设置IP
假设要将IP 设置为192.168.16.2 网关为192.168.16.250
查看/dev/下的网卡,比如e1000g0,然后新建/etc/hostname.e1000g0,内容为主机名
-
设置IP :修改/etc/hosts,/etc/inet/hosts 和 /etc/inet/ipnodes 这三个文件, 内容为 192.168.16.2 主机名 loghost
-
设置子网掩码: 更改了/etc/netmasks
-
设置缺省网关: 添加或者更新文件/etc/defaultrouter ,内容为:192.168.16.250
-
设置主机名: 添加了文件/etc/nodename 内容为主机名
-
重启网卡,不需要重启系统即可生效: # svcadm disable physical # svcadm enable physical
-
检测IP 是否设置成功 Ifconfig –a