B – B = 0

perjalananku dalam mengenal hidup

Install Apache on freeBSD

1. langkah pertama download file apache, disini saya menggunakan file apache httpd-2.2.4.tar.gz
2. login ke freeBSD dengan root
3. masukkan file httpd-2.2.4.tar.gz ke /usr/src
# cp httpd-2.2.4.tar.gz /usr/src
3. kemudian masuk ke derektori /usr/src
# cd /usr/src
4. ekstrak file httpd-2.2.4.tar.gz dengan perintah
# tar -zxvf httpd-2.2.4.tar.gz
5. kemudian masuk pada derektori hasil ekstrak
# cd httpd-2.2.4
6 kemudian lakukan perintah konfigurasi
# ./configure –prefix=/usr/local/apache2/
7. setelah konfigurasi kurang lebih 15 menit dan gak ada eror jalan kan perintah
# make
8. setelah itu perintah
# make install
9. peroses make install selesai masuk pada derektori /usr/local/apache2/bin
# cd /usr/local/apache2/bin
10. kemudian jalakan daemon dari apache denagn perintah
# ./apachectl start
11. untuk mencoba keberhasilan instalasi lihat pada broser ketikkan localhost / pada kompi yang terjaring
dengan memanggil ip kompi freeBSD kita
12. kaloo ada tertampil pada broser maka kita telah berhasil melakukan instalasi apache

Desember 27, 2007 Ditulis oleh onotrah | FreeBSD | | No Comments Yet

Mengkomfigurasi Mikrotik sebagai proxy

minggu ini ini aku bingung untuk menyelesaikan masalah ku, kan gini aku pengen ngeblok web tertentu yang amoral + nyedot BW banyak. yang jadi masalah router ku and server proxy gak jadi satu alias dua pc gituuu!

pengen saya setiap clien langsung otomatis ngelot server proxy saya ???

PERSOALAN ITU DAH ADA JALAN KELUAR :)

ketika brosing ama mbah google ketemu deh caranya yaitu:

#NAT IP#
chain=srcnat out-interface=ether1 src-address=192.168.7.0/24 out-interface=ether1 action=src-nat to-addresses=[ip public/WAN] —– kalo ni dari user yang mau konek ke wan
chain=srcnat out-interface=ether1 src-address=10.10.1.0/30 out-interface=ether1 action=src-nat to-addresses=[ip public/WAN] —- kalo ni maksutnya apa kagak tau aku

#NAT proxy#
chain=dstnat src-address=192.168.7.0/24 protocol=tcp dst-port=80 action=dst-nat to-addresses=192.168.7.252 to-ports=8080 —— ni berarti untuk setiap koneksi dari ip 192.168.7.0/24 yang memakai pot 80 di tujukan terlebih dahulu ke pot 8080 proxy server dengan ip 192.168.7.252

Desember 19, 2007 Ditulis oleh onotrah | Mikrotik | | No Comments Yet

Compile file kernel BSD

kompile merupakan suatu cara untuk mengoptimalkan OS BSD terhadap hadware yang kita miliki
sehingga kenerja hadwer dan sofware dapat bekerja dengan optimal.

PROSES PENGKOMPILANYA YAITU :-)

1. login sebagai root pada OS bsd Anda
2. kemudian masuk pada pada derektori /conf dng printah
#cd /usr/src/sys/i386/conf
#ls perintah ini digunaka untuk melihat isi dari deroktori conf
.cvsignore GENERIC.hints NOTES SMP
DEFAULTS MYKERNEL PAE XBOX
GENERIC Makefile ROUTER
#cp GENERIC MYKERNEL
perintah ini digunaka untuk mengkopi file GENERIC dan disimpan dengan nama MYKERNEL
MYKERNEL dapat diberi nama sesuka kita.
3. ketikkan perintah
#vi MYKERNEL

# $FreeBSD: src/sys/i386/conf/GENERIC,v 1.429.2.13 2006/10/09 18:41:36 simon Exp $

machine i386
cpu I486_CPU
cpu I586_CPU
cpu I686_CPU
ident GENERIC

# To statically compile in device wiring instead of /boot/device.hints
#hints “GENERIC.hints” # Default places to look for devices.

makeoptions DEBUG=-g # Build kernel with gdb(1) debug symbols

