Page 2 of 2 FirstFirst 12
Results 11 to 14 of 14

Thread: ubuntu router for 2 networks

  1. #11
    Join Date
    Feb 2009
    Location
    Singapore
    Beans
    Hidden!
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: ubuntu router for 2 networks

    Too bad then. You need that to work if you're not going to change the hardware setup.

    Else you need to add static route on individual computer in the 192.168.151.x network.

  2. #12
    Join Date
    Nov 2013
    Beans
    7

    Re: ubuntu router for 2 networks

    Quote Originally Posted by nebileix View Post
    2. Run
    Code:
    # /sbin/iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
    on ubuntu server. That was assuming you didn't have any DROP policy.
    how do I make this static/reboot-safe?

    Quote Originally Posted by nebileix View Post
    Too bad then. You need that to work if you're not going to change the hardware setup.
    Else you need to add static route on individual computer in the 192.168.151.x network.
    It's ok. Internet for 150.x was the goal. Everything else would be nice but not nessesary.

    I just wonder why 150 can ping 151 but 151 not 150?
    Last edited by Master-JCF; November 11th, 2013 at 03:37 PM.

  3. #13
    Join Date
    Feb 2009
    Location
    Singapore
    Beans
    Hidden!
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: ubuntu router for 2 networks

    To make it persistent across reboot:
    Code:
    # iptables-save > /etc/myiptables.conf
    Add "/sbin/iptables-restore < /etc/myiptables.conf" to /etc/rc.local.
    Please add it before the "exit 0" line.

    You might be interested to read up on routing and how it works.
    Last edited by nebileix; November 12th, 2013 at 02:07 AM.

  4. #14
    Join Date
    Nov 2013
    Beans
    7

    Thumbs up Re: ubuntu router for 2 networks

    thanks a lot for the fast help.

Page 2 of 2 FirstFirst 12

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •