Isi file /etc/sysconfig/network-scripts/ifcfg-eth0 sebelum di-edit :
# Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+
DEVICE=eth0
IPADDR=192.168.17.12
BROADCAST=192.168.17.255
NETMASK=255.255.255.0
BOOTPROTO=static
#BOOTPROTO=dhcp
HWADDR=00:10:DC:CD:A0:39
ONBOOT=yes
#DHCP_HOSTNAME=localhost.localdomain
Isi file /etc/sysconfig/network-scripts/ifcfg-eth0 setelah di-edit (tambahkan GATEWAY):
# Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+
DEVICE=eth0
IPADDR=192.168.17.12
BROADCAST=192.168.17.255
NETMASK=255.255.255.0
GATEWAY=192.168.17.1
BOOTPROTO=static
#BOOTPROTO=dhcp
HWADDR=00:10:DC:CD:A0:39
ONBOOT=yes
#DHCP_HOSTNAME=localhost.localdomain
DEVICE=eth0
IPADDR=192.168.17.12
BROADCAST=192.168.17.255
NETMASK=255.255.255.0
GATEWAY=192.168.17.1
BOOTPROTO=static
#BOOTPROTO=dhcp
HWADDR=00:10:DC:CD:A0:39
ONBOOT=yes
#DHCP_HOSTNAME=localhost.localdomain
Isi file /etc/resolv.conf adalah kosong. Selanjutnya edit menjadi
nameserver 192.168.17.1
Testing sebelum konfigurasi DNS
[root@localhost ~]# ping www.yahoo.com
ping: unknown host www.yahoo.com
Testing setelah konfigurasi DNS
[root@localhost ~]# ping www.yahoo.com
PING ds-sg-fp3.wg1.b.yahoo.com (106.10.139.246) 56(84) bytes of data.
64 bytes from ir1.fp.vip.sg3.yahoo.com (106.10.139.246): icmp_seq=1 ttl=52 time=19.5 ms
64 bytes from ir1.fp.vip.sg3.yahoo.com (106.10.139.246): icmp_seq=2 ttl=52 time=22.3 ms
--- ds-sg-fp3.wg1.b.yahoo.com ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 2038ms
rtt min/avg/max/mdev = 19.594/20.979/22.364/1.385 ms
No comments:
Post a Comment