Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 123142 - ifplugd problems with boot-disconnected interfaces and IP aliases
Summary: ifplugd problems with boot-disconnected interfaces and IP aliases
Status: RESOLVED WORKSFORME
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] baselayout (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Roy Marples (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-02-17 00:12 UTC by Mirek Kratochvil
Modified: 2006-02-17 04:31 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mirek Kratochvil 2006-02-17 00:12:17 UTC
Description:

When ifplugd starts, it doesn't stop running interfaces that are disconnected.
This means problems with interfaces that are dhcp'ed and have some aliases
(because aliases start the interface, and when it's later plugged in, dhcp 
doesn't start)

To reproduce:  (for example)

[/etc/conf.d/net]
iface_eth0="dhcp"    <---should receive 192.168....
dhcpcd_eth0="-t 5"
alias_eth0="81.79.155.29"  <---just some IP that I need

[/etc/conf.d/ifplugd set for eth0]

..then boot without cable, dhcp fails but interface is started by alias.
When the cable comes, ifplugd maybe tries to start interface, but nothing
happens.

Possible fixes:

- configure ifplugd so that it stops disconnected interfaces at 'ifplugd start'.
- set ifplugd NOT to start interfaces with '/etc/init.d/.. start', BUT
  with '/etc/init.d/... restart' instead, so that badly configured interface
  is stopped and replaced.
- when dhcp on eth* fails, aliases shouldn't be set.

See also:

This bug is similar to #48482, which is marked as fixed, but appears not.
(I checked baselayout and ifplugd versions twice ;) )

-------------------------------------------------------
Just to be complete, my emerge info:

Portage 2.0.54 (default-linux/x86/2005.0, gcc-3.3.6, glibc-2.3.5-r2, 2.6.13-gentoo-r3 i686)
=================================================================
System uname: 2.6.13-gentoo-r3 i686 AMD Athlon(tm) processor
Gentoo Base System version 1.6.14
ccache version 2.3 [disabled]
dev-lang/python:     2.3.5, 2.4.2
sys-apps/sandbox:    1.2.12
sys-devel/autoconf:  2.13, 2.59-r6
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1
sys-devel/binutils:  2.16.1
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.11-r2
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=athlon -pipe -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.3/env 
/usr/kde/3.3/share/config /usr/kde/3.3/shutdown /usr/kde/3.4/env 
/usr/kde/3.4/share/config /usr/kde/3.4/shutdown /usr/kde/3/share/config 
/usr/lib/X11/xkb /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -march=athlon -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks sandbox sfperms strict"
GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 3dnow 3dnowext X a52 alsa apm arts audiofile avi bitmap-fonts bzip2 cdr
crypt cups curl divx4linux dvd dvdr dvdread emboss encode esd exif expat fam 
fastcgi ffmpeg firefox flac foomatic foomaticdb fortran gd gdbm gif glut gmp gpm 
gstreamer gtk gtk2 icq idn imagemagick imap imlib ipv6 java javascript jpeg junit
 kde lcms libg++ libwww lm_sensors mad maildir mhash mikmod mmx mmxext mng motif 
mozilla mp3 mpeg ncurses nls ogg oggvorbis openal opengl oss pam pcre pdflib perl
 php png ppds python qt quicktime readline sasl sdl slang speex spell sqlite ssl
 svga tcltk tcpd tiff truetype truetype-fonts type1-fonts udev unicode usb 
vorbis win32codecs xine xml2 xmms xv xvid zlib userland_GNU kernel_linux 
elibc_glibc"
Unset:  ASFLAGS, CTARGET, LANG, LC_ALL, LDFLAGS, LINGUAS, PORTDIR_OVERLAY
Comment 1 Roy Marples (RETIRED) gentoo-dev 2006-02-17 04:31:13 UTC
(In reply to comment #0)
> When ifplugd starts, it doesn't stop running interfaces that are disconnected.

100% correct.

The solution is to emerge baselayout-1.12.0_pre16 has it has inbuilt ifplugd support. Remove the ifplugd init script from the default runlevel.

If you don't use coldplug then add net.eth0 to the default runlevel.

Also, you're config may need to be updated to the new syntax. Here's it done for you.

config_eth0=( "dhcp" "81.79.155.29" )

There's no point in specifying a dhcpcd timeout when the interface is fully under the control of ifplugd, which it is for baselayout-1.12.0_pre16 :)

Re-open if you disagree