How shall i configure the following scenario:

  1. I had 1 host windows machine with 2 NICS and fedora installed on oracle virtual box.

  2. I had 2 routers one configured for internet and other for local network.

  3. I want the host machine should access first router with internet.

  4. And Oracle virtual box with fedora should access the local network / or access both the networks.

How should i achieve this ?

  • You wanna do it by changing you router's routing table or by adding rules to your firewall? Explain a bit more, it's not crystal clear.
    – user172564
    Aug 6, 2016 at 8:51
  • updated the question.
    – Curious
    Aug 6, 2016 at 9:01
  • 1
    If you have nothing to do with firewall, you can just set different gateways for each OS, or if both are first connected to the first router which is connected to network, you can set a rule so it'll redirect your Fedora to the other. I hope it could be helpful.
    – user172564
    Aug 6, 2016 at 9:07

1 Answer 1


You can add additional route to local network via secondary router. To do it create new configuration file in virtual machine via command: echo " via" › /etc/sysconfig/network-scripts/route-eth0.cfg Where is local network, eth0 is name of network interface on virtual machine and is IP address of secondary router, which is in same network with your host machine. This method will work only if you create bridged interface for virtual machine in oracle virtual box. In other cases, please show more details about your routers and networks.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.