ZFS dedup disable cleanup

willis936

Cadet
Joined
Dec 4, 2021
Messages
6
Is there a script or command that can rewrite-in-place a zpool to clean up dedup links after dedup has been disabled?

This would also come in handy for making links on existing pools when wanting to enable dedup after the pool has been loaded with data.

I would like to avoid having to shuffle the data to another pool.
 

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,680
No. Once dedup has been enabled, there is really no going back. There is also no way to deduplicate a pool after-the-fact.
 

willis936

Cadet
Joined
Dec 4, 2021
Messages
6
If I'm using less than 50% of the pool then could I delete all snapshots, reduce the size of the pool, make a second pool, copy the first pool into the second pool, then copy everything back?
 

Samuel Tai

Never underestimate your own stupidity
Moderator
Joined
Apr 24, 2020
Messages
5,399
Sorry, no. The dedup property is immutable once set. You'd need to offload your data, destroy the pool, recreate it without dedup, and then roll your data back.
 
Top