LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 09-17-2004, 12:18 PM   #1
familyman
LQ Newbie
 
Registered: May 2004
Distribution: Redhat/Debian
Posts: 10

Rep: Reputation: 0
One Web Server on Multiple Internet Connections


I want to put up a webserver in my office. We have one DSL with a static IP. This DSL has gone down before and I don't want that to affect the availability of my site, so I thought I could bring in another DSL from a different provider (ensuring that one is not reselling the other's services) and allow the web server to be available on both lines.

My Question is: would the following scenario work?

Associate ns1.blah.com and ns2.blah.com with mydomain.com

Point ns1.blah.com to the IP for one of my DSLs
Point ns2.blah.com to the other IP

Set up BIND on my server and put both DSL lines into it.

From what I read, the top level DNS servers should send clients to ns1.blah.com half of the time and ns2.blah.com the other half. If one of my DSLs goes down and the other one is up. All traffic should go through the working DSL.

It would be great if you could help me by telling me if you think this would work. Links to related articles would be great! THanks,
 
Old 09-17-2004, 03:32 PM   #2
zatriz
Member
 
Registered: Aug 2003
Location: Seattle, Wa
Distribution: Fedora,Trustix,Debian
Posts: 290

Rep: Reputation: 30
What you are probably want to do rather than have two seperate dns entries is to setup round robin dns.
What that will do is you supply two ip address for the same domain name like google.com or microsoft.com

So that the switch is automatic and if you apply a different ip to just the secondary dns then sometimes the the cache of some isp might not get update they they will be left with the resolve results of the primary when its down.

Where ever you are hosting your dns ask them if they support round robin dns, bind does so you can set it up on your server if you wanted.

example:
http://www.akadia.com/services/dns_round_robin.html

Last edited by zatriz; 09-17-2004 at 03:38 PM.
 
Old 09-17-2004, 07:41 PM   #3
familyman
LQ Newbie
 
Registered: May 2004
Distribution: Redhat/Debian
Posts: 10

Original Poster
Rep: Reputation: 0
Thank you for your reply.

I've registered my domain name through godaddy.com. I just checked and it looks like it allows me to add multiple hosts (blah.mydomain.com, blah2.mydomain.com) and their cooresponding IP address to my domain name. Does this mean that godaddy does support round robin? Is there a way to check and test for round robin support besides getting 2 DSLs and just trying it?

Thanks again for the support. I love you guys (tears well up as I write this).
 
Old 09-18-2004, 06:00 PM   #4
zatriz
Member
 
Registered: Aug 2003
Location: Seattle, Wa
Distribution: Fedora,Trustix,Debian
Posts: 290

Rep: Reputation: 30
The easiest way to check if you have round robin support is to enter a host name and enter two ip's for it
like this
create an A record for www.server.com to 192.168.0.1
and then create another A record to www.server.com with ip 192.168.0.2
so both records should be called www.server.com or just www

You dont need to have two ip to test round robin if the dns server accepts the entries and it will go through remember that you will have to adjust your settings like TTL to a low number.
 
Old 09-18-2004, 06:28 PM   #5
linux_terror
Member
 
Registered: Aug 2004
Location: Northbrook, Illinois
Distribution: CentOS-5
Posts: 311

Rep: Reputation: 30
The best way to assure that you have round robin is to host the DNS yourself, I do exactly what you are trying to accomplish with 2 servers that are in different parts of the country. This is How I accomplish it...

Install BIND(named) 9.x.x it has round robin automatically.
Change your parent servers dns to just point at your nameserver, eg- NS1.EXAMPLE.COM and NS2.EXAMPLE.COM and define one of the DSL IP addy's for each.

Add a master zone for your TLD(top level domain) with a record that looks similar to this
Code:
$ttl 38400
example.com.	IN	SOA	ns1.example.com whoever.example.com. (
			1092506603
			3700
			3600
			604800
			38400 )
example.com.	IN	NS	ns1.example.com.
example.com.	IN	NS	ns2.example.com.
example.com.	IN	A	first dsl connections ip address
example.com.	IN	A	second dsl connections ip address
www.example.com.	IN	CNAME	example.com.
ns1.example.com.	IN	A	first dsl connections ip address
ns2.example.com.	IN	A	second dsl connections ip address
this defines your TLD and your nameservers, and adds a canonical name for www. so www.example.com will be directed to example.com

Now on failover or in the event of an outage if the clients browser does not get a reply from one IP it will automatically try the other.

Have fun,
linux_terror
 
Old 09-18-2004, 06:38 PM   #6
linux_terror
Member
 
Registered: Aug 2004
Location: Northbrook, Illinois
Distribution: CentOS-5
Posts: 311

Rep: Reputation: 30
An afterthough....you also should port forward port 53 tcp and udp to your linux box on BOTH dsl connections so that your nameserver can be queried, and on my router I had to enable anonymous requests from the internet as well, and make sure your webserver is listening on all addy's e.g --> *:80


cheers,
linux_terror
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Help for a newbie about multiple internet connections lazza79 Linux - Networking 0 01-03-2005 04:24 AM
Web Server Refusing Connections zoso Linux - Networking 2 12-27-2004 11:41 AM
Multiple internet connections kojie Linux - Networking 2 12-08-2004 03:19 PM
Multiple Internet connections (Broadband and Dial up) MadLee Linux - Hardware 0 04-11-2003 05:54 PM
Linux server on multiple internet connections gt50 Linux - Networking 1 02-24-2002 05:16 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 11:44 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration