1

I have the following equipment, which I want to connect as described to two ISPs.

1 internet server - ubuntu 16.04 - to ISP 1

2 content creator - win7 - to ISP 1

3 HTPC - ubuntu 16.04 - to ISP 2

4 Sony BluRay player - to ISP 2

5 admin - ubuntu 16.04 - to ISP 1 -- needs to mount drives from computers 1, 2, and 3, admin both routers, and be a file server to HTPC.

I think what I may need is to connect it all to a switch, but I don't have one to test. Another possibility might be extra lan cards, or wireless cards.

What would be best, and are there any pitfalls I need to avoid in the topology?

If I need to supply any more info I'll be happy to do so.

Speaking of which, as a pre-edit if you will, everything is in one 16x16 room, mostly on one wall.

ISP 1 is suitable for the server, whereas ISP 2 will not provide a properly formatted reverse DNS. AOL and Comcast mail servers insist on that.

ISP 2 gives me more bandwidth, so that Netflix etc. don't detract from our customers' experience.

Both routers are set to 192.168.0.1, but that can change, of course.

5
  • 1
    I would say put each ISP router on separate/different subnets and then setup routing rules in between to route between the subnets. Just use the IP address for each ISP router as the defauly gateway address for the NICs on each of the devices. Commented Jul 16, 2017 at 21:32
  • It sounds like that might work, but sadly I don't know how.
    – Catweasel
    Commented Jul 16, 2017 at 21:40
  • What's the intent of the two ISPs? Is it for failover? Load balancing? Lower latency to certain hosts? Using connections based on connection type (e.g., your servers might only work on one of the two)? Getting an extra public IP address for your devices? Something else? (This impacts what you need to do/the complexity)
    – lungj
    Commented Jul 16, 2017 at 23:08
  • What are the current IP addresses to each of the ISP routers? What is this now? If you don't know this at least you're stuck until you get someone that does. Commented Jul 16, 2017 at 23:08
  • I still need an answer. I've added clarifications, @lungj
    – Catweasel
    Commented Jul 23, 2017 at 19:44

2 Answers 2

1

You've been given some good information. But there is a more straight forward route here.

You mentioned both routers are on 192.168.0.1. Change the router for ISP 2 to 192.168.0.2 or some other unused IP address in this same range. Disable DHCP on this second router.

Connect everything together via a switch. Or if you have enough ports just connect both routers together by adding a cable between their LAN ports.

Next, change the default gateway on each machine (assuming they are all using a statically assigned IP) so that machines that need to use ISP 1 use 192.168.0.1 and machines that need to use ISP 2 use 192.168.0.2.

You'll have to make sure all devices are using a unique IP address on the network. Also make sure only one DHCP server is active.

Now, all devices can see each other on the same network but each machine will use whatever ISP you choose depending on it's gateway setting.

There aren't any drawbacks I can think of. This is a simple approach and gives you the flexibility to change an ISP assigned to a machine quickly. There is nothing wrong with having two routers on the same network.

3
  • I think this is a good approach for a small network and may well be the best solution for OP (I'm still not exactly sure what OP's situation is). I can think of a few drawbacks, if you want to edit your answer to include them: lack of partitioning (if desired); need to reconfigure machines individually instead of a centralized point (this even more annoying in a heterogenous network) -- although running a DHCP server with custom configurations can largely solve this at the expense of initial complexity and the need to reload DHCP configurations;
    – lungj
    Commented Jul 24, 2017 at 6:00
  • options for server redundancy reduced/non-existent; and inability to use both Internet connections simultaneously on the same machine for different purposes. If OP doesn't need these things, you're right: this is a better approach.
    – lungj
    Commented Jul 24, 2017 at 6:02
  • Your comment is valid, but based on the content of the question, this is a small network and the OP already had these drawbacks. There are certainly "enterprise" solutions but what I posted is just one simple approach that directly answers the question. Commented Jul 24, 2017 at 6:11
0

Not sure what you mean by "customers"; I will assume you mean people trying to access your server (as opposed to you offering a hotspot to customers like Starbucks). I'm assuming you have no switches and two routers from your ISPs that have sufficient LAN ports. I'm also assuming your routers are sufficiently fast for your LAN needs (so gigabit Ethernet if you need it).

In all cases, you'll want to have two different networks for the routers. Say, 192.168.0.1/24 for the router for ISP 1 and 192.168.1.1/24 for ISP 2. If you don't do this, you'll either end up with headaches or end up in an impossible-to-resolve situation.

Low cost + easiest to configure

"Best" in terms of cost and ease is probably to use a spare network port on machine 5 (install a network card if necessary) and connect it to the router for ISP 2. Then, you can either set a higher route cost for the second router to make the Internet fail over to it if necessary or just configure the Ethernet port for the LAN subnet. The benefit of this is that it's as simple as plugging in an extra network connection (and card) plus configuration on one machine. It also maintains a semblance of separation between your two LANs so long as machine 5 is not compromised, which you may want for security purposes. If you wish to bridge the two networks, you can configure machine 5 to act as a router; your success will depend on your ISPs' routers configurability.

Balance between cost + flexibility

A good balance between cost and flexibility is to get a third router with at least three network ports (one where you have full control over routing, not something like a consumer wi-fi router, unless you plan to flash some custom firmware on) and a switch. The router should be configured to have two gateways -- ISP 1 and ISP 2. Then, create a third LAN segment that all your machines are connected to and then use the switch to connect all your devices to your router. It's cheaper and easier to get a switch with many ports than it is to buy a router with the same number of ports.

Continuing with the configuration of the balanced configuration... based on your edit, I think a good configuration would be to have ISP 2 have a lower route cost than ISP 1 so that ingoing and outgoing connections use it by default. On router 3, you should be able to set inbound traffic on the ISP 1 LAN (which is only connected to the router) to go to your server. You probably need to set an SNAT rule so that server-related traffic from machine 1 goes to ISP 1; I'm assuming the reverse-DNS issue is related to anti-spam measures and thus the outbound traffic IP address is important. Lastly, use QoS on router 3 to ensure important traffic is prioritized. The benefits of this topology are that all your machines can "see" each other and can be expanded on the cheap. You can also do virtual reconfiguration of the network if you have different needs in the future. Types of configurations you can do include creating separate LAN segments for security (using VLANs), QoS to prioritize different traffic, and reconfiguring iptables (or whatever is used on your router) if you add/remove/change your server setup. You may wish to get a switch that supports VLANs for future-proofing if you think that's in the cards.

The downside is your storage network shares the same physical connection as your other services; you may not want this. Ditto remote management systems like IPMI.

If you're looking for a low-cost router, I can recommend Ubiquiti's EdgeRouter X. I've been using three of them trouble-free since January (two in different roles in a small business setting and one at home). I can vouch that the ER-X can run the second configuration I described above: I've successfully configured one of the business routers to run several services over different IP addresses to various virtual machines, all with their own IP addresses; I also (sadly) had the opportunity to test my home network's ability to run dual ISP connections today since my regular ISP's connection is down and I've failed over to a cellphone data plan. I am not in any way affiliated with Ubiquiti.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .