Can't ping to virtualbox instance [closed]
Asked Answered
V

2

9

I'm trying to set up the vagrant lucid32 box

The instance network setting is NAT

the virtual box instance can ping to the Mac, but can't vice versa

here is my Mac config

lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 16384
    options=3<RXCSUM,TXCSUM>
    inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1 
    inet 127.0.0.1 netmask 0xff000000 
    inet6 ::1 prefixlen 128 
gif0: flags=8010<POINTOPOINT,MULTICAST> mtu 1280
stf0: flags=0<> mtu 1280
en0: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 1500
    ether 10:9a:dd:a9:43:44 
    inet6 fe80::129a:ddff:fea9:4344%en0 prefixlen 64 scopeid 0x4 
    inet 10.32.24.78 netmask 0xffff0000 broadcast 10.32.255.255
    media: autoselect
    status: active
p2p0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 2304
    ether 02:9a:dd:a9:43:44 
    media: autoselect
    status: inactive
utun0: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> mtu 1380
    inet6 fe80::69ca:da35:534a:9504%utun0 prefixlen 64 scopeid 0x6 
    inet6 fd78:f3ab:2fb2:b8b8:69ca:da35:534a:9504 prefixlen 64 

And here is the virtual box network config:

enter image description here

Virgate answered 24/11, 2012 at 9:38 Comment(0)
C
6

It is quite obvious that when you are using NAT it will be impossible to ping host after NAT. It is how the NAT works... even if you will have real not virtual host the bechaviour will be the same.

Cacie answered 24/11, 2012 at 9:44 Comment(1)
It's like Vagrant only support NAT, is there a way I can work around it?Virgate
B
13

You need to change networking mode from NAT to bridged, and ping should start working in both directions.

Boson answered 24/11, 2012 at 9:42 Comment(0)
C
6

It is quite obvious that when you are using NAT it will be impossible to ping host after NAT. It is how the NAT works... even if you will have real not virtual host the bechaviour will be the same.

Cacie answered 24/11, 2012 at 9:44 Comment(1)
It's like Vagrant only support NAT, is there a way I can work around it?Virgate

© 2022 - 2024 — McMap. All rights reserved.