Opened 16 years ago

Last modified 8 years ago

#3026 assigned bug

Removable Media: Ejecting a CD leaves ghost of mount point

Reported by: RandomInsano Owned by: nobody
Priority: normal Milestone: R1
Component: System/Kernel Version: R1/pre-alpha1
Keywords: Cc: edwinguy+haiku@…, ttcoder
Blocked By: Blocking:
Platform: All

Description

Mounting a CD or DVD then pressing the eject button to remove it properly removes the entry from Tracker, but according to the 'ls' command in Terminal, the entry remains.

When re-inserting the disc, a new folder in the root filesystem node is created with the same name and an incrementing number. This is entirely reproducible (on real hardware at the very least).

Unmounting the volume with Tracker avoids this problem and ejects the CD happily.

Perhaps there's an issue with a lock on the folder when the system detects the CD is removed? I'm unable to test this with USB media.

Attachments (1)

CD2.png (66.2 KB ) - added by RandomInsano 16 years ago.
Terminal output

Download all attachments as: .zip

Change History (5)

by RandomInsano, 16 years ago

Attachment: CD2.png added

Terminal output

comment:1 by pulkomandy, 10 years ago

There doesn't seem to be a locking problem, it's just that unmounting a device by default does not remove the directory where it was mounted. The same happen if you use the unmount command.

The code taking care of cleaning up when unmounting is in BPartition. It does this by leaving a "marker" in the created directory, this is an empty dir named _HaikuAutoCreated. Maybe this should be moved to the lower level (fs_mount_volume/fs_unmount_volume), or maybe the unmount command and the auto-unmount on eject should use BPartition instead.

comment:2 by ttcoder, 10 years ago

Dunno how I missed this.. Somewhat benign but still part of the big picture. Can an admin please "Cc" me, I'd like to have this ticket in my query list, thank you.

comment:3 by waddlesplash, 10 years ago

Cc: ttcoder added
Platform: x86All

comment:4 by axeld, 8 years ago

Owner: changed from axeld to nobody
Status: newassigned
Note: See TracTickets for help on using tickets.