Page 1 of 1
Cannot ping the host from the guest
Posted: 11. Apr 2012, 15:13
by Gringo67
Hi,
I'm running an Ubuntu server 10.04 as guest on a Windows xp host. I can
ping the guest (Ubuntu) from the host (Windows) but I cannot ping the
host from the guest.
The guest configuration network is set to "bridged networking" and
the VirtualBox Host-Only Network TCP/IP is set to
IP:192.168.56.1
mask: 255.255.255.0
What should I do to reach the host from the guest ?
Thanks for advance
Re: Cannot ping the host from the guest
Posted: 11. Apr 2012, 15:20
by Perryg
Did you setup an additional adapter to host-only? If not then use the hosts original IP address.
Re: Cannot ping the host from the guest
Posted: 11. Apr 2012, 15:43
by Gringo67
Thanks for your fast answer.
Did you setup an additional adapter to host-only?
No I didn't.
If not then use the hosts original IP address.
That's what I did and indeed it works.
But why am I not able to ping the host with an ip address given by the router (ex: 192.168.0.32) and
what should I do to make it works ?
Re: Cannot ping the host from the guest
Posted: 11. Apr 2012, 15:53
by Perryg
You say in one sentence that it worked and then ask how to make it work. This leads to a lot of confusion.
Post the results of ipconfig /all from the host and ifconfig -a from the guest.
Also make sure that firewalls or virus software are not causing your issue
Re: Cannot ping the host from the guest
Posted: 11. Apr 2012, 16:26
by Gringo67
You say in one sentence that it worked and then ask how to make it work. This leads to a lot of confusion.
I know but that what happens.
If I ping 192.168.0.254 or my real IP address 88.xxx.xx.xxx it works, but
when I ping 192.168.0.32 it doesn't.
Post the results of ipconfig /all from the host and ifconfig -a from the guest.
Host ipconfig/all
Code: Select all
Configuration IP de Windows
Nom de l'hôte . . . . . . . . . . : salander
Suffixe DNS principal . . . . . . :
Type de noud . . . . . . . . . . : Inconnu
Routage IP activé . . . . . . . . : Non
Proxy WINS activé . . . . . . . . : Non
Carte Ethernet Connexion au réseau local:
Suffixe DNS propre à la connexion :
Description . . . . . . . . . . . : Carte Intel(R) PRO/100 S pour ordinateur de bureau
Adresse physique . . . . . . . . .: 00-02-B3-D1-32-45
DHCP activé. . . . . . . . . . . : Oui
Configuration automatique activée . . . . : Oui
Adresse IP. . . . . . . . . . . . : 192.168.0.32
Masque de sous-réseau . . . . . . : 255.255.255.0
Passerelle par défaut . . . . . . : 192.168.0.254
Serveur DHCP. . . . . . . . . . . : 192.168.0.254
Serveurs DNS . . . . . . . . . . : 192.168.0.254
Bail obtenu . . . . . . . . . . . : mercredi 11 avril 2012 14:44:41
Bail expirant . . . . . . . . . . : jeudi 12 avril 2012 02:44:41
Carte Ethernet VirtualBox Host-Only Network:
Suffixe DNS propre à la connexion :
Description . . . . . . . . . . . : VirtualBox Host-Only Ethernet Adapter
Adresse physique . . . . . . . . .: 08-00-27-00-90-36
DHCP activé. . . . . . . . . . . : Non
Adresse IP. . . . . . . . . . . . : 192.168.56.1
Masque de sous-réseau . . . . . . : 255.255.255.0
Passerelle par défaut . . . . . . :
Guest ifconfig -a
Code: Select all
eth0 Link encap:Ethernet HWaddr 08:00:27:75:d9:d2
inet adr:192.168.0.13 Bcast:192.168.0.255 Masque:255.255.255.0
adr inet6: 2a01:e35:8b65:ccf0:a00:27ff:fe75:d9d2/64 Scope:Global
adr inet6: fe80::a00:27ff:fe75:d9d2/64 Scope:Lien
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
Packets reçus:1033 erreurs:0 :0 overruns:0 frame:0
TX packets:211 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 lg file transmission:1000
Octets reçus:122207 (122.2 KB) Octets transmis:27826 (27.8 KB)
lo Link encap:Boucle locale
inet adr:127.0.0.1 Masque:255.0.0.0
adr inet6: ::1/128 Scope:Hôte
UP LOOPBACK RUNNING MTU:16436 Metric:1
Packets reçus:11 erreurs:0 :0 overruns:0 frame:0
TX packets:11 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 lg file transmission:0
Octets reçus:1232 (1.2 KB) Octets transmis:1232 (1.2 KB)
Re: Cannot ping the host from the guest
Posted: 11. Apr 2012, 16:35
by Perryg
If I ping 192.168.0.254 or my real IP address 88.xxx.xx.xxx it works, but
OK the 192.168.0.254 is the address (gateway) of your router and the 88.* is the public address assigned by your provider.
The 192.168.0.32 *is the IP address of the host and if it is not reachable it must be getting filtered out by either a firewall or virus software.
Re: Cannot ping the host from the guest
Posted: 11. Apr 2012, 17:06
by Gringo67
The 192.168.0.32 *is the IP address of the host and if it is not reachable it must be getting filtered out by either a firewall or virus software.
It's the firewall.
Thanks again.

