Solved

Backup Network Connection

Posted on 2002-07-17
7
261 Views
Last Modified: 2013-12-27
Greeting,

I have Solaris servers and I want to connect every server to two Ethernet switches. That's mean I will have two Network Interface Cards (NIC) on every Solaris server.

The scenario that I want is as following:
if one of the two switches failed while the active Ethernet connection on the server is connected to it, the Solaris machine should switch the traffic to the other Ethernet interface (the backup interface)

So, I would like to know if this kind of back is possible. If not, how I can install backup network interface on the Solaris machine???

If this is possible, then how and what are the commands and I prefer both Ethernet interfaces to be in the same IP segment.

Please assist...
Thanks
0
Comment
Question by:omars
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
7 Comments
 
LVL 51

Expert Comment

by:ahoffmann
ID: 7160515
this is possible, and simple. The command you need is: ifconfig

Then you need to write a watchdog script, which periodicaly checks the connection, and switches to the backup NIC if the primary one failed. Somthing like:

   ping -c 1 -w 1 ip-NIC1
   if ($status == 1) then
      ifconfig le0 IP-le0 down
      ifconfig le0 0.0.0.0
      ifconfig le1 IP-le1 down
      ifconfig le1 IP-le0 up
   endif

I recommend to use different subnets for the 2 NICs.
0
 
LVL 2

Expert Comment

by:blowfish
ID: 7161272
Once you run the ifconfig commands, you will also need to change the default route.  

If you have services running like Apache, then they are probably listening on one or more virtual IPs configured on the card that went down.  You will probably need to maintain two configuration files in this case, and stop and start services each time you switch NICs.  

0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 7161354
oops, I missed the route stuff, thanks blowfish

About Apache, etc.: most services do not need to be restarted (as long as they are bound to IP, not NICs)
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:omars
ID: 7161826
Will this script affect the network speed or performance or the server performance since my servers are too busy.

Also, is this applicable for the firewall serevrs??

Thanks
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 7162077
> .. affect the network speed or performanc ..
depends on how you measure your performance.
In fact the script shuts down the network for a few milliseconds. But does this really matter, if the primary NIC already had gone (and so does not respond anything)?

> .. applicable for the firewall ..
depends on the firewall.
Most modern firewalls use packetfilters which can have rules depending on NIC and/or MAC. In this case it's best to stop and then restart the firewall service.
0
 
LVL 14

Accepted Solution

by:
chris_calabrese earned 200 total points
ID: 7162488
Actually, if your routers support Router Discovery Protocol, Solaris 8 and above can do this automagically without the need for special watchdog scripts. And it'll even balance the load through the two interfaces.

See http://www.sun.com/solutions/blueprints/0201/Multipathing.pdf
0
 
LVL 1

Expert Comment

by:k.kidambi
ID: 7163300
If you are running Solaris 8 then I would suggest Chris_calabrese way of doing the NIC teaming / multipathing.

Thanks
kidambi
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I have been running these systems for a few years now and I am just very happy with them.   I just wanted to share the manual that I have created for upgrades and other things.  Oooh yes! FreeBSD makes me happy (as a server), no maintenance and I al…
I promised to write further about my project, and here I am.  First, I needed to setup the Primary Server.  You can read how in this article: Setup FreeBSD Server with full HDD encryption (http://www.experts-exchange.com/OS/Unix/BSD/FreeBSD/A_3660-S…
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question