VMware下solaris10网卡配置
一.激活网卡
问题:VMware9安装solaris 10后,用ifconfig -a只能看到一个lo0,说明只有一个本地环回,即网卡没有启动或者系统没有识别到
bash-3.2# ifconfig -a
lo0: flags=2001000849 mtu 8232 index 1
e1000g0
说明己识别,只是没有激活,使用以下命令激活:
bash-3.2# ifconfig e1000g0 plumb
bash-3.2# dladm show-dev
e1000g0
bash-3.2# ifconfig -a
lo0: flags=2001000849 mtu 8232 index 1
e1000g0: flags=1000842 mtu 1500 index 2
若还出现问题,可以修改VMware虚拟机的配置文件
you will probably get the error failed to plumb pcn0
If so follow these steps, if not, and everything magically works..cool
AFTER INSTALL
--------------------
for networking.
--------------------
shutdown the VM
edit the .VMX file in the virtual machine folder on the host OS and add the following line
ethernet0.virtualDev = "e1000"
then startup Solaris
-----------------------------------------------
二.设置IP
DHCP:
ifconfig e1000g0 dhcp
静态IP:
ifconfig e1000g0 192.168.1.2 netmask 255.255.255.0 up
最基本的网络配置主要为配置网卡的:ip,gateway,netmasks及defaultrouter
如:在安装solaris的时候,在网络配置选择是选择了dhcp服务,但是我现在想要配置静态的ip及hostname等等
/etc/hosts
/etc/hostname.e1000g0
/etc/netmask
/etc/defaultrouter
/etc/nodename
/etc/networks
在solaris中只要设置过dhcp,则会优先于静态ip
首先到etc目录,查看一下有没有dhcp目录及dhcp.e1000g0文件,如果有说明启动了dhcp服务,若要配置静态ip需要将其删除,或是改名
要更改的配置为:
hostname:jlive
ip:192.168.1.2
netmask:255.255.255.0
defaultrouter:192.168.1.1
1.修改/etc/nodename文件,这个文件默认不存在,需要自己建立,内容为jlive
echo
2.修改/etc/hosts文件,
#
# Internet host table
#
::1
127.0.0.1
3.修改/etc/defaultrouter,默认不存在,需要自己建立
echo
4.修改/etc/hostname.e1000g0,若没有,需要自己建立
echo
5.修改/etc/netmask
192.168.1.0
6.修改/etc/networks
# The loopback network is used only for intra-machine communication
#
loopback
#
# Internet networks
#
arpanet