[ltp] eth0 or eth1 active ?

FeRD linux-thinkpad@linux-thinkpad.org
Fri, 03 Feb 2006 19:36:00 -0500


This is why, on my mobile machine, ntpdate no longer gets to start at 
boot. I start/reload it every once in a while when the thing's online, 
to make sure I don't drift too far from the One True Time(tm). named is 
well-behaved, so I leave it running all the time. But let's face it, the 
ThinkPad's clock is good enough that it doesn't really need to be 
Constantly. Checking. What. Time. It. Is!

(Reminds me that every time I fiddle with something like this -- or the 
Gnome Panel applets I use that are network-aware and useless when I'm 
not online -- I wish the "new, improved" SYSV init system had the 
concept of system-state-dependent services built in. It'd be nice if 
ntpdate could be automatically started, instead of at boot, when the 
system first makes a network connection to the outside world. Same goes 
for user session elements... be great if some panel applets launched 
themselves only when the machine makes it online.)

Oh, well. Maybe I'll (or someone will) get motivated and try for Fedora 
Core 6. ;)

-FeRD

Francois Maltey wrote:
> Hello,
>
> When I use my thinkpad at home near a wifi router 
>
> I often get the right solution :
> 1/     wifi link on eth1 active
> 2/ ethernet link on eth0 down 
> and all is perfect.
>
> But sometimes the debian etch boot puts 
> 1/ ethernet link on eth0 active 
> 2/     wifi link on eth1 down
> and /etc/init.d/ntpdate service lock the boot for 1 or 2 minutes.
>
> Then I shutdown ethernet link and wake-up wifi link in gnome network monitor.
> After I type always the same IP adress, gateway adress, and essid name.
>
> My /etc/network/interfaces is :
> ---------------------------------------------------------
> auto lo
> iface lo inet loopback
>
> auto eth1
> # The primary network interface
> iface eth1 inet static
> address 192.168.0.5
> netmask 255.255.255.0
> gateway 192.168.0.1
> wireless-essid Wireless
>
> iface eth0 inet static
> address 192.168.0.15
> netmask 255.255.255.0
> gateway 192.168.0.1
>
> --------------------------------------------------------
> The problem is the same when I remain or remove the eth0 lines.
>
> How can I force the debian to use eth1 ?
> How can I force the system to forget the eth0 link ?
>
> What is the route command which delete a complete iterface 
> and how can I add a gateway with route ?
> I don't understand the man page.
>
> Thanks a lot for your help !
>
> Francois
>