options SCHED_4BSD # 4BSD scheduler
options PREEMPTION # Enable kernel thread preemption
options INET # InterNETworking
options INET6 # IPv6 communications protocols
options FFS # Berkeley Fast Filesystem
options SOFTUPDATES # Enable FFS soft updates support
options UFS_ACL # Support for access control lists
options UFS_DIRHASH # Improve performance on big directories
options MD_ROOT # MD is a potential root device
options NFSCLIENT # Network Filesystem Client
options NFSSERVER # Network Filesystem Server
options NFS_ROOT # NFS usable as /, requires NFSCLIENT
options MSDOSFS # MSDOS Filesystem
options CD9660 # ISO 9660 Filesystem
options PROCFS # Process filesystem (requires PSEUDOFS)
options PSEUDOFS # Pseudo-filesystem framework
options GEOM_GPT # GUID Partition Tables.
options COMPAT_43 # Compatible with BSD 4.3 [KEEP THIS!]
options COMPAT_FREEBSD4 # Compatible with FreeBSD4
options COMPAT_FREEBSD5 # Compatible with FreeBSD5
options SCSI_DELAY=5000 # Delay (in ms) before probing SCSI
options KTRACE # ktrace(1) support
options SYSVSHM # SYSV-style shared memory
options SYSVMSG # SYSV-style message queues
options SYSVSEM # SYSV-style semaphores
options _KPOSIX_PRIORITY_SCHEDULING # POSIX P1003_1B real-time extensions
options KBD_INSTALL_CDEV # install a CDEV entry in /dev
options ADAPTIVE_GIANT # Giant mutex is adaptive.

edit driver 2 yang gak penting dan gak guna seperti hd scsi adn yang lain lainnn oke

4. untuk melihat hadware yang kita guankan saat ini ketikkan perintah:
#vi /var/run/dmesg.boot /var/run/dmesg.boot

Copyright (c) 1992-2006 The FreeBSD Project.

opyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
The Regents of the University of California. All rights reserved.
FreeBSD is a registered trademark of The FreeBSD Foundation.
FreeBSD 6.2-RC2 #0: Mon Dec 17 20:08:36 CET 2007
root@idur.com:/usr/src/sys/i386/compile/MYKERNEL
Timecounter “i8254″ frequency 1193182 Hz quality 0
CPU: Intel(R) Pentium(R) 4 CPU 1.50GHz (928.31-MHz 686-class CPU)
Origin = “GenuineIntel” Id = 0xf12 Stepping = 2
Features=0×780a17b<FPU,VME,PSE,TSC,MSR,PAE,CX8,PGE,CMOV,MMX,FXSR,SSE,SSE2>
real memory = 111149056 (106 MB)
avail memory = 99172352 (94 MB)
kbd1 at kbdmux0
ath_hal: 0.9.17.2 (AR5210, AR5211, AR5212, RF5111, RF5112, RF2413, RF5413)
cpu0 on motherboard
pcib0: <Intel 82443BX host to PCI bridge (AGP disabled)> pcibus 0 on motherboard
pci0: <PCI bus> on pcib0
isab0: <PCI-ISA bridge> at device 7.0 on pci0
isa0: <ISA bus> on isab0
atapci0: <Intel PIIX4 UDMA33 controller> port 0×1f0-0×1f7,0×3f6,0×170-0×177,0×376,0xffa0-0xffaf at device 7.1 on pci0
ata0: <ATA channel 0> on atapci0
ata1: <ATA channel 1> on atapci0
pci0: <old, non-VGA display device> at device 7.2 (no driver attached)
pci0: <bridge> at device 7.3 (no driver attached)
pci0: <display, VGA> at device 8.0 (no driver attached)
de0: <Digital 21140A Fast Ethernet> port 0xec00-0xec7f mem 0xfebff000-0xfebfffff irq 11 at device 10.0 on pci0
de0: 21140A [10-100Mb/s] pass 2.0
de0: Ethernet address: 00:03:ff:81:4e:f0
pmtimer0 on isa0
orm0: <ISA Option ROM> at iomem 0xc0000-0xc9fff on isa0
atkbdc0: <Keyboard controller (i8042)> at port 0×60,0×64 on isa0
atkbd0: <AT Keyboard> irq 1 on atkbdc0

Desember 19, 2007 Ditulis oleh onotrah | FreeBSD | | No Comments Yet

SERVER PROXY REDHAT

squid proxy rathad –idur–

Cek dahulu apakah squid dah ter instal blum:
# rpm -qa | grep squid

ketikadah muncul sequid… dengan versi berapa maka squid telah terinstall.

jika belum maka perlu dilakukan instalasi terlebih dahului:

ketika squid telh teristall maka kita teinggal melakukan sentuhan sedikit aja:

