debian 配置上网参数

# vim /etc/network/interfaces

auto eth0
iface eth0 inet static
address
192.168.1.3
netmask
255.255.255.0
gateway
192.168.1.1

设置DNS服务器
# vim /etc/resolv.conf
nameserver 8.8.8.8

CentOS 设置方法:

# vim /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE
=eth0
BOOTPROTO
=static
HWADDR
=00:03:48:1F:AB:20
ONBOOT
=yes
IPADDR
=192.168.1.33
NETMASK
=255.255.255.0
GATEWAY
=192.168.1.1

DNS设置方法一样

posted @ 2011-05-08 21:38  Mini.J  阅读(152)  评论(0)    收藏  举报