LinuxQuestions.org
Support LQ: Use code LQCO20 and save 20% on CrossOver Office
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
 
LinkBack Search this Thread
Old 06-02-2003, 05:52 PM   #1
jweiss
LQ Newbie
 
Registered: Jun 2003
Posts: 1

Rep: Reputation: 0
Redhat 8.0 2 NIC Cards, trying to failover


Hello,

I am running Redhat 8.0 with 2 separate NIC cards. I have assigned them each a differen IP address and everything is fine. But...I would like them to failover, so if one network connection is lost the other network adapter takes over... I can do this manually, but I would like to know if this is possible to automate. Thanks I look forward to hearing an answer.

Jeremy
jweiss@thinkorswim.com
 
Old 06-03-2003, 04:08 PM   #2
david_ross
Moderator
 
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 58
I would probably write a script and stick it in a cron job. something like:
Code:
#!/bin/bash
ping OTHER_HOST -c 3 -w 5 > /dev/null
if [ $? == 1 ]; then
mv /etc/sysconfig/network-scripts/ifcfg-eth0 /etc/sysconfig/network-scripts/ifcfg-eth-temp
mv /etc/sysconfig/network-scripts/ifcfg-eth1 /etc/sysconfig/network-scripts/ifcfg-eth0
mv /etc/sysconfig/network-scripts/ifcfg-eth-temp /etc/sysconfig/network-scripts/ifcfg-eth1
service network restart
fi
It may need tweaking but it will give you a start.
 
  


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
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Add more NIC cards nkutty Linux - Networking 1 08-05-2005 11:02 PM
nic failover help cambie Linux - Networking 2 01-12-2005 09:41 AM
No Networking on Redhat 9.0!!! ; unable to initialize NIC cards smadny Linux - Hardware 3 01-19-2004 05:15 AM
Networking with 2 Nic Cards FXRS Fedora 2 12-06-2003 07:35 AM
NIC Cards Not Working bennieblanco Linux - Networking 0 07-20-2003 10:17 PM


All times are GMT -5. The time now is 10:05 AM.

Main Menu
 
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
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration