dual network cards

Top Page
Attachments:
Message as email
+ (text/plain)
Delete this message
Reply to this message
Author: ShawnT.Rutledgerutledge@cx47646-a.phnx1.az.home.com
Date:  
Subject: dual network cards
On Wed, Apr 12, 2000 at 05:14:02PM -0700, Joel Dudley wrote:
> A newbie at my wits end!! Here is what I did. I installed red hat with
> the server option, thus I have no X. I put two Linksys NICs into the


Well I have two NICs too, here's my extra line from lilo.conf:

append="ether=9,0x350,eth0 ether=5,0x300,eth1"

for a pair of 3c509's. The kernel probably only detects the first one
unless you get these parameters right... but you should study the
bootup messages (type dmesg to see them again) to see if it really saw
both of them or not.

As for the config stuff, that's one of my gripes about redhat is the
way it separates the actual scripts from the configuration files that
control them... mine's just one script, /etc/init.d/network, which I
could tweak without having to worry about any other dependencies.

#! /bin/sh
ifconfig lo 127.0.0.1
route add -net 127.0.0.0

# The LAN
IPADDR=10.0.0.1
NETMASK=255.255.255.0
NETWORK=10.0.0.0
BROADCAST=10.0.0.255

ifconfig eth0 ${IPADDR} netmask ${NETMASK} broadcast ${BROADCAST}
route add -net ${NETWORK} netmask ${NETMASK} dev eth0

# Cox @ home
IPADDR="24.1.227.2"
NETMASK="255.255.255.0"
NETWORK="24.1.227.0"
BROADCAST="24.1.227.255"
GATEWAY="24.1.224.1"

ifconfig eth1 ${IPADDR} netmask ${NETMASK} broadcast ${BROADCAST}
route add -net ${NETWORK} netmask ${NETMASK} dev eth1
route add -host ${GATEWAY} dev eth1
route add default gw ${GATEWAY} metric 1

# Masquerade stuff
# ipfwadm -F -a m -S 10.0.0.0/24 -D 0.0.0.0/0
# ipfwadm -F -p deny
echo "1" > /proc/sys/net/ipv4/ip_forward
ipchains -P forward DENY
ipchains -A forward -s 10.0.0.0/16 -j MASQ


Of course they do it that way to make it easier to write GUI wrappers
to change the config files for you... but did they plan for two or more
ethernet adapters? At least if you can understand the ifconfig/route
commands, you can maybe decipher how to have it add more than one adapter.
As you can see it's only 2 or 3 commands for each one.

-- 
  _______                                     http://www.bigfoot.com/~ecloud
 (_  | |_)     finger 
 __) | | \__________________________________________________________________
 Get money for spare CPU cycles at http://www.ProcessTree.com/?sponsor=5903