Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

The problem has been solved. Now the Internet can be accessed from the namespace of external router as well as from the VM instances connected to the external router. The problem was that NAT was not enabled on the host machine, which is enabled by this command:

sudo iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE

Note: eth1 is the interface through which my host machine is connected to the Internet.

The problem has been solved. Now the Internet can be accessed from the namespace of external router as well as from the VM instances connected to the external router. The problem was that NAT was not enabled on the host machine, which is enabled by this command:

# sudo iptables -t nat -A POSTROUTING -o eth1 -j MASQUERADE

MASQUERADE

Note: eth1 is the interface through which my host machine is connected to the Internet.