:: Re: [DNG] For all you automounter p…
Inizio della pagina
Delete this message
Reply to this message
Autore: Didier Kryn
Data:  
To: dng
Oggetto: Re: [DNG] For all you automounter programmers
Le 02/05/2016 14:12, fsmithred a écrit :
> No support for file system labels at this time. If someone can tell me a
> reliable way for unprivileged user to get the labels, I'll add it. Feel
> free to use these scripts as they are or as motivation to create something
> better.
>
> -fsr
>
>
> On 04/28/2016 01:52 PM, fsmithred wrote:
>> On 04/27/2016 08:28 PM, fsmithred wrote:
>>> You could get the label from lsblk, do 'pmount label' and it will be
>>> mounted at /media/label. Every time you plug in a thumb drive labeled
>>> backup, it'll go to the same place. If you unmount the drive, /media/label
>>> will no longer exist, so you could even have the backup script check to
>>> make sure it's there.
>>>
>>> -fsr
>>>
>>
>> Correction - Only root can get the label from lsblk. User can get the
>> label from '/sbin/blkid -s LABEL', but only after root has run blkid at
>> least once. Other than that, I've now got a script that will handle the
>> labels... sometimes.
>>
>> -fsr
>>
>>
>


kryn@apcnb98:~$ /sbin/blkid /dev/sda5
/dev/sda5: LABEL="/" UUID="d91acaa3-5fdc-49e9-9f2b-ba7f3efb33f9"
UUID_SUB="6a0c80cd-5dc6-4135-8018-575686e7e11e" TYPE="btrfs"
kryn@apcnb98:~$ /sbin/blkid /dev/sda6
/dev/sda6: LABEL="/usr" UUID="05f9f811-b8b1-445f-ac8c-9537a202a9f9"
UUID_SUB="52b8e1b8-7080-4696-94e1-8f7580005871" TYPE="btrfs"

     Didier