xfs
[Top] [All Lists]

Re: [PATCH] mkfs.xfs: add [-U uuid] option

To: Mika Eloranta <mika.eloranta@xxxxxxx>
Subject: Re: [PATCH] mkfs.xfs: add [-U uuid] option
From: Dave Chinner <david@xxxxxxxxxxxxx>
Date: Tue, 22 Sep 2015 09:36:27 +1000
Cc: xfs@xxxxxxxxxxx
Delivered-to: xfs@xxxxxxxxxxx
In-reply-to: <2640913C-6C95-4128-9055-B155AECA0206@xxxxxxx>
References: <1442855060-38259-1-git-send-email-mel@xxxxxxx> <20150921221839.GC19114@dastard> <2640913C-6C95-4128-9055-B155AECA0206@xxxxxxx>
User-agent: Mutt/1.5.21 (2010-09-15)
On Tue, Sep 22, 2015 at 01:56:53AM +0300, Mika Eloranta wrote:
> On 22 Sep 2015, at 01:18, Dave Chinner <david@xxxxxxxxxxxxx>
> wrote:
> > 
> > On Mon, Sep 21, 2015 at 08:04:20PM +0300, Mika Eloranta wrote:
> >> The UUID can now be optionally specified during filesystem
> >> creation.
> > 
> > Which UUID are you wanting to set - the metadata uuid or the
> > user visible UUID label? Or both? Can you explain the use case
> > for this?  i.e. I'm trying to work out why Why doesn't mkfs.xfs
> > + xfs_admin -U <uuid> doesn't work for you?
> 
> I want to set the user visible UUID (same as xfs_admin -U/-u).
> Whether this impacts the "metadata uuidâ or not, I do not
> know, Iâm not an expert on the XFS internals, just a user.

Which tells me what I need to know - You are trying to use the UUID
as a user controlled filesystem label. Funnily enough, we have a
thing for this already - a user controlled filesystem label:

# mkfs.xfs -L "label" ....

It's 12 characters long, so more than enough for any sort of unique
identification scheme you want to use for your filesystems.
xfs_admin enables you to change it after the fact, all major
filesystems support it and all the infrastructure know about it
(lsblk, /etc/fstab. /dev/disk/by-label, etc) so using it is no
different to using UUIDs. Except that, unlike UUIDs, you can make
fileystem labels human readable. :)

Perhaps you should try using filesystem labels seeing as everything
you need is already there?

Cheers,

Dave.
-- 
Dave Chinner
david@xxxxxxxxxxxxx

<Prev in Thread] Current Thread [Next in Thread>