2

I've got a strange situation, I have a server that is connected to an old static IP on a totally different gateway, dns, subnet and a new static IP again with a new gateway dns subnet. I also have about 50 domains pointed to the old IP, I want to make this as seemless as possible so is there a way to activate both connections on one nic? Here is a little diagram of the network topology:

2 Internet Connections go into switch ==> One line comes off switch and into server(Everything is layer 2 only)

Al Katawazi
  • 233
  • 3
  • 11
  • If you'd like a more detailed answer, please provide details on what operating system you are using. – Tom Shaw Jun 03 '11 at 13:42
  • If you're running Linux it's actually pretty easy. You'll just need to run `ifconfig eth0:1 11.22.33.44`, then configure the gateway via `route` and everything should be working. Of course you need to be able to connect to the 2IP addresses from that cable you're plugging inside the nic. – tftd Jun 04 '11 at 02:45

2 Answers2

3

Yes, use vLans to connect both networks to the same NIC on the server.

Chris S
  • 77,337
  • 11
  • 120
  • 212
  • 2
    That's probably best from a security point of view, but it *is* possible to have multiple subnets on the same vlan. – Tom Shaw Jun 03 '11 at 13:41
  • but multiple default routes? :) – SpacemanSpiff Jun 03 '11 at 14:01
  • 1
    @Spaceman, no multiple default routes (on different networks) will break a normal Windows machine. – Chris S Jun 03 '11 at 14:02
  • well, it shouldn't break it, each adapter is given a metric so... the first one will win – SpacemanSpiff Jun 03 '11 at 14:06
  • 1
    @Spaceman, more likely than not, both NICs will have the same metric. I've seen this break machines frequently. It's an invalid configuration and newer versions of Windows specifically warn you as such if you try to configure it. – Chris S Jun 03 '11 at 14:11
  • Just one point though, in windows the server will only use one nic and 1 ip unless explicitly specified. I guess it operates in fail over not load balancing mode since it considers the internet the same network. – Al Katawazi Jul 06 '11 at 01:08
  • Correct, Windows, without additional software, can only have one default gateway. All outbound traffic will use it. – Chris S Jul 06 '11 at 01:13
1

Yes, this is called IP Aliasing.

If you want your system to be smart about routing (to avoid the problems with multiple default routes or asymmetrical routing), you can use policy-based routing.

Tom Shaw
  • 3,702
  • 15
  • 23