Bug 9557

Summary: Could not set non-blocking flag with 2.6.24-rc5
Product: File System Reporter: Rafael J. Wysocki (rjwysocki)
Component: VFSAssignee: fs_vfs
Status: CLOSED UNREPRODUCIBLE    
Severity: normal CC: bunk, tino.keitel, trondmy
Priority: P1    
Hardware: All   
OS: Linux   
Kernel Version: 2.6.24-rc5 Subsystem:
Regression: Yes Bisected commit-id:
Bug Depends on:    
Bug Blocks: 9243    
Attachments: working run with 2.6.23.8 in a chroot
broken run with 2.6.24-rc5 in a chroot
working run with 2.6.23.8 outside a chroot
working run with 2.6.24-rc5 outside a chroot

Description Rafael J. Wysocki 2007-12-13 16:27:26 UTC
Subject         : Could not set non-blocking flag with 2.6.24-rc5
Submitter       : Tino Keitel <tino.keitel@gmx.de>
References      : http://lkml.org/lkml/2007/12/13/392
Comment 1 Trond Myklebust 2007-12-13 16:52:45 UTC
>  [pid  5988] fcntl64(-1, F_GETFL)        = -1 EBADF (Bad file descriptor)

Err... '-1' has always been an illegal value for a file descriptor. POSIX
tells you explicitly that if open() or creat() return -1, then that is a
sign of an error. I'm surprised that aptitude isn't checking for that.

That said, could you show the part from the strace that actually contains the
open() that failed?
Comment 2 Tino Keitel 2007-12-17 23:43:51 UTC
Created attachment 14098 [details]
working run with 2.6.23.8 in a chroot
Comment 3 Tino Keitel 2007-12-17 23:44:30 UTC
Created attachment 14099 [details]
broken run with 2.6.24-rc5 in a chroot
Comment 4 Tino Keitel 2007-12-17 23:45:01 UTC
Created attachment 14100 [details]
working run with 2.6.23.8 outside a chroot
Comment 5 Tino Keitel 2007-12-17 23:45:28 UTC
Created attachment 14101 [details]
working run with 2.6.24-rc5 outside a chroot
Comment 6 Tino Keitel 2007-12-17 23:46:36 UTC
I attached some complete strace outputs of the working and the broken condision. I hope that helps.
Comment 7 Linus Torvalds 2008-01-01 14:07:41 UTC
At least for the chroot case, you're getting

   open("/dev/null", O_RDWR) = -1 ENXIO (No such device or address)

which to me implies that you have a broken /dev, possibly due to some
odd udev issue or just your chroot environment getting broken by
something.
Comment 8 Tino Keitel 2008-01-06 03:13:25 UTC
The chroot is extracted from the same .tar.gz in each of the above cases. I'll check if I can see what's wrong with /dev/null in the error case.
Comment 9 Adrian Bunk 2008-01-11 12:37:47 UTC
Tino, any updates?
Comment 10 Tino Keitel 2008-01-13 10:20:50 UTC
I can not reproduce it anymore with 2.6.24-rc4.
Comment 11 Rafael J. Wysocki 2008-01-13 13:12:09 UTC
Closing as unreproducible.  Please reopen if it reappears.
Comment 12 Tino Keitel 2008-01-13 13:22:47 UTC
Err, I meant 2.6.24-rc7 (I was told that this was a XFS issue that is fixed in 2.6.24-rc7).