Re: Cannot ping the host from the guest
Posted: 5. Jun 2013, 22:58
by Micheus
Hi there.
I'm with the same problem in the subject, but all that was explained here didn't help me. I already did a lot of search on Google and no success.
I will put here all information I have read someone asked for before. Please let me know if anything else is necessary.
- Host (
Morpheus):
Windows 7 Pro 64bits;
- Guest (
Morpheus-Linux):
Linux Mint 13 (Maya);
- VM configuration on
VirtualBox with
network adapter configured for
Bridge mode;
- All IP address were set manually;
- Both Windows and Linux Firewall service stopped;
- Avast anti-virus - all service disabled during the test;
- I'm able to manage the Windows shared folder on Linux.
1) IP information
a) Host (ipconfig on Windows):
Configuração de IP do Windows
Adaptador Ethernet Conexão local 2:
Sufixo DNS específico de conexão. . . . . . :
Endereço IPv6 de link local . . . . . . . . : fe80::f90c:4b40:e794:ab29%12
Endereço IPv4. . . . . . . . . . . . . . . :
192.168.1.2
Máscara de Sub-rede . . . . . . . . . . . . : 255.255.255.0
Gateway Padrão. . . . . . . . . . . . . . . :
192.168.1.1
Adaptador Ethernet VirtualBox Host-Only Network:
Sufixo DNS específico de conexão. . . . . . :
Endereço IPv6 de link local . . . . . . . . : fe80::6053

2bca:ef30%59
Endereço IPv4. . . . . . . . . . . . . . . :
169.168.1.50
Máscara de Sub-rede . . . . . . . . . . . . : 255.255.255.0
Gateway Padrão. . . . . . . . . . . . . . . :
b) Gest (ifconfig on Linux):
eth1 Link encap:Ethernet HWaddr 08:00:27:9c:c8:7f
inet addr:
192.168.1.51 Bcast:192.168.1.255 Mask:255.255.255.0
inet6 addr: fe80::a00

fe9c:c87f/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:4627 errors:0 dropped:0 overruns:0 frame:0
TX packets:3344 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:4869302 (4.8 MB) TX bytes:508938 (508.9 KB)
2) Result of ping
a) Host (Windows):
C:\Users\Micheus>ping MORPHEUS-LINUX
Disparando MORPHEUS-LINUX [192.168.1.51] com 32 bytes de dados:
Resposta de 192.168.1.51: bytes=32 tempo<1ms TTL=64
Resposta de 192.168.1.51: bytes=32 tempo<1ms TTL=64
Resposta de 192.168.1.51: bytes=32 tempo<1ms TTL=64
Estatísticas do Ping para 192.168.1.51:
Pacotes: Enviados = 3, Recebidos = 3, Perdidos = 0 (0% de perda),
C:\Users\Micheus>ping MORPHEUS
Disparando Morpheus [fe80::f90c:4b40:e794:ab29%12] com 32 bytes de dados:
Resposta de fe80::f90c:4b40:e794:ab29%12: tempo<1ms
Resposta de fe80::f90c:4b40:e794:ab29%12: tempo<1ms
Resposta de fe80::f90c:4b40:e794:ab29%12: tempo<1ms
Estatísticas do Ping para fe80::f90c:4b40:e794:ab29%12:
Pacotes: Enviados = 3, Recebidos = 3, Perdidos = 0 (0% de perda),
b) Guest (Linux):
Morpheus-Linux ~ # 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_req=1 ttl=255 time=0.781 ms
64 bytes from 192.168.1.1: icmp_req=2 ttl=255 time=0.792 ms
64 bytes from 192.168.1.1: icmp_req=3 ttl=255 time=0.781 ms
^C
--- 192.168.1.1 ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 1999ms
rtt min/avg/max/mdev = 0.781/0.784/0.792/0.032 ms
Morpheus-Linux ~ # ping 192.168.1.2
PING 192.168.1.2 (192.168.1.2) 56(84) bytes of data.
^C
--- 192.168.1.2 ping statistics ---
4 packets transmitted, 0 received, 100% packet loss, time 2999ms
Morpheus-Linux ~ # ping morpheus
ping: unknown host morpheus
Morpheus-Linux ~ # ping microsoft.com
PING microsoft.com (64.4.11.37) 56(84) bytes of data.
^C
--- microsoft.com ping statistics ---
6 packets transmitted, 0 received, 100% packet loss, time 5040ms
Re: Cannot ping the host from the guest
Posted: 5. Jun 2013, 23:13
by Perryg
@Micheus ,
1) enable ICMP on the Windows host
2) On the guest you need to be using eth0 not eth1. Either edit the /etc/udev/rules.d/70-persistent-net.rules or you can delete the rules and Linux will configure it on the next boot
Re: Cannot ping the host from the guest
Posted: 6. Jun 2013, 22:59
by Micheus
Thank you
Perryg.
I can ping the host now, but only by IP. I think that there is anything else to be configured in order to be able to ping by the server name.
I need to access the
Firebird server (on
Windows), but I can connect to it by using the IP address without any problem.
___________
If I didn't have try ping by the IP address (192.168.1.2) yesterday I wouldn't believe that something strange happened today (maybe a Windows strange things, as usual

)
As I told in previous post, my
Windows' firewall was disabled, but I enabled it and added the rule for ICMP as you suggested and also I edited the file Linux you had pointed.
Then everything worked. So, as I found strange have to enable the firewall and get the ping working, I disable it again restated the linux and it was still working...
... at the end, I put back the eth1 where it was; restarted everything again and it still working.
Thanks again.
Re: Cannot ping the host from the guest
Posted: 6. Jun 2013, 23:08
by Perryg
Unless you have a DNS server to resolve friendly names you will need to use the IP or add the location and IP to the hosts file.
Re: Cannot ping the host from the guest
Posted: 9. Jun 2013, 19:34
by Micheus
Perryg wrote:you will need to use the IP or add the location and IP to the hosts file.
Thank you again.