5

I'm running Ubuntu 13.04 32bit. I'm trying to accomplish something that I'm sure is simple. I have two NIC's installed on my PC.

  • eth0 - connected to office network with static IP.
  • eth1 - connected to Internet via router with DHCP.

I would like to have all regular Internet traffic going through eth1 and all internal office stuff going through eth0. From what I have read online so far, I understand that I need to setup a static route. Can anybody instruct me on how to do this?

2

The link to the geekstuff.com article is a very good explanation but does not describe exactly how to do this for a dual-homed scenario.

Assuming:

eth0 - office network with static IP address (10.x.x.x addresses); eth1 - Internet connection via router with DHCP (172.168.1.x addresses)

The following worked for me:

sudo route add -net 10.0.0.0 netmask 255.0.0.0 gw 10.14.21.1 dev eth0
sudo route del default gw 10.14.21.1
sudo route add default gw 172.168.1.1 dev et

In my case, Internet access was needed temporarily, so the appropriate files were not modified to make this permanent.

0

Take a look at this article. It describes a scenario similar to what you intend to implement and explains in brief some of the basic concepts behind networking.

0

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.