Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
static ip and lan issues.
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
dieboy
n00b
n00b


Joined: 29 Mar 2004
Posts: 13

PostPosted: Wed Nov 22, 2006 7:51 pm    Post subject: static ip and lan issues. Reply with quote

I have a newly installed gentoo machine on my network i'm trying to get up and running with two nics. For some reason and several hours later I can't seem to solve a simple problem. Kind of frustrating, regardless here it is.

Gentoo machine
eth0 - 10.0.0.3 subnet 255.255.255.0 (100mb linksys card)
eth1 - 10.0.0.4 subnet 255.255.255.0 (1000mb smc card)

All i am trying to do is have apache, ssh, and a handfull of other services that use net to nothing bandwidth use the .3 addy. And the samba and ftp to latch to the .4 addy for faster large file transfers. Both network cards are functioning fine.

So what's happening is the only card that i can get to do any packet moving at all is the .3 address. the .4 just sits idle. I even went so far as to bind my services to the correct addys, apache, ssh is on eth0 and samba, ftp is on eth1. Well in addition to not being able to get the .4 card to move packets, when i access the samba or ftp from a workstation elsewhere, it will route through the .3 address. I would think that since i bound the services to the eth1 and if it isn't moving packets why is it even defaulting to .3, shouldn't it not work at all?

Well obviosly i'm pretty new to having to actually problem solve in linux. So any help is greatly appreciated.

Here is my cpypste from /etc...../net file, let me know if more info is needed.
Code:
iface_eth0="10.0.0.3 broadcast 10.0.0.255 netmask 255.255.255.0"
iface_eth1="10.0.0.4 broadcast 10.0.0.255 netmask 255.255.255.0"
gateway="eth0/10.0.0.1"
[/quote]
Back to top
View user's profile Send private message
blu3bird
Retired Dev
Retired Dev


Joined: 04 Oct 2003
Posts: 616
Location: Munich, Germany

PostPosted: Wed Nov 22, 2006 8:11 pm    Post subject: Reply with quote

That's exactly what you want: http://home.regit.org/?page_id=20

But I'd go for bonding instead of dividing packets by port/l7.

Currently you've got 2 routing entries for 10.0.0.0/24 and every packet takes the first available which is always eth0(10.0.0.3). You could also add separat routes for specific ips but that's probably not what you are looking for.
_________________
Black Holes are created when God divides by zero!
Back to top
View user's profile Send private message
dieboy
n00b
n00b


Joined: 29 Mar 2004
Posts: 13

PostPosted: Wed Nov 22, 2006 8:33 pm    Post subject: Reply with quote

I understand what they are acomplishing on that page, it just seems like a huge pain just to route a couple ethernet cards to diffrent services. Being its all on the same network, there is no real pass through going on on the machine like a dhcp server etc. It was ridiculusly easy on my win03 servers at work, you think it wouldn't be that involved for linux as its a fairly common thing in small business networks.

I will give that a try if nothing else works out. Here I thought it was just my routing tables.

Thanks for the rply blu3bird, that is definatly what i'm trying to accomplish.
If anyone else has any ideas please let me know. Thanks :)
Back to top
View user's profile Send private message
Dan
Veteran
Veteran


Joined: 25 Oct 2005
Posts: 1302

PostPosted: Wed Nov 22, 2006 10:34 pm    Post subject: Reply with quote

Why use 2 network cards then?

why not?
config_eth0=(
"10.1.10.1 brd 10.1.10.255 netmask 255.255.255.0"
"10.1.10.2 brd 10.1.10.255 netmask 255.255.255.0" # eth0:1
"10.1.10.3 brd 10.1.10.255 netmask 255.255.255.0" # eth0:2
##"192.168.1.2 brd 192.168.1.255 netmask 255.255.255.255" # eth0:3
)
routes_eth0=(
"default gw 10.1.10.1"
##"default gw 192.168.1.1" #if you have multiple gateways
)

Then do as you have and bind web,dns,ssh to the specific ip's you want them to use...

If you need to have 2 cards for some reason then your problem is that eth1 doesn't have a route
so add one
routes_eth1=(
"default gw 10.1.10.1"
)

also you are using a depreciated syntax and probably should be getting a message at boot up about it... see /etc/conf.d/net.example should be using the syntax I have provided

EDIT: I just looked at it again and it looks like it has some more recent changes and additions.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum