运行命令ifconfig -a, 只发现lo0接口,没有发现网卡。
一.识别网卡
1. 使用 /usr/X11/bin/scanpci 查看系统上的PCI设备:
................vendor 0x8086 device 0x1050 Intel Corporation PRO/100 VE Network Connection
2. 编辑/etc/driver_aliases,增加以下内容
iprb "pci8086,1050" (iprb是intel网卡的接口名,后面的id是刚刚用scanpic查到的 8086是venderid)
3. /boot/solaris/devicedb/master文件,加入以下内容:
pci8086,1050 pci8086,1050 net pci iprb.bef "Intel Pro/100 VE Network Connection"
4. 运行devlinks
5. 运行touch /reconfigure
6.编辑/etc/hostname.iprb0, 文件内容是你的主机名比如ZSol。(如果用的是IPv6,那么要编辑的是hostname6.iprb0文件)
7. 配置主机名:
(1)运行/usr/lib/mail/sh/check-hostname
(2)获取root权限
(3)chmod 644 /etc/inet/hosts
(4)gedit /etc/inet/hosts 并按(1)所提示的方法输入相关内容
(5)chmod 444 /etc/ineet/hosts
8. 重新启动系统
二.配置相关文件
1. 启动网卡: 点击屏幕右下角的“网络监视器”,并在“连接”选项中选中“iprb0“。
2.配置网关,新建/etc/defaultrouter文本文档,内容为网关ip:
xxx.xxx.xxx.xxx (要换成你的网关地址)
3.配置DNS:
nameserver xxx.xxx.xxx.xxx
nameserver xxx.xxx.xxx.xxx
4.设置掩码:修改/etc/netmasks文件
最后添加一行:
xxx.xxx.xxx.xxx 255.255.255.0
5.新建空白文件 /etc/dhcp.iprb0。
6. 启用网卡:
ifconfig iprb0 unplumb down 停用网卡
ifconfig iprb0 plumb up 激活网卡
ifconfig iprb0 dhcp 配置动态分配ip