User Tools

Site Tools


tips:hiding-lvm2-physical-volumes-from-thunar-removable-devices

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
tips:hiding-lvm2-physical-volumes-from-thunar-removable-devices [05.08.2012 20:49]
vergo
tips:hiding-lvm2-physical-volumes-from-thunar-removable-devices [05.08.2012 23:28]
vergo
Line 1: Line 1:
 ====== Hiding LVM2 physical volumes from Thunar removable devices ====== ====== Hiding LVM2 physical volumes from Thunar removable devices ======
  
-For some reason, Thunar will sometimes show LVM2 physical volumes as removable devices. As an example, with Ubuntu 12.04 and Xfce using an encrypted disk that then contains a LVM2 physical volume, that volume will come visible even when it isn't mountable. The solution involves using the UDISKS_PRESENTATION_HIDE environment variable. However, this needs to be passed to Thunar using udev.\\+For some reason, Thunar will sometimes show LVM2 physical volumes as removable devices. As an example, with Ubuntu 12.04 and Xfce using an encrypted ​raid disk that then contains a LVM2 physical volume, that volume will come visible even when it isn't mountable. The solution involves using the UDISKS_PRESENTATION_HIDE environment variable. However, this needs to be passed to Thunar using udev.\\
 \\ \\
-Adding the following in ///​etc/​udev/​rules.d/​99-hide-thunar-devices.rules//​ will hide devices starting with "md" ​and ending with "​_crypt",​ essentially hiding encrypted raid devices.+Adding the following in ///​etc/​udev/​rules.d/​99-hide-thunar-devices.rules//​ will the device ​"md1"
 <​code>​ <​code>​
-ENV{DM_LV_NAME}=="md?*_crypt", ENV{UDISK_PRESENTATION_HIDE}:="​1"​+KERNEL=="md1", ENV{UDISKS_PRESENTATION_HIDE}="​1"​
 </​code>​ </​code>​
  
-Alternative syntax if you know the exact device name:+Then use this command (as root) to trigger a refresh:
  
 <​code>​ <​code>​
-KERNEL=="​sda1",​ ENV{UDISK_PRESENTATION_HIDE}:​="​1"​+udevadm trigger
 </​code>​ </​code>​
  
-The bad news: a reboot seems to be needed.+You may need to play around guessing the correct device name depending on your setup. Udisks doesn'​t appear ​to be able to tell you directly which the possible mystery device is.
tips/hiding-lvm2-physical-volumes-from-thunar-removable-devices.txt · Last modified: 05.08.2012 23:28 by vergo