Bug 67814 - /sbin/ifdown loops at boot when /var/lib/pcmcia/stab exists
Summary: /sbin/ifdown loops at boot when /var/lib/pcmcia/stab exists
Keywords:
Status: CLOSED INSUFFICIENT_DATA
Alias: None
Product: Fedora
Classification: Fedora
Component: pcmcia-cs
Version: 1
Hardware: i686
OS: Linux
medium
high
Target Milestone: ---
Assignee: Pete Zaitcev
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2002-07-02 14:07 UTC by Need Real Name
Modified: 2008-08-02 23:40 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2006-10-25 20:08:20 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Need Real Name 2002-07-02 14:07:25 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (compatible; Konqueror/3.0.0-10; Linux)

Description of problem:
I've consistently had a problem with pcmcia startup hangs on several laptops running 7.3 after ungraceful shutdowns, and final figured it out I think.  When /var/lib/pcmcia/stab exists at boot time left over from the previous boot, /etc/init.d/pcmcia start tries to execute:

cat $RUN/stab | cleanup

which runs /etc/pcmcia/$CLASS stop $DEV

Tracing through, /sbin/ifdown line 50 checks to see if the device
is down, but for some reason doesn't believe this if DHCP is specified as $BOOTPROTO (can't figure out why this check is made?).
Execution therefore continues, even though eth0 is down, and line 53 executes "ip -o link show", which fails with "no such device".  The variable $FOUNDMACADDR isn't checked for a null result, and the script execs itself in the next if block at line 58 and loops with "no such device", but this output is suppressed in /etc/init.d/pcmcia, so startup just sees a hang.


Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1. ungraceful shutdown while pcmcia network up, or manually create /var/lib/pcmcia/stab (with $BOOTPROTO set to dhcp)
2. /etc/init.d/pcmcia start or reboot

Actual Results:  System hangs if being booted at PCMCIA startup.
If system is already booted and /etc/init.d/pcmcia startup is being executed manually, ^C frees this up (presumably by breaking into looped exec's of /sbin/ifdown).


Expected Results:  System should cope with erroneous presence of /var/lib/pcmcia/stab by testing properly for network status of eth0 and recover.

Additional info:

Classing this as severity "high" as it prevents successful boot (and I've seen it lots of times on several machines) - please reassign if this is inappropriate.

Suggested possible solutions:

1) Check for eth0 in /etc/init.d/pcmcia startup and only "cleanup" if really up (not a good solution)

2) In /sbin/ifdown:
#    if [ "${FOUNDMACADDR}" != "${HWADDR}" ]; then
    if [ ! -z "$FOUNDMACADDR" -a "${FOUNDMACADDR}" != "${HWADDR}" ]; then

(better, but not completely clean)

3) Fix the call above in /sbin/ifdown to check_device_down to still discontinue execution even if $BOOTPROTO is dhcp (best solution?).

Comment 1 Darren Brierton 2003-04-23 14:21:53 UTC
I can confirm that this happens on RHL9 too. I was just aout to report it.

Comment 2 Jim Hollan 2003-11-17 11:46:06 UTC
I have a very similar problem with Fedora Core 1. System hangs on boot
starting up pcmcia following an ungraceful shutdown.

Comment 3 Need Real Name 2005-07-11 01:03:51 UTC
It's nice to see this is still marked as NEW. It was my first bug report and I
put in lots of work!  Maybe it could be marked PREHISTORIC or something.

Comment 4 Pete Zaitcev 2005-10-28 03:04:21 UTC
Surely this is not a problem with FC5 Rawhide, if only because Hinds' pcmcia-cs
is replaced with pcmciautils. Please check if it works, if it's feasible.


Comment 5 Matthew Miller 2006-07-11 17:28:23 UTC
Fedora Core 1 is maintained by the Fedora Legacy project for security updates
only. If this problem is a security issue, please reopen and reassign to the
Fedora Legacy product. If it is not a security issue and hasn't been resolved in
the current FC5 updates or in the FC6 test release, reopen and change the
version to match.

Thanks!

NOTE: Fedora Core 1 is reaching the final end of support even by the Legacy
project. After Fedora Core 6 Test 2 is released (currently scheduled for July
26th), there will be no more security updates for FC1. Please use these next two
weeks to upgrade any remaining FC1 systems to a current release.



Comment 6 John Thacker 2006-10-25 20:08:20 UTC
Closed per above message and lack of response.  Note that FC1 is not even
supported by Fedora Legacy currently.


Note You need to log in before you can comment on or make changes to this bug.