LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 06-14-2009, 02:23 AM   #1
swordphsh
Member
 
Registered: Sep 2008
Distribution: Ubuntu 9.04 X86_64 Desktop, 8.04 X86 Server
Posts: 33

Rep: Reputation: 15
Load Balancing with Dynamic IPs


I'm looking for a way to do something similar to the iproute2 (manual section 4.2. Routing for multiple uplinks/providers) load balancing, but with dynamic IPs. I'm using two cable modems.
I have been looking around, but everything seems to be geared towards static addresses, but this is not an option for me.

Any help is appreciated, thanks in advance.
 
Old 06-15-2009, 01:19 PM   #2
rweaver
Senior Member
 
Registered: Dec 2008
Location: Louisville, OH
Distribution: Debian, CentOS, Slackware, RHEL, Gentoo
Posts: 1,833

Rep: Reputation: 167Reputation: 167
Quote:
Originally Posted by swordphsh View Post
I'm looking for a way to do something similar to the iproute2 (manual section 4.2. Routing for multiple uplinks/providers) load balancing, but with dynamic IPs. I'm using two cable modems.
I have been looking around, but everything seems to be geared towards static addresses, but this is not an option for me.

Any help is appreciated, thanks in advance.
There is no good way to perform this unless you reconfigure and restart the load balancing each time an ip address changes.
 
Old 06-15-2009, 03:02 PM   #3
manwichmakesameal
Member
 
Registered: Aug 2006
Distribution: Slackware
Posts: 804

Rep: Reputation: 110Reputation: 110
Don't know about your isp, but mine NEVER changes my ip. They are given out according to the CPE mac address, so if you don't change your mac address on your router or whatever you have behind the modem, you could probably set it up like a static. You could throw in some error checking so IF your ip changes, you can just restart the load balancing.
 
Old 06-15-2009, 08:25 PM   #4
swordphsh
Member
 
Registered: Sep 2008
Distribution: Ubuntu 9.04 X86_64 Desktop, 8.04 X86 Server
Posts: 33

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by manwichmakesameal View Post
You could throw in some error checking so IF your ip changes, you can just restart the load balancing.
That could work. Do you have any suggestions on how to do that?
 
Old 06-15-2009, 08:34 PM   #5
manwichmakesameal
Member
 
Registered: Aug 2006
Distribution: Slackware
Posts: 804

Rep: Reputation: 110Reputation: 110
Take a look at here. It's actually niels.horn's site. Specifically:
Code:
# Get IP addresses of our devices:
ip1=`ifconfig $DEV1 | grep inet | awk '{ print $2 }' | awk -F: '{ print $2 }'`
ip2=`ifconfig $DEV2 | grep inet | awk '{ print $2 }' | awk -F: '{ print $2 }'`
You could modify that into some sort of script to check if it has changed, then restart whatever load balancing services you need.
 
  


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
Dynamic IPs agunhan Linux - Networking 1 03-01-2006 11:15 AM
Dynamic load balancing Dns sandeep3001 Linux - Networking 1 06-05-2005 09:28 AM
Earthlink blocks mail from dynamic IPs... Erik Thorsson Linux - Networking 6 09-14-2004 01:02 AM
Load Balancing? gsibble Linux - Networking 3 12-09-2003 10:39 PM
dns and dynamic ips, please help! myk3 Linux - Networking 2 11-17-2003 10:32 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 03:59 AM.

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
Open Source Consulting | Domain Registration