Opened 2 years ago

Last modified 9 days ago

#18044 new bug

kernel: file descriptor leak on unmount

Reported by: X512 Owned by: nobody
Priority: normal Milestone: Unscheduled
Component: System/Kernel Version: R1/Development
Keywords: Cc:
Blocked By: Blocking:
Platform: All

Description

This is hrev56567.

Test Bash code (adjust file names if needed):

while true
do
	mkdir /Haiku-riscv
	mount -t bfs haiku-minimum.image /Haiku-riscv
	ls -a -1 /Haiku-riscv > /dev/null
	unmount -f /Haiku-riscv
	rmdir /Haiku-riscv
done

Running this test code cause run out of file descriptors and attempting to run any program cause error "Killed (by death)".

Attachments (1)

screenshot480.png (80.9 KB ) - added by X512 2 years ago.

Download all attachments as: .zip

Change History (4)

by X512, 2 years ago

Attachment: screenshot480.png added

comment:1 by waddlesplash, 2 years ago

Does the unmount -f have any relevance here, or does the same happen with non-forced unmounts?

If it's the latter, the leak is probably a general kernel file descriptors leak. Running various kdebug commands to show kernel file descriptors should help in determining where the leak is occurring.

comment:2 by waddlesplash, 2 years ago

Does this happen with all partitions, or only disk images?

comment:3 by waddlesplash, 9 days ago

Seems this is still with us. hrev58373 probably improved the situation, but it isn't completely fixed. Strangely enough I can still start new processes, but the syslog is filled with KERN: load_module_image(...) failed: Too many open files.

Note: See TracTickets for help on using tickets.