Show device names in Thunar? (solved)

Post Reply
Message
Author
Vincent17
Posts: 75
Joined: Tue Feb 20, 2018 1:07 am

Show device names in Thunar? (solved)

#1 Post by Vincent17 »

Still getting used to xfce...
When I plug in a flash drive, it automounts and shows up in the Thunar side panel under DEVICES under a name that is not always clear to me. Is there a way to see "sdx#" within Thunar?

My main HD is usually labeled sdb, but if I boot with a flash drive or sd card plugged in, it changes. This makes me very nervous about using dd of=/dev/sdb ! What I do now is run df in a terminal and compare volume names several times. Is there a better way?
Last edited by Vincent17 on Fri Mar 30, 2018 6:48 pm, edited 1 time in total.

User avatar
m_pav
Developer
Posts: 1390
Joined: Sun Aug 06, 2006 3:02 pm

Re: Show device names in Thunar?

#2 Post by m_pav »

Yep.
1) label your fixed disk partitions if they're not labelled already and make sure ALL your external storage devices are labelled too, that way, when they show up in the file managers, you will know them by name.
2) understand that the reference point for / is always taken from the boot device, so when you boot from USB, / becomes the / of the Live session, not your physical disk partitions, which will ALWAYS be different to when running from a native fixed disk install.

This is not a fault of the OS, it's a feature of ALL operating systems regardless of their brand, type or otherwise. To my knowledge, every operating system ever known to man has the same quirk.

3) On your fixed disk installation, Open Thunar, navigate to /dev/disks and drag the by-label directory left to the area labelled Places and a link will be made available for you. Now all you have to do when a device is inserted, find it in the by-label director and hover your mouse on the icon for it. While hovering your mouse above the icon, look down in the lowest part of the Thunar Window, you'll see what the Linux nomenclature of the device is. Simple.

Whis won't help you when you're running live, but it will help you with rock solid understanding which will never let you down.
Mike P

Regd Linux User #472293
(Daily) Lenovo T560, i7-6600U, 16GB, 2.0TB SSD, MX_ahs
(ManCave) AMD FX 6100 CPU, nVidia, 8Gb, 3.25TB mixed, MX_ahs
(Spare)2017 Macbook Air 7,2, 8GB, 256GB SSD, MX_ahs

Vincent17
Posts: 75
Joined: Tue Feb 20, 2018 1:07 am

Re: Show device names in Thunar?

#3 Post by Vincent17 »

Thanks, m_pav, that's very useful.
You do not have the required permissions to view the files attached to this post.

User avatar
sunrat
Posts: 636
Joined: Mon Mar 28, 2016 9:54 pm

Re: Show device names in Thunar? (solved)

#4 Post by sunrat »

Vincent17 wrote:My main HD is usually labeled sdb, but if I boot with a flash drive or sd card plugged in, it changes. This makes me very nervous about using dd of=/dev/sdb ! What I do now is run df in a terminal and compare volume names several times. Is there a better way?
Yep.
Immediately after plugging in your external device, run

Code: Select all

dmesg |tail

Vincent17
Posts: 75
Joined: Tue Feb 20, 2018 1:07 am

Re: Show device names in Thunar? (solved)

#5 Post by Vincent17 »

label your fixed disk partitions if they're not labelled already and make sure ALL your external storage devices are labelled too, that way, when they show up in the file managers, you will know them by name.
Good advice...To cover cases where it's not followed :azn: I have rc.local copy this desktop file into /dev/disk/by-label:

Code: Select all

[Desktop Entry]
Type=Application
Name=disks
Exec='bash -c "lsblk -o name,label,size,fstype,mountpoint ; read"'
Terminal=true
Now when I click the by-label shortcut, I have the option to quickly check names of unlabeled flash drives also, though not in Thunar. Belt and suspenders. Thanks for the guidance.

User avatar
m_pav
Developer
Posts: 1390
Joined: Sun Aug 06, 2006 3:02 pm

Re: Show device names in Thunar? (solved)

#6 Post by m_pav »

sunrat wrote:Immediately after plugging in your external device, run

Code: Select all

dmesg |tail
Easier way is to watch messages in real time. The following will print all dmesg entries to your display through the Xfce terminal window as they happen, so if you run it before plugging any device in, you'll see the system messages well before anything pops up on your screen. Just make sure the Xfce window is wide enough to mimimise the text wrapping to a point where the content is decipherable. Ctrl + c stops the output.

Code: Select all

dmesg -wH
the -w replaces ( tail-f ) which follows a process
the -H, replaces ( --human ) and enables features like relative time and console colours
Mike P

Regd Linux User #472293
(Daily) Lenovo T560, i7-6600U, 16GB, 2.0TB SSD, MX_ahs
(ManCave) AMD FX 6100 CPU, nVidia, 8Gb, 3.25TB mixed, MX_ahs
(Spare)2017 Macbook Air 7,2, 8GB, 256GB SSD, MX_ahs

Post Reply

Return to “XFCE Desktop Environment”