[clug] command of the hour

Ian darkstarsword at gmail.com
Thu Feb 12 04:13:05 GMT 2009


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Thanks for another useful command Kim.

As has already been mentioned you can mount disks by ID and UUID - I
use that all the time for my permanent disks. I have one encrypted
removable disk that I wanted to be able to mount and unmount with
minimal fuss so my solution was to create a new udev rule under
/etc/udev/rules.d/10-local.rules containing:
SUBSYSTEMS=="usb", PROGRAM="/lib/udev/vol_id -u %N",
RESULT=="insert-your-disk-uuid-here", SYMLINK+="dse"

Whenever I attach it udev automatically creates /dev/dse as a symlink
to the _partition_ with that uuid. Then I can simply run 'pmount dse'
which prompts me for my passphrase and mounts it under /media/dse - no
need to set up /etc/crypttab or /etc/fstab and no need to sudo just to
mount or decrypt it. When I'm done, 'pumount dse' will unmount and
remove it from cryptsetup.

Cheers,
- -Ian

- --
http://darkstarshout.blogspot.com/
- --
On the day *I* go to work for Microsoft, faint oinking sounds will be
heard from far overhead, the moon will not merely turn blue but
develop polkadots, and hell will freeze over so solid the brimstone
will go superconductive.
     -- Erik Raymond, 2005
- --
Please avoid sending me Word or PowerPoint attachments.
See http://www.gnu.org/philosophy/no-word-attachments.html


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Use GnuPG with Firefox : http://getfiregpg.org (Version: 0.7.3)

iD8DBQFJk6HFrQR5CkD4dNARAtE+AKCX/D22GePGIyXL0G90LyCxpxTAvQCdENSp
2zg9N1LlupG36gPfVIR4OTA=
=F3K8
-----END PGP SIGNATURE-----


More information about the linux mailing list