LinuxQuestions.org
Review your favorite Linux distribution.
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 12-27-2003, 08:08 PM   #1
VioLaToR
Member
 
Registered: Aug 2002
Distribution: ArchLinux 2007.08 / Slackware 11.0
Posts: 58

Rep: Reputation: 15
Question 2 NICs / 2 WANs, 1 dynamic 1 static -- on Slackware 9.1


I need some help hooking up 2 WANs to 2 separate NICs:

I have been running 1 internet connection on my Linksys PCI card with a static address. the device is using eth0 and tulip.o driver. There has never been any problem with this device or the settings on it.

My computer has an onboard LAN port but it has always been disabled. I enabled it and booted up the machine and the onboard NIC took over eth0 and the linksys card took eth1.

I need to know how to make sure that the linksys card ALWAYS keeps eth0 and remains with a static IP address that i have set using netconfig. Even if i turn on the onboard LAN or add other PCI NICs, i want to make sure that the existing card never loses it's designation to eth0.

The onboard NIC will not always be enabled. i only use this on occasion, and i want to turn it off when i do not use it. the onboard NIC uses rhine.o driver.

When i do turn it on, i need to be able to have it obtain an address from the DHCP server. I want the onboard NIC to always use the next available net device (should always be eth1) instead of taking over the eth0 and screwing up my existing network settings.

I also need to know how to activate the eth1 and get the DHCP when the system is currently running. I know that ifconfig eth1 up will activate the device, but that does not get any DHCP from the broadcast address.

If i need to provide more information on what i need to do, and what is currently happening, i will do my best.

Last edited by VioLaToR; 12-27-2003 at 08:20 PM.
 
Old 12-28-2003, 12:00 PM   #2
phobox
Member
 
Registered: Dec 2003
Location: Columbus, OH USA
Distribution: Debian Knoppix Kanotix Sidux
Posts: 73

Rep: Reputation: 15
You could try setting the irq's for the nic's in the bios, if the interfaces are handed out by the kernel on the basis of that. As for not getting the dhcp broadcast on command, I don't know because mine does it.
 
Old 12-28-2003, 12:06 PM   #3
phobox
Member
 
Registered: Dec 2003
Location: Columbus, OH USA
Distribution: Debian Knoppix Kanotix Sidux
Posts: 73

Rep: Reputation: 15
Actually, I just remembered you can assign interfaces based on MAC addesses and that will ensure your pci nic will always have eth0
 
Old 12-28-2003, 06:28 PM   #4
VioLaToR
Member
 
Registered: Aug 2002
Distribution: ArchLinux 2007.08 / Slackware 11.0
Posts: 58

Original Poster
Rep: Reputation: 15
Quote:
Originally posted by phobox
Actually, I just remembered you can assign interfaces based on MAC addesses and that will ensure your pci nic will always have eth0
would you care to describe the method used to do such a thing?
 
Old 12-29-2003, 10:40 AM   #5
phobox
Member
 
Registered: Dec 2003
Location: Columbus, OH USA
Distribution: Debian Knoppix Kanotix Sidux
Posts: 73

Rep: Reputation: 15
Something like this...

http://www.mail-archive.com/linux-la.../msg01867.html

Last edited by phobox; 12-29-2003 at 11:15 AM.
 
Old 01-05-2004, 12:39 AM   #6
phobox
Member
 
Registered: Dec 2003
Location: Columbus, OH USA
Distribution: Debian Knoppix Kanotix Sidux
Posts: 73

Rep: Reputation: 15
Incidentally, there is a better way to assign network interfaces based on mac address here:

http://xenotime.net/linux/doc/networ...face-names.txt

based on /etc/mactab file.
 
Old 02-24-2004, 07:17 PM   #7
VioLaToR
Member
 
Registered: Aug 2002
Distribution: ArchLinux 2007.08 / Slackware 11.0
Posts: 58

Original Poster
Rep: Reputation: 15
i have played with the stuff in those two links, and i really have no idea how to make that work. those were for redhat systems, and i do not know the equivalencies of the stuff it was talking about. I tried to place the reference to nameif, and the /etc/mactab that i created, into /etc/rc.d/rc.inet1 and that did not work out for me.

/etc/rc.d/rc.inet1: line 99: nameif: command not found
nameif: reports error

that is what it tells me now. apparently that method is not for my slackware box.

I really could use some help to keep my NICs from changing eth# when i activate the backup NIC.

