Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I want the following setup:

Internet ---- Cable modem
                   |
                   |
                   +--- Router A ---- PC
                   .
                   .
                 (wifi) . . . . [PC, tablet, etc.]
                   .
                   .
            HTPC Linux Mint 15
                   |                 +---- TV
                   |                 |
                   +--- Router B ----+---- PS3
                                     |
                                     +---- Receiver

I currently have internet access at HTPC through wifi from Router A.

I want to have internet access for HTPC and devices after Router B.

As of now I don't care that devices after Router B see devices before Router B.

I would like to know how to get internet access for devices after Router B, while keeping internet access of HTPC. HTPC might occasionally pull internet content through OpenVPN.

I tried [Networks Settings] => [Wired] => [Options] => [IPv4 Settings] => [Method:] = "Shared to other computers" on HTPC Linux Mint 15, but it didn't work. I don't know anymore where to look to find a solution, if any.

share|improve this question

migrated from serverfault.com Aug 17 '13 at 23:49

This question came from our site for professional system and network administrators.

add comment

1 Answer

You probably want HTPC to become the actual router for the stuff currently behind router B.

You should degrade RouterB to a switch, i.e. don't put anything into the uplink port, just put everything (including HTPC) into the normal switch ports of the device.

Then configure HTPC to do the routing and NATting for you. If you don't want to touch the devices (TV/PS3/...) you give HTPC the same IP than RouterB had before.

A few steps on what to do on HTPC to make it the router:

Turn on ip forwarding

echo 1 > /proc/sys/net/ipv4/ip_forward

Create the NAT and configure the firewall (ask Google for details)

iptables -t nat -A POSTROUTING -o wlan0 -j MASQUERADE

(wlan0 = whatever your wifi interface is called)

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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