Bug 381461

Summary: /sbin/start_udev: line 257: cannot redirect standard input...
Product: [Fedora] Fedora Reporter: Michael McLagan <mmclagan>
Component: udevAssignee: Harald Hoyer <harald>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: 11CC: aros, frank
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-04-13 16:12:31 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Michael McLagan 2007-11-14 03:27:17 UTC
Description of problem:

udev shows error during startup:

/sbin/start_udev: line 85: cannot redirect standard input from /dev/null: No
such file or directory
/sbin/start_udev: line 85: cannot redirect standard input from /dev/null: No
such file or directory

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

udev-116-3.fc8

How reproducible:

Always (12 systems)

Steps to Reproduce:
1. Install udev 116
2. reboot
3. watch boot process just after "Welcome to Fedora"
  
Actual results:

error as above

Expected results:

no error message.

Additional info:

I found a note online from the udev author about using klibc instead of glibc
due to it's need for the /dev/null device node (Google it, I've closed the
window already).  Line 85 is:

		for i in /etc/udev/makedev.d/*.nodes; do

which suggests that it's bash that's complaining about it, maybe a shell which
doesn't rely on /dev/null should be used instead of bash in the script or even a
private copy of bash linked against klibc?

In any case, I don't remember seeing anything like this for F7.

Comment 1 Frank Crawford 2007-12-16 09:27:26 UTC
I've also seen this only since F8, but also only on certain machines.  From my
investigation, it only appears on systems booted without an initrd image (i.e. a
kernel will all boot dependencies compiled in).

I suspect the line numbers are wrong and it actually occurs from the section
around lines 92-104, which are the statements:

     pushd $devdir &> "$udev_root/null"
and 
     popd &> "$udev_root/null"

(and maybe the one in between - see the code).

and is caused by the fact that /dev/null ($udev_root is /dev at that stage)
doesn't exist at that point, due to a race condition.  It is created by the
MAKEDEV call run in the background at line 88.

For kernels with a standard Fedora initrd, /dev/null is a node created specially
as part of the setup and hence exists when this is run.

Comment 2 Harald Hoyer 2008-02-20 18:12:06 UTC
udev-118-5.fc9

Comment 3 Michael McLagan 2009-07-02 03:44:23 UTC
This bug has returned, but it is now at line 257, same complaint about not being able to redirect to /dev/null.

[root@xxxxx ~]# rpm -q udev
udev-141-3.fc11.i586

Comment 4 Artem S. Tashkinov 2009-08-22 18:43:47 UTC
I have the same problem in Fedora 11. It only happens with a manually built kernel *without* initrd.

My /dev is populated with some static devices/files in order to boot without initrd - I absolutely have /dev/null file with 666 permissions.

Line 257 reads:

make_extra_nodes &

 - there's no redirection of any kind going on here - it seems like a bash bug.

I have an idea that at a moment udev start ups with a fresh /dev, with redirection to /dev/null already going in place, however /dev/null hasn't been yet created.

Comment 5 Artem S. Tashkinov 2010-03-30 10:28:42 UTC
This bug has actually disappeared.

rpm -q udev
udev-145-19.fc12.i686