Thanks for the sources so far.
 
Old 03-02-2004, 02:28 AM   #8
phobox
Member
 
Registered: Dec 2003
Location: Columbus, OH USA
Distribution: Debian Knoppix Kanotix Sidux
Posts: 73

Rep: Reputation: 15
Here's a different explanation:
http://www.linuxfromscratch.org/hint...les/nameif.txt

I'm not sure why it's not finding nameif, since it is part of the basic networking system for linux, not specific for any distro. Maybe try the full pathname (/sbin/nameif for my debian system.)
 
Old 03-02-2004, 03:53 AM   #9
VioLaToR
Member
 
Registered: Aug 2002
Distribution: ArchLinux 2007.08 / Slackware 11.0
Posts: 58

Original Poster
Rep: Reputation: 15
nameif does not exist in my filesystem at all.

/etc/rc.d/init.d/network does not exist in my filesystem.

/etc/sysconfig does not exist as a directory or a file.

By now i am sure you are fed up with me on this topic, but i just can't get this done.

I have checked several other files hoping for the correct equivalents:

/etc/networks
/etc/rc.d/rc.inet1
/etc/rc.d/rc.inet2

Those didn't have the proper things in them either.

Am i just out of luck?

thanks again for your help.
 
Old 03-03-2004, 02:30 AM   #10
phobox
Member
 
Registered: Dec 2003
Location: Columbus, OH USA
Distribution: Debian Knoppix Kanotix Sidux
Posts: 73

Rep: Reputation: 15
Looks like you need to install the net-tools. Here is a link describing what exactly that is:

http://www.faqs.org/docs/linux_scrat...net-tools.html

and it also has a link to where you can download it's sources.

Also, here is a small description to help if you need to manually create a sysconfig directory:

http://www.comptechdoc.org/os/linux/...sysconfig.html

Last edited by phobox; 03-03-2004 at 02:36 AM.
 
Old 03-03-2004, 04:15 PM   #11
VioLaToR
Member
 
Registered: Aug 2002
Distribution: ArchLinux 2007.08 / Slackware 11.0
Posts: 58

Original Poster
Rep: Reputation: 15
i installed net-tools.

but there is a problem now. there are config files somewhere in my system already or it would not be working now. so i'm not going to start making conflicting files in /etc/sysconfig and really mess things up.

I tried using only the mactab and nameif but that fails. I need to rename the devices in the existing network configuration files. any idea where those are? They have to be in there somewhere or the devices would never work at all.

When i added a line to call on nameif, i put it in /etc/rc.d/rc.inet1 thinking that might get it early enough to work.

When i rebooted the system with the primary and the secondary NICs turned on, the primary was lost, and the secondary was once again eth0

still scratching my head and losing my mind. some slackware guys would sure be nice to see up in here!
 
Old 03-03-2004, 08:53 PM   #12
Darin
Senior Member
 
Registered: Jan 2003
Location: Portland, OR USA
Distribution: Slackware, SLAX, Gentoo, RH/Fedora
Posts: 1,024

Rep: Reputation: 45
/etc/rc.d/init.d/network and /etc/sysconfig are redhat/mandrake config files. Slackware uses a different type of config with simpler startup scripts in /etc/rc.d.

Anyhow, for Slackware try looking in /etc/rc.d/rc.netdevice or /etc/rc.d/rc.modules for the lines that load your ethernet modules rhine and tulip, if you are lucky just switching those around will make the onboard NIC be eth1. Another suggestion that may be a better way to do it is to edit /etc/modules.conf (if it is empty thats OK, if it doesn't exist make it 'touch /etc/modules.conf') and add lines:
alias eth0 tulip
alias eth1 rhine
(or whatever the actual network modules are called, the module names should be in your rc.netdevice and/or rc.modules files)
 
  


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 IP to Static Temujin_12 *BSD 2 06-10-2005 04:58 PM
Static vs Dynamic Big Al Linux - Networking 2 12-08-2003 03:10 PM
NS with static or dynamic IP cijunet Linux - Networking 3 05-08-2003 11:04 PM
Two DSL lines - Two static IP - Three NICS - can I capitolize? fmotta Linux - Networking 1 03-14-2003 10:42 AM
Static/dynamic linking ugenn Linux - Software 0 12-15-2002 11:01 PM

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

All times are GMT -5. The time now is 06:34 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