linux 下 查看ipv6网关
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了linux 下 查看ipv6网关相关的知识,希望对你有一定的参考价值。
虚拟机设置是hostonly 利用网卡共享和虚拟的路由来上网。
在linux(VMware下的FC6 内核2.6)下面配置IPV6:
ip地址可以,网关:route -A inet6 add ::/0 gw 2001:da8:207::9401
但是就是不能访问ipv6的页面,ping6也无和ipv6地址取得连接,提示地址不可达。
可能是网关问题,请问linux怎么看ipv6的网关呢?
谢谢。
如果方便的话,哪位朋友成功配置过ipv6的,可否赐教?
感激不尽
# /sbin/ip -6 route show dev eth0
3ffe:ffff:0:f101::/64 proto kernel metric 256 mtu 1500 advmss 1440
fe80::/10 proto kernel metric 256 mtu 1500 advmss 1440
ff00::/8 proto kernel metric 256 mtu 1500 advmss 1440
default proto kernel metric 256 mtu 1500 advmss 1440
我没在虚拟机上配置过 ,所以不清楚
我想你首先应该判断是否是你虚拟机的问题 ,其次 ,vmware还是别的什么的虚拟网卡是否支持ipv6
希望对你有所帮助 参考技术A 输入ifconfig eth0,eth0代表的是你的网卡,你查看的时候根据你的实际情况而定。
Centos/Linux下如何查看网关地址/Gateway地址
Centos/Linux下如何查看网关地址/Gateway地址? Linux下查看网关的命令还是很多的,不过如果IP是DHCP获取,那么有些命令是不适用的,当然也有通用的查询网关命令.
1.ifconfig -a 和 cat /etc/resolv.conf (主要查看ip/netmask和dns)
2.netstat -rn
3.cat /etc/sysconfig/network
4.cat /etc/sysconfig/network-scripts/ifcfg-eth0
5.traceroute 第一行就是自己的网关
6.ip route show
7.route -n
以上几个是比较常用的查询网关的命令。下面是范例:
[[email protected]]# netstat -rn
Kernel IP routing table
Destination Gateway Genmask Flags MSS Window irtt Iface
184.82.152.96 0.0.0.0 255.255.255.248 U 0 0 0 eth0
169.254.0.0 0.0.0.0 255.255.0.0 U 0 0 0 eth0
0.0.0.0 184.82.152.97 0.0.0.0 UG 0 0 0 eth0
[[email protected]]# cat /etc/sysconfig/network-scripts/ifcfg-eth0
# Intel Corporation 82567V-2 Gigabit Network Connection
DEVICE=eth0
BOOTPROTO=none
HWADDR=00:1c:c0:f8:a1:ac
ONBOOT=yes
NETMASK=255.255.255.248
IPADDR=184.82.152.98
GATEWAY=184.82.152.97
TYPE=Ethernet
[[email protected]]# ip route show
184.82.152.96/29 dev eth0 proto kernel scope link src 184.82.152.98
169.254.0.0/16 dev eth0 scope link
default via 184.82.152.97 dev eth0
[[email protected]]# route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
184.82.152.96 0.0.0.0 255.255.255.248 U 0 0 0 eth0
169.254.0.0 0.0.0.0 255.255.0.0 U 0 0 0 eth0
0.0.0.0 184.82.152.97 0.0.0.0 UG 0 0 0 eth0
[[email protected]]# ifconfig -a
eth0 Link encap:Ethernet HWaddr 00:1C:C0:F8:A1:AC
inet addr:184.82.152.98 Bcast:184.82.152.103 Mask:255.255.255.248
本文出自 “平平淡淡才是真” 博客,请务必保留此出处http://ucode.blog.51cto.com/10837891/1893181
以上是关于linux 下 查看ipv6网关的主要内容,如果未能解决你的问题,请参考以下文章
Centos/Linux下如何查看网关地址/Gateway地址
Linux 实用指令 -- 网络配置(查看网络IP和网关 ping 测试主机之间网络连通Linux网络环境配置(指定固定ip))