3.

Lencana Facebook

Kamis, 18 Februari 2010

setting router linux debian 5 lenny

nano /etc/network/interfaces
atur ip kemudian save dan ketik :
/etc/init.d/networking restart

iptables --flush
iptables --table nat --flush
iptables --delete-chain
iptables --table nat --delete-chain
iptables --table nat --append POSTROUTING --out-interface eth0 -j MASQUERADE
iptables --append FORWARD --in-interface eth1 -j ACCEPT
echo 1 > /proc/sys/net/ipv4/ip_forward
iptables-save > /etc/firewall.conf

nano /etc/network/if-up.d/iptables
ketik:
#!/bin/sh

iptables-restore < /etc/firewall.conf

echo 1 > /proc/sys/net/ipv4/ip_forward

kemudian save

chmod +x /etc/network/if-up.d/iptables

reboot!!!!!!

atur samba dengan ketik
nano /etc/samba/smb.conf

check pada bagian:
global setting pastikan tidak ada tanda # pada
workgroup = isi workgroup
server setting =

terletak pada global setting :
ketikkan pada paling bawah global setting:
guest only = yes
guest ok = yes
account guest = bagus-tkj

terletak pada authentication
pastikan script :
security = share

kemudian untuk sharing cd-rom sebagai berikut
hilangkan tanda ; pada
[cd-rom]
comment = samba server's CD-ROM
read only = yes
locking = no
path = /cdrom
guest ok = yes

kemudian sharing folder :
tambahkan script berikut:
[tekaje]
path = /home/bagus-tkj/Desktop/tekaje
comment = Share Directories
browseable = yes
writable = yes
public = yes
available = yes

kemudian save dan restart samba dengan cara :
/etc/init.d/samba restart

setelah itu kemudian upload data dari laptop ke PC
dan berikutnya adalah ketikkan script berikut pada terminal linux :
cp -r /home/bagus-tkj/Desktop/tekaje /var/www

kemudian lakukan ujicoba web page dan cdrom dari laptop melalui mozilla dengan mengetik 192.168.2.36/bagus-tkj


1 komentar:

photo