见鬼!除了网关,其他的都可以ping通。
系统为ubuntu 6.10
软件为:VMware Player 1.0.2 build-29634
虚拟机系统:XP
网关IP:192.168.1.1
本机IP:192.168.1.22
另一个真实机器IP:192.168.1.11
虚拟机IP:192.168.1.33
虚拟机网卡模式:bridged
虚拟机不能上网,在虚拟机执行
Microsoft Windows XP [版本 5.1.2600]
(C) 版权所有 1985-2001 Microsoft Corp.
C:\Documents and Settings\gamexg>ping 192.168.1.22
Pinging 192.168.1.22 with 32 bytes of data:
Reply from 192.168.1.22: bytes=32 time<1ms TTL=64
Reply from 192.168.1.22: bytes=32 time<1ms TTL=64
Reply from 192.168.1.22: bytes=32 time<1ms TTL=64
Reply from 192.168.1.22: bytes=32 time<1ms TTL=64
Ping statistics for 192.168.1.22:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 0ms, Average = 0ms
C:\Documents and Settings\gamexg>ping 192.168.1.33
Pinging 192.168.1.33 with 32 bytes of data:
Reply from 192.168.1.33: bytes=32 time<1ms TTL=128
Reply from 192.168.1.33: bytes=32 time<1ms TTL=128
Reply from 192.168.1.33: bytes=32 time<1ms TTL=128
Reply from 192.168.1.33: bytes=32 time<1ms TTL=128
Ping statistics for 192.168.1.33:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 0ms, Average = 0ms
C:\Documents and Settings\gamexg>ping 192.168.1.11
Pinging 192.168.1.11 with 32 bytes of data:
Reply from 192.168.1.11: bytes=32 time=4ms TTL=64
Reply from 192.168.1.11: bytes=32 time=1ms TTL=64
Reply from 192.168.1.11: bytes=32 time<1ms TTL=64
Reply from 192.168.1.11: bytes=32 time<1ms TTL=64
Ping statistics for 192.168.1.11:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 4ms, Average = 1ms
C:\Documents and Settings\gamexg>ping 192.168.1.1
Pinging 192.168.1.1 with 32 bytes of data:
Request timed out.
Request timed out.
Request timed out.
Request timed out.
Ping statistics for 192.168.1.1:
Packets: Sent = 4, Received = 0, Lost = 4 (100% loss),
C:\Documents and Settings\gamexg>
在主机上执行
gamexg@ubuntu:~$ uname -a
Linux ubuntu 2.6.17-10-386 #2 Tue Dec 5 22:26:18 UTC 2006 i686 GNU/Linux
gamexg@ubuntu:~$ ping 192.168.1.1
PING 192.168.1.1 (192.168.1.1) 56(84) bytes of data.
64 bytes from 192.168.1.1: icmp_seq=1 ttl=64 time=0.498 ms
64 bytes from 192.168.1.1: icmp_seq=2 ttl=64 time=0.463 ms
64 bytes from 192.168.1.1: icmp_seq=3 ttl=64 time=0.456 ms
64 bytes from 192.168.1.1: icmp_seq=4 ttl=64 time=0.460 ms
64 bytes from 192.168.1.1: icmp_seq=5 ttl=64 time=0.471 ms
64 bytes from 192.168.1.1: icmp_seq=6 ttl=64 time=0.467 ms
64 bytes from 192.168.1.1: icmp_seq=7 ttl=64 time=0.468 ms
64 bytes from 192.168.1.1: icmp_seq=8 ttl=64 time=0.467 ms
--- 192.168.1.1 ping statistics ---
8 packets transmitted, 8 received, 0% packet loss, time 7012ms
rtt min/avg/max/mdev = 0.456/0.468/0.498/0.029 ms
gamexg@ubuntu:~$ ping 192.168.1.11
PING 192.168.1.11 (192.168.1.11) 56(84) bytes of data.
64 bytes from 192.168.1.11: icmp_seq=1 ttl=64 time=2.62 ms
64 bytes from 192.168.1.11: icmp_seq=2 ttl=64 time=0.333 ms
64 bytes from 192.168.1.11: icmp_seq=3 ttl=64 time=0.368 ms
--- 192.168.1.11 ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2006ms
rtt min/avg/max/mdev = 0.333/1.109/2.626/1.072 ms
gamexg@ubuntu:~$ ping 192.168.1.22
PING 192.168.1.22 (192.168.1.22) 56(84) bytes of data.
64 bytes from 192.168.1.22: icmp_seq=1 ttl=64 time=0.048 ms
64 bytes from 192.168.1.22: icmp_seq=2 ttl=64 time=0.041 ms
64 bytes from 192.168.1.22: icmp_seq=3 ttl=64 time=0.037 ms
--- 192.168.1.22 ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 1998ms
rtt min/avg/max/mdev = 0.037/0.042/0.048/0.004 ms
gamexg@ubuntu:~$ ping 192.168.1.33
PING 192.168.1.33 (192.168.1.33) 56(84) bytes of data.
64 bytes from 192.168.1.33: icmp_seq=1 ttl=128 time=2.75 ms
64 bytes from 192.168.1.33: icmp_seq=2 ttl=128 time=0.350 ms
64 bytes from 192.168.1.33: icmp_seq=3 ttl=128 time=0.470 ms
64 bytes from 192.168.1.33: icmp_seq=4 ttl=128 time=0.340 ms
--- 192.168.1.33 ping statistics ---
4 packets transmitted, 4 received, 0% packet loss, time 3003ms
rtt min/avg/max/mdev = 0.340/0.978/2.755/1.027 ms
gamexg@ubuntu:~$
我的另一个虚拟机也PING不通网关。
运行
sudo -i
echo 1 > /proc/sys/net/ipv4/ip_forward
就可以解决问题
[已解决]见鬼!除了网关,其他的都可以ping通。
-
- 帖子: 72
- 注册时间: 2007-01-27 14:06
-
- 帖子: 452
- 注册时间: 2006-11-18 15:40