From: Alan Chandler on
On 23/06/10 11:20, Javier Barroso wrote:
> On Wed, Jun 23, 2010 at 10:40 AM, Alan Chandler
> <alan(a)chandlerfamily.org.uk <mailto:alan(a)chandlerfamily.org.uk>> wrote:
>
> I feel I should move my entire /etc/fstab over to using uuids
>
....
> Get your uuid from dumpe2fs -h /dev/vg/lv | grep UUID
>
> But /dev/vg/lv is a persistent name, so no sense changing it to uuid, or
> maybe I'm missing something ?
>

My brain fade - of course I can use the persistent name


--
Alan Chandler
http://www.chandlerfamily.org.uk


--
To UNSUBSCRIBE, email to debian-user-REQUEST(a)lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster(a)lists.debian.org
Archive: http://lists.debian.org/4C224433.2070400(a)chandlerfamily.org.uk
From: Aaron Toponce on
On 06/23/2010 09:47 AM, Camaleón wrote:
> On Wed, 23 Jun 2010 09:40:22 +0100, Alan Chandler wrote:
>> I feel I should move my entire /etc/fstab over to using uuids
>
> Mmm... any strong reason for doing that? :-)

Whether or not these are his reasons, I can tell you why that is a wise
move. UUIDs are unique to the device/filesystem. The major advantage of
using UUIDs is that you don't have to worry about reordering of disks by
the kernel when it sees it in a different order than previous.


> I'm with Lenny and the old naming method ("/dev/sdx") is the default for
> "/etc/fstab".

This isn't recommended, because if the Linux kernel developers change
drivers, and the drives become a new device (just as it happened when
ditching the PATA driver for SATA, and /dev/hda became /dev/sda), your
partitions/volumes won't mount. Instead, you should either be using
LABELs or UUIDs.

>> if I look in /dev/disk/by-id I can locate the following
>> and in /dev/disk/by-uuid (again excuse the word wrap)
>>
>> lrwxrwxrwx 1 root root 10 Jun 21 19:20
>> f3408fda-0649-414f-8446-c01cf4e07558 -> ../../dm-0
>>
>> There seems to be no correspondence between them

If you're running LVM2, then you need to be familiar with the LVM
commands. In particular, lvdisplay:

# lvdisplay
--- Logical volume ---
LV Name /dev/work/root
VG Name work
LV UUID M5qcO0-CEBb-rn7M-tm2o-pgII-0HmE-LNuSW9
LV Write Access read/write
LV Status available
# open 1
LV Size 18.80 GiB
Current LE 4813
Segments 2
Allocation inherit
Read ahead sectors auto
- currently set to 256
Block device 254:0

--
. O . O . O . . O O . . . O .
. . O . O O O . O . O O . . O
O O O . O . . O O O O . O O O

From: Camaleón on
On Wed, 23 Jun 2010 13:02:36 -0600, Aaron Toponce wrote:

> On 06/23/2010 09:47 AM, Camaleón wrote:

>> On Wed, 23 Jun 2010 09:40:22 +0100, Alan Chandler wrote:
>>> I feel I should move my entire /etc/fstab over to using uuids
>>
>> Mmm... any strong reason for doing that? :-)
>
> Whether or not these are his reasons, I can tell you why that is a wise
> move. UUIDs are unique to the device/filesystem. The major advantage of
> using UUIDs is that you don't have to worry about reordering of disks by
> the kernel when it sees it in a different order than previous.

Yes, I know.

But if the installer has setup (by its own) as default method for naming
devices the old one and I am not experiencing any problem with that, for
sure I won't change that. If it ain't broke, don't fix it.

>> I'm with Lenny and the old naming method ("/dev/sdx") is the default
>> for "/etc/fstab".
>
> This isn't recommended, because if the Linux kernel developers change
> drivers, and the drives become a new device (just as it happened when
> ditching the PATA driver for SATA, and /dev/hda became /dev/sda), your
> partitions/volumes won't mount. Instead, you should either be using
> LABELs or UUIDs.

