Networking Settings2011/03/05 |
[1] | Change to static IP addres if you use Debian as a server. |
root@dlp:~# vi /etc/network/interfaces # This file describes the network interfaces available on your system # and how to activate them. For more information, see interfaces(5).. # The loopback network interface auto lo iface lo inet loopback # The primary network interface allow-hotplug eth0 # make it comment # iface eth0 inet dhcp# add follows auto eth0 iface eth0 inet static address 10.0.0.30 # specify IP address network 10.0.0.0 # specify network address netmask 255.255.255.0 # specify subnet-mask broadcast 10.0.0.255 # specify broadcast address gateway 10.0.0.1 # specify default gateway root@dlp:~# ifdown eth0 # stop eth0 root@dlp:~# ifup eth0 # start eth0 |
[2] | Disable IPv6 if not needed. |
root@dlp:~# echo "net.ipv6.conf.all.disable_ipv6=1" >> /etc/sysctl.conf root@dlp:~# root@dlp:~# eth0 Link encap:Ethernet HWaddr 00:1a:4d:45:9f:57 inet addr:10.0.0.30 Bcast:10.0.0.255 Mask:255.255.255.0 UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:43 errors:0 dropped:0 overruns:0 frame:0 TX packets:39 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:5444 (5.3 KiB) TX bytes:6145 (6.0 KiB) Interrupt:27 Base address:0x6000 lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 UP LOOPBACK RUNNING MTU:16436 Metric:1 RX packets:0 errors:0 dropped:0 overruns:0 frame:0 TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:0 (0.0 B) TX bytes:0 (0.0 B) |
Sponsored Link |
|