Ubuntu server running VirtualBox has globally-visible routable static IPs N->N+5 available to it. It is using IP N itself, and has lovely internet access via IP Q (on a completely different subnet, same ethernet card)
A virtual machine is created with Bridged networking to eth0, using IP N+1.
It is accessable from the internet via RDP to the *host server* because VirtualBox does that, and that means I'm connecting to the host, not the VM.
It is accessable via ping and SSH *from* the host server, via IP.
It can ping and ssh *to* the host server, via IP.
It can't go further than the host server and nothing from the outside can get to it.
"route -n" on the host and the VM produce sensible-looking results that perfectly match a working identical configuration (with different IPs, of course)
This is a fresh install, on a brand new machine.
Telling the host server that *it* is IP N+1 (or 2, or 3, or whatever) results in perfectly good network access to and from those IPs.
Any ideas?
EDIT: The problem is definitely routing of some sort. The host happily bounces out via IP Q, traceroute from the outside to N goes in to N via Q no problem - but the virtual machine can't ping Q. So when then VM is connecting to the outside world, it goes to N (it's gateway), then the host doesn't pass that along to Q and out to the intertubes.
EDIT2: IPv4 Packet Forwarding in /etc/sysctl.conf FTW.
Fixed it myself. I love you guys, sometimes just ASKING the question is enough to jog me through figuring out where to look.
A virtual machine is created with Bridged networking to eth0, using IP N+1.
It is accessable from the internet via RDP to the *host server* because VirtualBox does that, and that means I'm connecting to the host, not the VM.
It is accessable via ping and SSH *from* the host server, via IP.
It can ping and ssh *to* the host server, via IP.
It can't go further than the host server and nothing from the outside can get to it.
"route -n" on the host and the VM produce sensible-looking results that perfectly match a working identical configuration (with different IPs, of course)
This is a fresh install, on a brand new machine.
Telling the host server that *it* is IP N+1 (or 2, or 3, or whatever) results in perfectly good network access to and from those IPs.
Any ideas?
EDIT: The problem is definitely routing of some sort. The host happily bounces out via IP Q, traceroute from the outside to N goes in to N via Q no problem - but the virtual machine can't ping Q. So when then VM is connecting to the outside world, it goes to N (it's gateway), then the host doesn't pass that along to Q and out to the intertubes.
EDIT2: IPv4 Packet Forwarding in /etc/sysctl.conf FTW.
Fixed it myself. I love you guys, sometimes just ASKING the question is enough to jog me through figuring out where to look.
