RedhatHat配置IPv6地址:
修改网卡配置文件:
[root@localhost ~]# cat /etc/sysconfig/network-scripts/ifcfg-eth4
DEVICE="eth4"
BOOTPROTO="none"
HWADDR="00:50:56:AA:69:EF"
#NM_CONTROLLED="yes"
ONBOOT="yes"
TYPE="Ethernet"
#UUID="4e44fcc7-a050-4271-a07f-2d32d319be74"
#IPADDR=192.168.73.58
#NETMASK=255.255.255.0
#GATEWAY=192.168.73.1
IPV6INIT=yes
USERCTL=yes
IPV6ADDR=2001::5656
IPV6PREFIX=64
#IPV6_AUTOCONF=no
配置网关:
[root@localhost ~]# cat /etc/sysconfig/network
NETWORKING=yes
HOSTNAME=localhost.localdomain
NETWORKING_IPV6=yes
IPV6_DEFAULTGW=2001::1212%eth4
手动配置IP:
ifconfig eth0 inet6 add 2001::5656/64
手动添加默认路由:
[root@localhost ~]# ip -6 addr add 2001::1212/64 dev eth4
查看路由:
[root@localhost ~]# route -A inet6
Kernel IPv6 routing table
Destination Next Hop Flags Metric Ref Use Iface
getnameinfo failed
getnameinfo failed
[UNKNOWN]/128 [UNKNOWN] UC 0 1 1 eth4
getnameinfo failed
[UNKNOWN]/64 * U 256 12 0 eth4
getnameinfo failed
[UNKNOWN]/64 * U 256 0 0 eth4
getnameinfo failed
*/0 [UNKNOWN] UGDA 1024 26 0 eth4
localhost/128 * U 0 0 1 lo
getnameinfo failed
[UNKNOWN]/128 * U 0 620 1 lo
getnameinfo failed
[UNKNOWN]/128 * U 0 24 1 lo
getnameinfo failed
[UNKNOWN]/128 * U 0 20 1 lo
getnameinfo failed
[UNKNOWN]/8
阅读(6722) | 评论(0) | 转发(0) |