I'll have to check into iproute2. Seems interesting...won't be able to try until tonight (after I get home), but will certainly share the results.
Thanks, Ben. --- Sean <[EMAIL PROTECTED]> wrote: > I've done this sort of thing before, but never with one interface > running dhcp. You definitely want to emerge iproute2 (which gives you > > the ip command), and add your interfaces to /etc/iproute2/rt_tables, > for > example (though in this case, 10 eth0 won't actually get used): > > 10 eth0 > 11 eth1 > 12 eth2 > > Then in /etc/conf.d/net, put: > > modules_eth0=("iproute2") > modules_eth1=("iproute2") > modules_eth2=("iproute2") > > config_eth0=("dhcp") > > config_eth1=("10.0.0.{1-10} netmask 255.255.255.0 broadcast > 10.0.0.255") > rules_eth1=("from 10.0.0.0/24 src table eth1") > routes_eth1=("10.0.0.0/24 src 10.0.0.1 table eth1" > "10.0.0.0/24 src 10.0.0.2 table eth1" > *** and so on ***) > > Then do the same kind of thing for eth1. Now, I also seem to remember > > that I had another system that I just did everything with the ip > commands in rc.local. And since you're also using dhcp, I don't know > if > that will muck with the routing tables everytime the IP renews > itself. > > Hope that helps. (Also, I seem to remember finding a decent amount of > > information about multihoming with iproute2 on the gentoo forums) > > -Sean > > BRM wrote: > > Ok, first - I wasn't sure which list this should go to, so if this > is > > the wrong list please just let me know. > > > > I am in the process of upgrading my server from a P90 running > Slackware > > to a "newer" system running Gentoo 2007.0. Everything is pretty > okay > > until I got to doing the network config. My basic config is as > follows: > > > > Public DHCP'd Interface -> eth0 (default gw) > > Private Lan Interface #1 -> eth1 > > Private Lan Interface #2 -> eth2 > > > > I also have a number of IP Aliases on the eth1 & eth2. I managed > this > > under Slack through a series of custom rc scripts, which > autodetected > > the IP address of eth0 for use in the routing. However, I am having > > trouble figuring out how to do the same thing in Gentoo's > conf.d/net > > file system. > > > > Thus far, in /etc/conf.d/net, I have the following: > > > > config_eth0("dhcp") > > > > config_eth1(<list of static IP addresses>) > > > > config_eth2(<static ip address>) > > > > I also had a route line for eth1 and eth2, but it specified the IP > of > > eth1, not eth0 - which is unknown. > > > > I've tried the following: > > > > route_eth1("default via ${COMMAND_STRING_TO_EXTRACT_IP_OF_ETH1}") > > > > which kinda works (it does get the IP address, but fails with at > adding > > the route - I'm not at the system right now, so I'll have to post > the > > specific SIG name later); however, I am very much doubting that > that is > > the right way to do what I want under Gentoo. > > > > So, my primary question is: > > > > What is the proper way to do this under Gentoo? > > > > I know I could just go and manually write versions of > > /etc/init.d/net.eth1/eth2, but I'd rather do it the right way if > there > > is one, and only do that as a last resort. (And even then, wouldn't > I > > be risking the Gentoo Configuration system replace them with > symlinks?) > > > > Any how...any advice on the proper way to do this would be greatly > > appreciated. I really like Gentoo and really do want to keep - I > use to > > keep Slack up-to-date manually, and just don't have the time for it > > anymore, which is why I'm trying Gentoo. > > > > Thanks, > > > > Ben > -- > [EMAIL PROTECTED] mailing list > > -- [EMAIL PROTECTED] mailing list