Renaming a TrueNAS pool is fairly simple, but it gets a little bit more complicated if the pool name contains spaces or other special characters. Pool names really should contain neither of these and arguably TrueNAS shouldn’t allow you to enter them in the first place.

If you’ve been a bit dense (i.e. like me), and you have used spaces, then you may have experienced some glitches with pool names if they contain spaces. In brief, you cannot import a pool by using its’ name if it contains spaces. You can import if you know the pool’s Id. These are steps I used to rename my pool from Pool 1 – 1TB Drives to archive.

As always, these notes are provided AS IS. and you use them at your risk. This post relates to TrueNAS version 25.04.2.4 which is the version I was using at the time of writing. You may need to check documentation if you are using a different version of TrueNAS.

Step 1: Backup & Preparation

Backup your TrueNAS configuration via the GUI – see https://www.truenas.com/docs/scale/25.04/gettingstarted/configure/setupbackupscale/

Wherever possible, disconnect any remote devices or users that are accessing the pool.

Step 2: Export / Disconnect Pool

Important: the export/disconnect of a pool will remove all references to services that use that pool (shares, containers, virtual machines etc.) If you wish to persist any of these, move them to another pool first.

In TrueNAS, got to Storage and select the pool in question. Then click on the Export/Disconnect button.

Check/tick the options Delete saved configuration from TrueNASand Confirm Export/Disconnect.

Then click on the Export/Disconnect button.

Step 3: Determine the Pool Id

Still within the Storage Dashboard, click on Import Pool

Click on the Pool drop down and you should see the pool you just exported. It’s name should be something like VerbosePoolName | SomeLongNumber. So, for me it was:

Pool 1 - 1TB Drives | 14645091355551590814

The value of SomeLongNumber is the pool Id. Either write down or copy the number – I was able to copy the text directly.

Step 4: Renaming the pool

In TrueNAS open a shell by going to System > Shell.

Import the pool by using the -f parameter to specify the pool Id. The command format is:

 zpool import -f pool_id new_pool_name 

So, for me to rename my pool to archive, I used:

zpool import -f 14645091355551590814 archive

You should then get a message along the lines of:

cannot mount '/archive': failed to create mountpoint: Read-only file system
Import was successful, but unable to mount some datasets

If you see this – despite the first message – the import was successful. Check the status using zpool status new_pool_name, for example:

zpool status archive

You will get an output that should contain the text state: ONLINE. For example:

zpool status archive
pool: archive
state: ONLINE
scan: scrub repaired 920K in 01:49:24 with 0 errors on Sun Jan 7 15:05:27 2024
...

To complete the process export using the command zpool export new_pool_name

zpool export archive

Step 5: Importing back into TrueNAS

Go to Storage and then click on Import Pool

Select the pool from the drop down menu and then click on Import. Depending on the size and complexity of the pool, this may take a few minutes to complete.

Once the import has completed, the Storage Dashboard will automatically update to show the imported and renamed pool.

Final Notes

If you were running Apps or Containers on the renamed pool – for example Docker – you can import the apps by going to Apps > Configuration > Choose Pool. However, you may need to manually update any configuration paths to reflect the new pool name.