Bug 452866 - netfs does not synchronise with udev
Summary: netfs does not synchronise with udev
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: initscripts
Version: 5.2
Hardware: All
OS: Linux
medium
medium
Target Milestone: rc
: ---
Assignee: initscripts Maintenance Team
QA Contact: Brock Organ
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2008-06-25 14:18 UTC by Bryn M. Reeves
Modified: 2018-10-20 02:40 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2009-01-20 22:16:02 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Add a udevsettle before mounting _netdev devices (588 bytes, patch)
2008-06-25 14:18 UTC, Bryn M. Reeves
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2009:0245 0 normal SHIPPED_LIVE initscripts bug fix update 2009-01-20 16:06:46 UTC

Description Bryn M. Reeves 2008-06-25 14:18:03 UTC
Description of problem:
The _netdev option is used in /etc/fstab to mark devices that depend on the
network for operation. This causes the initscripts to defer mounting file
systems located on these devices until the network is brought up and the netfs
initscript runs.

Device nodes for these devices (nbd, gnbd, iscsi etc.) are created by udev once
the appropriate subsystem is started.

Processing of the udev backlog may not have completed by the time the netfs
script runs causing failures to occur when attempting to mount file systems.
This can happen when there are a large number of devices or when device
initialisation is slow.

This is fixed by adding a udevsettle to the start() function in netfs. 

Version-Release number of selected component (if applicable):
initscripts-8.45.17.EL-1

How reproducible:
100%

Steps to Reproduce:
1. grep udev /etc/init.d/netfs
  
Actual results:
No results.

Expected results:
An invocation of udevsettle to cause the script to sync up with udev processing.

Additional info:
Reproducing actual errors is harder; need to create for e.g. a very large number
of iSCSI devices or arrange for the udev processing to take longer than normal
(maybe adding a sleep in a udev rule would work for simulating this).

This has been seen in production environments with large numbers of devices.

Comment 1 Bryn M. Reeves 2008-06-25 14:18:03 UTC
Created attachment 310267 [details]
Add a udevsettle before mounting _netdev devices

Comment 2 RHEL Program Management 2008-06-25 15:03:17 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release.  Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products.  This request is not yet committed for inclusion in an Update
release.

Comment 4 Bryn M. Reeves 2008-06-30 14:05:56 UTC
As described in comment #0; when you have a system that exhibits this behavior
it will fail 100% of the time. This normally involves very large numbers of
devices or devices that are for some reason slow for udev to process.

If using modified udev scripts is an acceptable way to reproduce for testing
purposes then just adding a delay of a couple of seconds should be adequate to
trigger a mount failure in the netfs script; just create an entry in fstab
labelled with _netdev that attempts to mount such a "slow" device.


Comment 5 David Kovalsky 2008-06-30 14:21:41 UTC
Yes, I think might be acceptable and probably easier to setup then many iscsi
drives (even though possible). Thanks for the info Bryn!

Comment 8 Bill Nottingham 2008-09-17 00:06:40 UTC
Upon re-review... why isn't this patch in the iscsi script instead?

Comment 9 Matthew Kent 2008-11-28 00:35:15 UTC
+1, seeing this issue here on multiple systems.

Confirming that adding /sbin/udevsettle --timeout=30 to init.d/iscsi startup, just after loginall, solves it nicely. Solid across 20 reboots.

Comment 10 Yulia Kopkova 2008-12-02 13:10:58 UTC
Bryn, Harald,

Can you please add more clear/step-by-step reproducer for QE?

Thank you in advance.

Comment 14 errata-xmlrpc 2009-01-20 22:16:02 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2009-0245.html


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