1. Konfigurasi Squid
membuat derektori squid sejajar dengan derektori root
# pwd
# /root
# cd /
# mkdir /cache
# chown squid.squid /cache -Rf
chown disini digunakan untuk mengganti akses
kalo sudahn sekarang tinggal kita konfigurasi  squid.conf

#cd /etc/squid
#ls -l
errors   mime.conf          msntauth.conf          notsex  squid.conf          squid.conf.save
mib.txt  mime.conf.default  msntauth.conf.default  sex     squid.conf.default  squid.save

kita telah masuk dalam derektori squid dan kita telah melihat isinya
sebelum melakukan konfigurasi squid.conf alangkah baiknya file squid.conf di bekup dahulu.
# touch squid.conf
# chmod 640 squid.conf
# vi /etc/squid/squid.conf
# :wq squid.conf.safe

sekarang inggal mengedit file squid.conf

# vi squid.conf

konfigurasi squid.conf yang paling umum digunakan adalah

http_port 8080
icp_port 0
cache_mem 80 MB
maximum_object_size 256 KB
cache_dir ufs /cache 200 16 256
memory_pools_limit 32 MB
redirect_rewrites_host_header off
replacement_policy GDSF
half_closed_clients off
#———–transparent proxy ———–
httpd_accel_host virtual
httpd_accel_port 80
httpd_accel_with_proxy on
httpd_accel_uses_host_header on
#——————————————-
acl QUERY urlpath_regex cgi-bin \?
no_cache deny QUERY
acl all src 0.0.0.0/0.0.0.0
acl localhost src 127.0.0.1/255.255.255.255
acl lan src 192.168.7.252/255.255.255.0
acl Safe_ports port 80 443 210 119 563 70 21 1025-65535
acl CONNECT method CONNECT
acl notsex url_regex -i “/etc/squid/notsex”
acl sex url_regex -i “/etc/squid/sex”
no_cache deny SEX
http_access allow notsex all
http_access deny sex all
http_access allow lan
http_access allow localhost
http_access deny !Safe_ports
http_access deny CONNECT
http_access deny all
#—————- administration info ————
cache_mgr alfinux@telkom.net
cache_effective_user squid
cache_effective_group squid
log_icp_queries off
cachemgr_passwd mypassword all
forwarded_for off
buffered_logs on
visible_hostname alfinuke.edcentral.pdk
ftp_user squid@edcentral.pdk

proxy yang natinta digunakan adalah ip kompi server denagn pot 8080

2. untuk konfigurasi web yang difilter atau pun tidak dapat di konfigurasi:

#pwd
/etc/squid
#vi sex
disini kita tingggal memasukkan nama web yang akan di fileter oleh proxy
jangan lupa menyimpan editanya.
#:wq

3. untuk memperbolehkan situs yang masuk kita tinggal mengedit filr di /ec/squid/notsex

#vi /etc/squid/notsex
tinggal memasukkan nama web yang akan masukkk oeh proxy
jangn lupa menyimpan hasil editan ya.

3. menjalankan squid
# squid -z
#/ec/init.d/squid start
#iptabels -f

Desember 19, 2007 Ditulis oleh onotrah | Redhat | | No Comments Yet

Login root pada freeBSD dengan SSH

ketika aku kenal freeBSD, aku kebingungn masalah ssh dengan root. ternya untuk dapat mengakses freeBSD dengan ssh login root maka kita harus mengedit fili sshd_config langkah2 nya yaitu:

1. login freeBSD dengan root

#cd /etc/ssh

#vi sshd_config akan muncul tampilan

Port 22 ini kita enable dengan menghilangkan tanda #

#Protocol 2
#AddressFamily any
#ListenAddress 0.0.0.0
#ListenAddress ::

# HostKey for protocol version 1
#HostKey /etc/ssh/ssh_host_key
# HostKeys for protocol version 2
#HostKey /etc/ssh/ssh_host_dsa_key

# Lifetime and size of ephemeral version 1 server key
#KeyRegenerationInterval 1h
#ServerKeyBits 768

# Logging
# obsoletes QuietMode and FascistLogging
#SyslogFacility AUTH
#LogLevel INFO

# Authentication:

#LoginGraceTime 2m
PermitRootLogin yes pada ini juga kita anable dan tulisan no kita ganti yes

#StrictModes yes
#MaxAuthTries 6
2. kita tingggal restart sshd denga perintah

# /etc/rc.d/sshd restart

3. coba ssh denagn kompi lain pasti bisa dehh

Desember 18, 2007 Ditulis oleh onotrah | FreeBSD | | No Comments Yet