Re: What to do about /etc/debian_version
>>>>> " " == Martin Keegan <mk270@cam.ac.uk> writes:
> Martijn van Oosterhout <kleptog@cupid.suninternet.com> writes:
>> Joey Hess wrote: > I think /etc/mtab is on its way out. A 2.4.x
>> kernel with devfs has a > /proc/mounts that actually has a
>> proper line for the root filesystem. > Linking the two files
>> would probably actually work on such a system > without
>> breakage.
>>
>> Does 2.4 now also include the information on which loop devices
>> are related to which filesystems? AFAIK that's the only thing
>> that went strange after linking /proc/mounts and /etc/mtab;
>> loop devices not being freed after unmounting.
No. Not that I saw a change for it. How could it? Currently when
mounting a loop device, mount writes the filename that gets attached
to the loop device into /etc/mtab and then mounts /dev/loopX. Because
/etc/mtab is read-only mount can't write the filename and thus doesn't
know what to detach when unmounting.
mount can't know the difference between
"mount -oloop file path"
and
losetup /dev/loop0 file
"mount /dev/loop0 path"
Maybe the mount or loopback interface could be changed to record that
umount has to free the loop device upon umount.
> When doing this I had a problem with the mount programme
> insisting on explicitly checking whether /etc/mtab were a
> symlink and explicitly breaking if it were. Why is this?
Never had that problem.
MfG
Goswin
Reply to: