Na klar kannst Du englisch schreiben. Die Liste besteht aus englischverstehenden und sehr toleranten Menschen. Wir helfen gerne!!
Thanks very much! I think I have found an issue in the init script dependencies. Basically, /etc/init.d/network does not depend on /etc/rc.d/pcmcia, but defers network initialization to /etc/rc.d/pcmcia. This fails when you are using IP-aliasses on a PCMCIA ethernet adapter. Let me explain more clearly: I have a laptop with eth0 being a PCMCIA card. The configuration of eth0 with an IP-address went ok - really no problem at all. Now I wanted to have an IP alias eth0:0, and this seems easy: extra entry in yast that gets into /etc/rc.config (see the snippets below). Starting the alias was no problem either: just run "/etc/rc.d/network start" and you are go. Now rebooting is a different issue: after a reboot, eth0 is up, but eth0:0 is not. Running "/etc/rc.d/network start" again solves this, but a reboot kills it. The issue appears to be that the card is a PCMCIA card, and this is not handled correctly by the init scripts. The /etc/rc.d/network script runs first, and defers eth0 initialization until /etc/rc.d/pcmcia is executed. But since eth0:0 depends on eth0, it is skipped by /etc/rc.d/network (without ANY warning!), and not deferred to /etc/rc.d/pcmcia . When /etc/rc.d/pcmcia runs, it only knows about eth0 (because that is a PCMCIA card) and not about eth0:0 (which it thinks is a regular network card). Looking at the init scripts (see snippets below) you can see the dependencies. I have a temporary workaround: 1. add 'pcmcia' to the 'Required-Start:' line in /etc/rc.d/network. It now looks like this: # Required-Start: $local_fs dummy usbmgr dhclient firewall_init pcmcia 2. run 'insserv' to re-generate the links in the runlevel directories. I am not satisfied with this workaround, as it creates a circular dependency (/etc/rc.d/network and /etc/rc.d/pcmcia depend on each other), but on my machine it now boots fine: /etc/rc.d/pcmcia is executed first, followed by /etc/rc.d/network. Since /etc/rc.d/pcmcia detects the PCMCIA card fine, /etc/rc.d/network starts both eth0 and eth0:0. But somehow this solution feels awkward. So I'd appreciate suggestions on how to fix this better. Snippet from /etc/rc.d/network: # /etc/init.d/network # ### BEGIN INIT INFO # Provides: network # Required-Start: $local_fs dummy usbmgr dhclient firewall_init # Required-Stop: # Default-Start: 2 3 5 # Default-Stop: # Description: Configure the network interfaces ### END INIT INFO Snippet from /etc/rc.d/pcmcia: ### BEGIN INIT INFO # Provides: pcmcia # # /sbin/init.d/pcmcia # ### BEGIN INIT INFO # Provides: pcmcia # Required-Start: network # Required-Stop: # Default-Start: 2 3 5 # Default-Stop: # Description: Loads pcmcia base modules and starts cardmgr ### END INIT INFO Snippet from /etc/rc.d: # Networking # # Number of network cards: "_0" for one, "_0 _1 _2 _3" for four cards # NETCONFIG="_1" # # This variable contains all indices of active PCMCIA network devices # NETCONFIG_PCMCIA="_0" # # IP Adresses # IPADDR_0="10.0.0.151" IPADDR_1="192.168.1.151" IPADDR_2="" IPADDR_3="" # # Network device names (e.g. "eth0") # NETDEV_0="eth0" NETDEV_1="eth0:0" NETDEV_2="" NETDEV_3="" # # Parameters for ifconfig, simply enter "bootp" or "dhcpclient" to use the # respective service for configuration. # Sample entry for ethernet: # IFCONFIG_0="192.168.81.38 broadcast 192.168.81.63 netmask 255.255.255.224" # IFCONFIG_0="10.0.0.151 broadcast 10.0.255.255 netmask 255.255.0.0 up" IFCONFIG_1="192.168.1.151 broadcast 192.168.1.255 netmask 255.255.255.0 up" IFCONFIG_2="" IFCONFIG_3="" -- Jeroen W. Pluimers Consultant at All I M http://www.all-im.com
On Tue, Feb 12, Jeroen W. Pluimers (All I'M) wrote:
Na klar kannst Du englisch schreiben. Die Liste besteht aus englischverstehenden und sehr toleranten Menschen. Wir helfen gerne!!
Thanks very much!
I think I have found an issue in the init script dependencies. Basically, /etc/init.d/network does not depend on /etc/rc.d/pcmcia, but defers network initialization to /etc/rc.d/pcmcia. This fails when you are using IP-aliasses on a PCMCIA ethernet adapter.
No, network should not depend on pcmcia, because pcmcia has it's own network setup script. Sucha dependency can cause troubles if you have pcmcia and build in NICs.
Let me explain more clearly:
I have a laptop with eth0 being a PCMCIA card. The configuration of eth0 with an IP-address went ok - really no problem at all. Now I wanted to have an IP alias eth0:0, and this seems easy: extra entry in yast that gets into /etc/rc.config (see the snippets below). Starting the alias was no problem either: just run "/etc/rc.d/network start" and you are go. Now rebooting is a different issue: after a reboot, eth0 is up, but eth0:0 is not. Running "/etc/rc.d/network start" again solves this, but a reboot kills it.
The issue appears to be that the card is a PCMCIA card, and this is not handled correctly by the init scripts.
This is intension. Initscripts are executed at boottime only, but plugging a pcmcia card can happen in the running system at any time. So these jobs must be independant.
The /etc/rc.d/network script runs first, and defers eth0 initialization until /etc/rc.d/pcmcia is executed. But since eth0:0 depends on eth0, it is skipped by /etc/rc.d/network (without ANY warning!), and not deferred to /etc/rc.d/pcmcia . When /etc/rc.d/pcmcia runs, it only knows about eth0 (because that is a PCMCIA card) and not about eth0:0 (which it thinks is a regular network card).
Looking at the init scripts (see snippets below) you can see the dependencies.
I have a temporary workaround:
1. add 'pcmcia' to the 'Required-Start:' line in /etc/rc.d/network. It now looks like this: # Required-Start: $local_fs dummy usbmgr dhclient firewall_init pcmcia 2. run 'insserv' to re-generate the links in the runlevel directories.
I am not satisfied with this workaround, as it creates a circular dependency (/etc/rc.d/network and /etc/rc.d/pcmcia depend on each other), but on my machine it now boots fine: /etc/rc.d/pcmcia is executed first, followed by /etc/rc.d/network. Since /etc/rc.d/pcmcia detects the PCMCIA card fine, /etc/rc.d/network starts both eth0 and eth0:0.
This does not work when you hotplug the card.
But somehow this solution feels awkward.
So I'd appreciate suggestions on how to fix this better.
Have a look at /etc/pcmcia/network. You can specify functions in /etc/pcmcia/network.opts which are executed after insertion or before ejection. This is described in the PCMCIA Howto: /usr/share/doc/packages/pcmcia/PCMCIA-HOWTO ------------- Wa are aware of such problems. The next SuSE Linux will have a completely redesigned network setup; then you won't have such problems anymore. -- ciao, christian ---------------------------------------------------------------- ... und sie sägten an den Ästen, auf denen sie saßen und schrien sich Ihre Erfahrungen zu, wie man besser sägen könne ... ---(Haindling [geklaut von Bert Brecht])------------------------
Christian,
No, network should not depend on pcmcia, because pcmcia has it's own network setup script. Sucha dependency can cause troubles if you have pcmcia and build in NICs.
I figured it had a reason, and now I know why. Thanks!
Initscripts are executed at boottime only, but plugging a pcmcia card can happen in the running system at any time. So these jobs must be independant.
Ah! That I never thought of. This laptop is just sitting in a draper playing internet server, so that pcmcia card is never removed.
I have a temporary workaround:
This does not work when you hotplug the card.
Which is not an issue on my machine, but I'm glad to know when my solution will fail.
Wa are aware of such problems. The next SuSE Linux will have a completely redesigned network setup; then you won't have such problems anymore.
That sounds great! I'm very happy about that. Thanks for your insights. --jeroen
participants (2)
-
Christian Zoz
-
Jeroen W. Pluimers (All I'M)