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

Re: boot hangs when no ethernet cable is plugged in



On 2015-07-09 11:29:02 +0100, Lisi Reisz wrote:
> On Thursday 09 July 2015 11:21:34 Vincent Lefevre wrote:
> > On 2015-07-09 10:46:06 +0100, Lisi Reisz wrote:
> > > On Thursday 09 July 2015 10:31:21 Vincent Lefevre wrote:
> > > > On 2015-07-09 09:29:26 +0100, Lisi Reisz wrote:
> > > > > On Wednesday 08 July 2015 23:40:55 Vincent Lefevre wrote:
> > > > > > So, I wonder why the default file contains "allow-hotplug eth0".
> > > > > > This seems to be incorrect: it doesn't make sense to put eth0 up
> > > > > > only because the network interface eth0 is present, which is always
> > > > > > the case in practice. The condition should be that an Ethernet
> > > > > > cable is plugged in.
> > > > >
> > > > > Which is why it has "allow-hotplug eth0" and not "auto eth0".
> > > >
> > > > No, "allow-hotplug eth0" has always meant "when the interface is
> > > > present", not "when an ethernet cable is plugged in". "auto" more or
> > > > less means "always".
> > >
> > > So what, in your opinion, should it put? Many of the rest of us
> > > would object if it didn't put an entry.
> >
> > Remove the "allow-hotplug eth0" line and have eth0 be brought up
> > automatically when there's an Ethernet signal? I haven't seen any
> > drawback yet.
> 
> So what do you want /e/n/i to say?  You haven't answered that.

I currently have concerning eth0:

iface eth0 inet dhcp

i.e. the default without "allow-hotplug eth0". But, well, now I'm not
sure...

> allow-hotpug should enable just what you want.

Indeed, it seems that things have changed during the past few years,
and /etc/init.d/networking now handles hotplug and does link detection.
My previous testings and discussions dated from 2009, and there's
still

  https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=550014

open and it may be obsolete now.

> The question is why it is being allowed to hold up booting.

If I re-add the "allow-hotplug eth0" and removed the netplug package,
I still get the same problem. I don't understand because

  cat /sys/class/net/eth0/operstate

gives the expected answer: "up" when the Ethernet cable is plugged in,
otherwise "down". So, /etc/init.d/networking shouldn't bring eth0 up,
but it does!

-- 
Vincent Lefèvre <vincent@vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)


Reply to: