Renamed pool can't be added back in GUI

ralphy

Dabbler
Joined
Feb 22, 2013
Messages
15
I wanted to rename my pool, so following instructions found elsewhere

zpool export oldname
zpool import oldname newname

In the GUI, the volume manager shows oldname having an error (as expected)

However, trying to import volume, the drop down list doesn't show the disk that the pool was on. I can Import Disk, and the relevant partition is listed, but that suggests there is no ZFS filesytem on the disk.


I can use Volume Manager to add the volume, but the 'add volume' button says the existing data will be destroyed - I don't want to do that.


Did I make a mistake?
Do I need to got to recover from backups after creating a new volume and datasets?
or have I missed some steps and all is not lost?

running 11.1-U4 under ESXi-6.5


EDIT:
Problem solved.... some additional steps were required to complete the task.
The steps I took were:
zpool export oldname
zpool import oldname newname
zpool export newname

in the GUI
  • in sharing: delete the samba share to oldname (may not be necessary, but I did)
  • in storage: detach oldname
  • reboot
  • in storage: import volume from GUI
 
Last edited:

ralphy

Dabbler
Joined
Feb 22, 2013
Messages
15
Well the plot thickens ....

I can actually see all my data under /mnt/newname, so all is not lost.

I also deleted the smb share to /mnt/oldname, but still no luck in importing the volume of data at /mnt/newname.
 

ralphy

Dabbler
Joined
Feb 22, 2013
Messages
15
Thanks dand35.

Unfortunately, I also tried zpool export newname, but that didn't help.

Having found that the data was still mounted, I had a little more courage to forge ahead.

The steps I took were:
#zpool export oldname
#zpool import oldname newname
#zpool export newname

in the GUI
  • in sharing: delete the samba share to oldname (may not be necessary, but I did)
  • in storage: detach oldname
  • reboot
  • in storage: import volume from GUI
Sigh of relief.
 
Joined
Jan 18, 2017
Messages
525
Likely the fact that you did not detach the volume in the GUI as the first step caused the issue, a couple of months ago I did
GUI detach
#zpool import oldname newname
#zpool export newname
GUI import

one two separate pools which worked perfectly.
 

jasonboche

Dabbler
Joined
Oct 2, 2018
Messages
25
Good morning,

I just wanted to leave a note and thank you both for saving my bacon. When I originally built my FreeNAS, I created a pool name that was descriptive of the underlying drive layout. Mirror2x6x1TB_slog_pool. I've since started working with snapshots, schedules, and clones for restoring data. I found out through a rather dubious error message when creating the extent that my device name was too long.

2020-04-16_22-00-08.jpg

I came here looking for a solution on how to rename my pool as the option didn't exist in the GUI. You really came through for me in this forum post. I verified the pool name in the shell.

2020-04-16_23-02-07.jpg

Shut down my workloads, stopped the iSCSI and NFS services. Removed the automated snapshot tasks associated with the zvol and datasets. Then Exported/disconnected the pool in the GUI.

2020-04-16_23-03-49.jpg

Renamed the pool in the shell by using the zpool import command. Then exported the pool so I could import it with the new name in the GUI.

2020-04-16_23-09-16.jpg

After this it was a cakewalk to recreate the zvol extents and present them back out with their LUN numbers.

2020-04-17_10-02-57.jpg

In my test environment the vSphere hosts picked back up the LUN with no fuss. In my prod environment however, I had to resignature all of the datastores and unregister/reregister the vSphere virtual machines. Not big deal as I have scripts for this process but I don't know what the difference was in the prod environmet. It just ended up taking a while longer with more careful steps being taken on the vSphere side.

I've worked with a lot of different storage arrays but I'm still pretty new to FreeNAS and I've made a few blunders while learning on this journey. For instance, I mistakenly promoted a clone but I'm quickly trying to forget that nightmare!

Thanks again!
 
Top