Usage of GPT Label in place of GPTID

Status
Not open for further replies.

AxeL

Dabbler
Joined
Nov 1, 2014
Messages
11
Hi All,
I am a happy user of a FreeNAS 9.3.1 box with a 6 drives RaidZ2 pool.

I've read that as a best practice one should use GPT label/GPTID to identify disk drives in the ZFS pool.
FreeNAS by default uses GPTID, as shown in the output of my `zpool status`.

Let's say I want to switch to GPT Label (they can be shorter and more descriptive than GPTID):
  1. Is there a "GUI way" of switching from GPTID to Labels?
  2. In the GUI there is a description column under Storage->View Disks, is this field just a property in the DB or is it used as disk label?
  3. From the command line, can I just label the corresponding partitions with `glabel` or I need to detach/reattach/resilver on drive at a time?

Thanks for any suggestion
AxeL
 

Bidule0hm

Server Electronics Sorcerer
Joined
Aug 5, 2013
Messages
3,710
1. No.

2. Just a field in DB for you to tag the drives :)

3. Very bad idea, don't mess with drives, partitions, ZFS, ... in the CLI if you care about your data.

NB: I made a script to be able to identify the drives easily, look at the "Useful Scripts" link in my signature :)
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
In case the OP needs to hear it from a few people, do not mess with the drives, you are looking for trouble if you do. The advice you have received above is correct.
 

AxeL

Dabbler
Joined
Nov 1, 2014
Messages
11
3. Very bad idea, don't mess with drives, partitions, ZFS, ... in the CLI if you care about your data.

Got it :cool:

Just for me to know, on creating a new pool, does it make sense to use GPT label?

Best
AxeL
 

gpsguy

Active Member
Joined
Jan 22, 2012
Messages
4,472
When creating a new pool with FreeNAS, just let it use the GPTID's.

As @Bidule0hm said, doing this from the CLI is a bad idea. This week, a forum user posted a message, saying his system had crashed and he was surprised that FreeNAS hadn't allocated space for swap. We find out later that he'd created the pool from the CLI using whole disks, instead of using the webgui. Had he used the webgui, it would have allocated 2GB per disk for swap and made it easier to do disk replacements if the sizes don't match exactly. Yeah, he'd run into that problem too.

My (our) point, is that FreeNAS is an appliance. Let it do it's thing. If you want more control, use FreeBSD or another OS instead.

Just for me to know, on creating a new pool, does it make sense to use GPT label?
 

solarisguy

Guru
Joined
Apr 4, 2014
Messages
1,125
@AxeL, why?

P.S.
In case you were considering entering GPT label/GPTID into the disk description field. Don't! GPT label/GPTID would not change if a disk is connected differently, but the disk name will change if the disk is connected differently. Let's say ada1 might become ada0 or da2.
 

AxeL

Dabbler
Joined
Nov 1, 2014
Messages
11
My (our) point, is that FreeNAS is an appliance. Let it do it's thing. If you want more control, use FreeBSD or another OS instead.

I completely agree with you!
That's why I asked if there were a "FreeNAS" way of doing this.

Could it be a feature I can work on for version 10?
 

gpsguy

Active Member
Joined
Jan 22, 2012
Messages
4,472
Status
Not open for further replies.
Top