I know, I know... but Lenny developers decided to go this way for any
reason and I will respect that. I'm aware that nowadays any modern
distribution is using "uuid" or "id" at least in "/etc/fstab" but as I
said, I still have not seen any good reason to change it.

Greetings,

--
Camaleón


--
To UNSUBSCRIBE, email to debian-user-REQUEST(a)lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster(a)lists.debian.org
Archive: http://lists.debian.org/pan.2010.06.23.21.30.39(a)gmail.com
From: Paul E Condon on
On 20100623_054331, Ron Johnson wrote:
> On 06/23/2010 05:20 AM, Javier Barroso wrote:
> >On Wed, Jun 23, 2010 at 10:40 AM, Alan Chandler
> ><alan(a)chandlerfamily.org.uk>wrote:
> >
> >>I feel I should move my entire /etc/fstab over to using uuids
> >>
> [snip]
> >>
> >>Which do I use, and what does the other one mean?
> >>
> >
> >Get your uuid from dumpe2fs -h /dev/vg/lv | grep UUID
> >
> >But /dev/vg/lv is a persistent name, so no sense changing it to uuid, or
> >maybe I'm missing something ?
> >
>
> Or use labels.

In squeeze, a recent revision in pata support seemed to introduce rewriting
/etc/fstab to reference all file systems via UUID.
Before that, I had constructed a system using labels which was totally
clobbered by the pata upgrade (which also suppressed all mention of
/dev/hd[ab][123] )

I don't use LVM. Perhaps using LVM protects you from 'upgrades' from
ata to pata. Or from future upgrades in pata support. But I'm inclined
to believe that we are in for a spate of instability as pata is worked
out in all its unintended ramifications.

FYI, the UUID is just a 128 bit number that is stored in a 16 byte
space in the superblock of the ext[234] file system. Mostly it is set
to a random value by mke2fs when the fs is originally created. But it
can also be set to a user designated (non-random?) value by
tune2fs -U <UUID> device.


--
Paul E Condon
pecondon(a)mesanetworks.net


--
To UNSUBSCRIBE, email to debian-user-REQUEST(a)lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster(a)lists.debian.org
Archive: http://lists.debian.org/20100624194611.GG3048(a)big.lan.gnu
From: Aaron Toponce on
On 06/23/2010 03:30 PM, Camaleón wrote:
> On Wed, 23 Jun 2010 13:02:36 -0600, Aaron Toponce wrote:
>> Whether or not these are his reasons, I can tell you why that is a wise
>> move. UUIDs are unique to the device/filesystem. The major advantage of
>> using UUIDs is that you don't have to worry about reordering of disks by
>> the kernel when it sees it in a different order than previous.
>
> Yes, I know.
>
> But if the installer has setup (by its own) as default method for naming
> devices the old one and I am not experiencing any problem with that, for
> sure I won't change that. If it ain't broke, don't fix it.

Sure. But you can also avoid breakage through proper administration.

>> This isn't recommended, because if the Linux kernel developers change
>> drivers, and the drives become a new device (just as it happened when
>> ditching the PATA driver for SATA, and /dev/hda became /dev/sda), your
>> partitions/volumes won't mount. Instead, you should either be using
>> LABELs or UUIDs.
>
> I know, I know... but Lenny developers decided to go this way for any
> reason and I will respect that. I'm aware that nowadays any modern
> distribution is using "uuid" or "id" at least in "/etc/fstab" but as I
> said, I still have not seen any good reason to change it.

So, you blindly accept what the developers think is good for your
system? I understand they're developers for a reason, but even
developers make mistakes. And having "/dev/sd??" in your /etc/fstab just
might be one of them.

FWIW, when the kernel switched disk drivers from PATA to SATA for
identifying IDE drives, I had already moved my /etc/fstab to UUIDs, and
I didn't have a problem with the upgrade. Friends of mine, however, got
to rescue their system, because it wouldn't boot. To each their own.

--
. O . O . O . . O O . . . O .
. . O . O O O . O . O O . . O
O O O . O . . O O O O . O O O