Results 1 to 2 of 2

Thread: dmsetup, device-mapper, TrueCrypt, and Desktop icon labels

  1. #1
    Join Date
    Dec 2010
    Beans
    43
    Distro
    Ubuntu 10.04 Lucid Lynx

    dmsetup, device-mapper, TrueCrypt, and Desktop icon labels

    Anyone know how device-mapper works, or can someone point me to any docco (other than the man page)?

    Couple years ago I wrote a TrueCrypt wrapper script for use on Puppy Linux, and am reworking it for Ubuntu. Puppy sometimes didn't have the 'dmsetup' device-mapper utility available, but TrueCrypt still works without this when the '-m nokernelcrypto' option is used.

    My script notices when dmsetup is available and skips this option. When the TC volume gets mounted (somehow using dmsetup), the Desktop icon is labled with the leaf name of the /media/mount_point -- so far, so good.

    However, if I force the script to add the no-kernel-crypto option, and the TC volume is mounted without using dmsetup, the Desktop icon ls labled with the size of the volume. Say what?

    Running df shows the difference between the two mounts is whether /dev/mapper is used. So *how is* dmsetup making this happen? The manpage isn't much help. Is it just the 'rename' sub-command? I am unable to find any details about this mechanism.
    Thank you,

    Code:
    With dmsetup: Icon on desktop is labeled 'testing.tc'
    
    Filesystem   Type   1K-blocks   Used Available Use% Mounted on
    /dev/mapper/truecrypt2
                 vfat        1769      6      1763   1% /media/testing.tc
    
    ------------------------------------------------------------------------
    Without dmsetup: Icon on desktop is labeled '1.8 MB Filesystem'
    
    Filesystem   Type   1K-blocks   Used Available Use% Mounted on
    /dev/loop3   vfat        1769      6      1763   1% /media/testing.tc
    The difference between theory and reality is that, in theory, there should be no difference but, in reality, there always is.

  2. #2
    Join Date
    Dec 2010
    Beans
    43
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: dmsetup, device-mapper, TrueCrypt, and Desktop icon labels

    No one knows how this works, huh? Even a pointer to somewhere?

    On a related subject, does anyone know where / how Ubuntu caches drive icon images, when you have an autorun.inf file and an icon file in the top-level directory of a device? There's a subtle issue concerning the deniability of how one is using TrueCrypt on a system.

    Update: I found the icons under ~/.thumbnails/normal/ with different names (08bb589a0ce1c187ecbcbf71f630a6cb.png, 50f265147a8b12498b573d331608d60e.png) but deleting them didn't help. Are they cached in memory? Hope there's a way to uncache them.
    Last edited by c.cobb; July 26th, 2011 at 11:12 PM. Reason: more info
    The difference between theory and reality is that, in theory, there should be no difference but, in reality, there always is.

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •