illegal seek - unable to umount device
Hi,
I have just encountered a problem (?) with reiserfs on Linux 2.4.20. I wrote the following (shortened) python code which produced an unkillable process:
#!/usr/bin/python
file=open("terabyte_length_file", "w")file.seek(1024*1024*1024*1024)file.write("%c" % 0)file.close()
On ext2, this code produced a file which had the (nominal) length of 1 terabyte and the real size of 16k. I ran this script on a reiserfs partition as a normal user, and it
1. produced an unkillable process with 100% CPU usage
2. i was unable to kill it anyway, and i was unable to unmount the filesystem. (Illegal seek, Device or resource busy). So finally i rebooted the system. Of course, the rebooting process also got stuck as init couldn't umount the device either.
Naturally, i was not really surprised that this code didn't work on reiserfs, but i was quite astonished by the fact that this dirty program could practically "kill" the machine as a normal user - in a meaning that running it several times consumes its CPU resouces and makes it impossible to unmount the filesystem.
Additional information about the system:
CPU: Pentium III (Coppermine) Linux: 2.4.20-ptrace_lnat (gcc version 2.95.4) Distribution: Debian woody Disks: 4x40GB (as might be expected, i don't have an
1 terabyte disk :))
...
(what else do you need?)
- Akosh
ps. i haven't subscribed to the list, so please "cc" me your answers.
Signature · 5 lines
.~. /V\ Gyimesi Ákos // \\ <[email protected]> /( )\ ^`~'^
Hello!
Quoted 12 lines · Gyimesi Akos
I have just encountered a problem (?) with reiserfs on Linux 2.4.20. I wrote the following (shortened) python code which produced an unkillable process:
#!/usr/bin/python
file=open("terabyte_length_file", "w")file.seek(1024*1024*1024*1024)file.write("%c" % 0)file.close()
On ext2, this code produced a file which had the (nominal) length of 1 terabyte and the real size of 16k. I ran this script on a reiserfs partition as a normal user, and it
1. produced an unkillable process with 100% CPU usage
2. i was unable to kill it anyway, and i was unable to unmount the filesystem.
Quoted 8 lines
(Illegal seek, Device or resource busy). So finally i rebooted the system. Of course, the rebooting process also got stuck as init couldn't umount the device either.
Naturally, i was not really surprised that this code didn't work on reiserfs, but i was quite astonished by the fact that this dirty program could practically "kill" the machine as a normal user - in a meaning that running it several times consumes its CPU resouces and makes it impossible to unmount the filesystem.
This is known problem and we hope to push the fix to Marcelo soon. In short, the process is not stuck, it is busy creating file hole (4k at a time). If you'd wait long enough, it will eventually finish.
Thank you for the report.
Bye,
Oleg