免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 1276 | 回复: 0
打印 上一主题 下一主题

Solaris系统网卡的配置 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2007-10-30 16:44 |只看该作者 |倒序浏览

                1,先看一下系统有几块网卡:
#more /etc/path_to_inst |grep network
然后对需要配置ip的网卡进行配置。
【有的资料写用#kstat |grep net来查看】
2,配置一个网口的ip:
1)ifconfig ce3 plumb 启用ce3
2)ifconfig ce3 inet 10.0.106.41 netmask 255.255.255.252 broadcast + up
3)ifconfig -a 查看已经装载的网卡
【可以用ifconfig -a plumb 系统可识别的网卡全装载上来看看,然后ifconfig xxx unplumb 一个个关闭,呵呵。】
3,一个卡绑定多个ip
举例说明,网卡名hme0:
# vi /etc/hosts
127.0.0.1 localhost
192.168.2.1 test1 loghost
192.168.9.15 test2
192.168.9.65 test3
# vi /etc/netmasks
192.168.2.0 255.255.255.0
192.168.9.0 255.255.255.192
192.168.9.64 255.255.255.252
#vi /etc/hostname.hme0
test1(或直接写ip)
#vi /etc/hostname.hme0:1
test2
#vi /etc/hostname.hme0:2
test3
上面的几步,是直接修改配置文件,系统重启后配置仍然有效。
下面是利用命令来进行配置,但是在系统重启后配置会丢失的:
# ifconfig hme0 inet 192.168.2.1 netmask 255.255.255.0 broadcast + up
# ifconfig hme0:1 inet 192.168.9.15 netmask 255.255.255.192 broadcast + up
# ifconfig hme0 inet 192.168.9.65 netmask 255.255.255.252 broadcast + up
               
               

本文来自ChinaUnix博客,如果查看原文请点:http://blog.chinaunix.net/u/25155/showart_410873.html
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP