I have the following set up

Host OS: windows 10
Guest OS: Ubuntu 20.04

I'm using cisco anyconnect on my host to access intranet resources that I can also access from my virtualbox with standard NAT in VBOX when my host's VPN is enabled. But I cannot access the internet with NAT when either VPN is on or off. Bridged mode does not seem to to fufill this either. It seems only bridged network type can give my VM internet access but running both adapters simultaneously seem to not give intranet access while giving internet access.

  • Make sure your VPN client allows for Split Tunneling. I think Cisco Any Connect does but either it or the server needs to be set up.
    – John
    Feb 10, 2022 at 19:49

1 Answer 1


Have you tried to enable natdnshostresolver for your adapter? I mean these steps:

  1. Shutdown your VM;
  2. In VM's settings choose network adapter type as "NAT";
  3. On the host machine execute these commands via cmd:
"C:\Program Files\Oracle\VirtualBox\VBoxManage" list vms

//copy id of your VM
"C:\Program Files\Oracle\VirtualBox\VBoxManage" modifyvm 738ea131-a9cf-4511-a623-f927ada9801a --natdnshostresolver1 on

//where in place of 738ea131-a9cf-4511-a623-f927ada9801a paste copied id.

FYI In parameter natdnshostresolver1 1 means number of the adapter, so if you have multiple adapters added in your VM's settings, specify correct number in the aforementioned command.

  1. Connect to Anyconnect VPN on the host machine;
  2. Start your VM to check if that helped.

If it won't help, shutdown VM, additionally execute aforementioned command with --natdnsproxy1 on parameter instead of --natdnshostresolver1 on, thus you will got both parameters enabled, start VM.

If you also need to keep local network connection between host and VM, add second adapter with bridged type. If that doesn't help try deleting all adapters, then add first adapter as bridge, second as NAT, then repeat steps 1-5 for NAT adapter (on step №3 don't forget that it has number 2 now).

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .