Now that our server is set up, I would like to rename our zpools.

I read somewhere that the way to do this is export & re-import under the new name. But will all my mount points and shares remain intact? Or will I have to set those up again?


Actually, you can rename a zpool. Just not live. It is done exactly as you suggested. You can only export & re-import it using the new name. 'man zpool import' explains it:

   zpool import [-o mntopts] [ -o property=value] ... [-d dir | -c cachefile] [-D] [-f] [-R root] pool | id [newpool]

   Imports  a  specific  pool.  A pool can be identified by its name or the numeric identifier. If newpool is specified, the pool is imported using the name newpool.
   Otherwise, it is imported with the same name as its exported name.

It is worth noting that while your mounts will likely survive, they won't be where they used to be, most likely. If you were, for example, importing NFS mounts on a client using<pool>/<dataset> then the mount would change to<new-pool-name>/<dataset>. Since you have to export the pool to rename it anyway, this task of renaming a pool IS a downtime event -- so if on re-import you have to reset some mounts or change some mountpoints on the server, I don't see that it's that huge a deal.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.