我可以 ssh 到远程虚拟机,但无法 ping 它

我可以 ssh 到远程虚拟机,但无法 ping 它

我获得了一台运行 Centos 7 的远程虚拟机,我必须在其上设置一个 Web 服务器。我可以通过 ssh 访问该机器,但无法 ping 通它,也无法访问我创建的测试网页(Apache 正在运行)。我做了一些检查:

  • 虚拟机上的ifconfig:

    eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1400
    inet 192.168.209.7  netmask 255.255.252.0  broadcast 192.168.211.255
    inet6 fe80::f816:3eff:fe35:cdfb  prefixlen 64  scopeid 0x20<link>
    ether fa:16:3e:35:cd:fb  txqueuelen 1000  (Ethernet)
    RX packets 110329  bytes 454155776 (433.1 MiB)
    RX errors 0  dropped 0  overruns 0  frame 0
    TX packets 65991  bytes 7412428 (7.0 MiB)
    TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
    
  • 虚拟机上的iptables:

    Chain INPUT (policy ACCEPT 85851 packets, 450M bytes)
    pkts bytes target     prot opt in     out     source      destination         
    
    Chain FORWARD (policy ACCEPT 0 packets, 0 bytes)
    pkts bytes target     prot opt in     out     source      destination         
    
    Chain OUTPUT (policy ACCEPT 46405 packets, 3382K bytes)
    pkts bytes target     prot opt in     out     source      destination
    
  • nmap -Pn -PS80 <remote ip>在客户端机器上(运行 ubuntu

    Starting Nmap 7.60 ( https://nmap.org ) at 2018-01-28 11:20 CET
    Nmap scan report for <remote ip>
    Host is up (0.043s latency).
    Not shown: 999 filtered ports
    PORT   STATE SERVICE
    22/tcp open  ssh
    
    Nmap done: 1 IP address (1 host up) scanned in 14.00 seconds
    

可能是什么问题呢?

相关内容