[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: eth between two computers



Hi,


> I put in the laptop a linksys PCMPC100 an it got recognized immediately.
> I put in the desktop-machine a linksys LNE100TX, compiled the supplied 
> drivers and put the results pci-scan.o and tulip.o into 
> /lib/modules/2.2.17/net.
> 
> >ifconfig 192.168.0.3 eth0 up at one side and
> >ifconfig 192.168.0.1 eth0 up at the other side.
> 
> 
> Then I checked:
> ROOT> route
> Kernel IP routing table
> Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
> 192.168.0.0     *               255.255.255.0   U     0      0        0 eth0
> ROOT>
> 
> This is the same on both ends.
> 
> Then I tried :
> 
> ROOT> route add -host 192.168.0.3 on machine "a" which should get 192.168.0.3
> SIOCADDRT: No such device
> ROOT> route add -host 192.168.0.1 gave me the same result
> SIOCADDRT: No such device
> ROOT>

Why do you want to do that? It all works, right? Most important for the
routing table are the networks: which network to which ethernet card. 
If you change /etc/network/interfaces everything is handled correcly:

iface eth0 inet static
	address 192.168.0.1
	netmask 255.255.255.0
	network 192.168.0.0
	broadcast 192.168.0.255
#	gateway 192.168.0.3	#you can use a gateway if, for example,
192.168.0.3 is configured as ip-masquerade, so you can share your internet
connection


Now you can do a simple
# ifup eth0 
to initialize the ethernet card and
# ifdown eth0
to shut it down.

The routing table should also be fine for common use. (if you have complex
server configurations you may want to change something here).

Greetz,
Sebastiaan




Reply to: