symlink to /proc/mounts

Richard Lightman richard at nezumi.plus.com
Wed Jan 1 23:36:09 PST 2003


* Ian Molton <spyro at f2s.com> [2003-01-02 07:06]:
> On Wed, 1 Jan 2003 23:14:50 +0000 (UTC)
> richard at nezumi.plus.com (Richard Lightman) wrote:
> 
> > > Mount writes information to /etc/mtab. Some, but not all
> > > of this information is found in /proc/mounts.
> > > 
> > Well fix it ;-). Create a kernel patch to allow mount to install
> > additional information in /proc/mounts.
> 
> I never got round to implementing my solution to the 'loopback device
> under symlinked /etc/mtab' problem.
> 
> basically I was going to allow 'named loopback devices' to be created so
> that mount could intelligently umount loopback devices when you
> unmounted the fs that was on them.
> 
> its probably a very trivial kernel mod. I should look into it again
> someday...
> 
I use an encrypted loop back device to hold plain text passwords
(/etc/ssh_host_dsa_key and /etc/ppp/pap-secrets). 

It mounts every day with:
md5sum /dev/misc/nvram | mount -p 0 /etc/secrets

and unmounts with:
umount -rnd /etc/secrets

fstab entry:
/etc/secret_crypt /etc/secrets cramfs \
noauto,nosuid,nodev,noexec,ro,loop=/dev/loop/0,keybits=192,encryption=aes

Is there some problem with the /etc/mtab symlink and loop devices that
does not show up because I have devfs and crypto?

The patches are in ftp://your.kernel.mirror/linux/kernel/people/hvr/
testing/loop-hvr-2.4.18.0.patch.bz2
testing/patch-int-2.4.20.1.bz2
util-linux-cryptoapi/util-linux-2.11r.patch.bz2

Richard
-- 
Unsubscribe: send email to listar at linuxfromscratch.org
and put 'unsubscribe lfs-dev' in the subject header of the message



More information about the lfs-dev mailing list