| system 回复于:2001-11-15 17:14:07 |
| 是不是重新启动了? ipconfig设置的只是临时的,重起后就失效了 |
| 三少爷 回复于:2001-11-15 17:43:52 |
| 更改网络接口的IP地址: #ifconfig hme0 down #ifconfig hme0 211.101.149.233 .netmask 255.255.255.0 up 首先,使用down命令参数把网络接口hme0的服务暂时停止,然后再用ifconfig命令给 接口分配新的IP地址和掩码,并启动网络接口服务 也可以通过改变文件/etc/hosts中的IP地址的值并重新启动系统来更改机器的IP地址。 /etc/hosts/: 211.101.149.11 sampdt 定义主机名在/etc/hostname.hme0及IP地址。 更改了网卡/增加了网卡,系统不能自动启动该接口服务,这时需要手动创建网口服务: #ifconfig hme0 plumb 即可以为接口le0创建网口服务 相应地,用ifconfig带unplumb参数可以停止服务并关闭网络 |
| leon 回复于:2001-11-15 23:32:35 |
| 就是这样 |
| jie718 回复于:2001-11-16 09:53:48 |
| also you can sys-unconfig to reset IP and Hostname, |
| angel 回复于:2001-11-16 15:23:44 |
| 实际上永远的UNIX上有详细的解释,呵呵 |
| leon 回复于:2001-11-18 15:15:36 |
| 但是ip6的可不一样哦 |
| 三少爷 回复于:2001-11-19 18:36:08 |
| 请讲。。 |
| amiao 回复于:2001-11-20 10:14:39 |
| 永远的UNIX是绝对好网站 |
| alanv 回复于:2001-11-20 10:14:41 |
| 修改ip地址直接用vi来修改etc/hosts文件不行吗? 我是一致这么做的 |
| hoy 回复于:2002-01-31 16:03:09 |
| 对阿,我也是,直接改/etc/hosts的ip ,然后reboot ifconfig 改动的ip 重启后就没有了 |
| wuya 回复于:2002-01-31 16:25:31 |
| [这个贴子最后由wuya在 2002/01/31 04:33pm 编辑] hoy,我看错行了 |
| jack-124 回复于:2002-01-31 16:26:57 |
| Ifconfig只是该系统正在运行的配置,而/etc/hosts是在系统启动的时候需要从其中加载配置的文件,所以用ifconfig改只是当时生效,而要重启动后还要生效就需要更改hosts文件/ |
| guofr 回复于:2002-01-31 17:32:48 |
| sys-unconfig,那有这个命令的详细说明,能介绍一下吗。 |
| purepig 回复于:2002-01-31 17:34:40 |
| 不用什么说明,自己试一下就知道了. 实在想知道,看man sys-unconfig |
| aying516 回复于:2002-02-01 08:31:56 |
| # ifconfig hme0 inet 192.0.0.1 netmask 255.255.255.0 up # route add default gateway (如果需要的话) # vi /etc/hosts # vi /etc/netmasks # vi /etc/defaultrouter ok,不用重新启动 |
| Fusheng 回复于:2002-10-25 05:51:00 |
| Hello there, If you want to perm change and IP, you need to change files: /etc/hosts /etc/hostname.interfacename depends on your network configuration, you might also need to change: /etc/defaultrouter /etc/netmasks Fusheng |
| nuliyidian 回复于:2002-10-25 09:14:50 |
| 谁懂ipv6啊? |