I recently created a new zpool over 8 disks with 4 mirrors. Today I attached the disks to a linux server and an old deprecated zpool is now showing up with zpool import which uses the same disks as the new one. I found out that the new pool is located on partition 1 of each disk:

Using /dev/sda
(parted) print
Model: ASMT 2105 (scsi)
Disk /dev/sda: 3001GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
Disk Flags:

Number  Start   End     Size    File system  Name  Flags
1      1049kB  3001GB  3001GB  zfs          zfs

When I have a look at the labels on partition 1 with zdb I see that the correct pool configuration is stored here. So I think the old deprecated zpool informations must be somewhere on the first 1049kb of the disk because partition 1 starts at 1049kB. I'd like to zero out the first 1049kB of each disk with dd but I'm not 100% sure how big the block size and count has to be. Can someone help me with my command to be absolutely sure that I won't destroy the new pool information. Something like:

dd if=/dev/sda bs=1024 count=1049

Thanks in advance

  • I used the whole disk for the zpool and the partition has been created by zfs. It's not possible with zpool commands to import the pool or destroy it. And if it would be I would probably also destroy the new pool because the same disks are in use. – Nenzo Jan 6 '17 at 14:22
  • Have you considered destroying and recreating your zpool.cache file? Does the output of the zdb command show anything that shouldn't be there? If so, destroy and recreate your zpool.cache file. – airhuff Jan 14 '17 at 2:38

Your Answer

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

Browse other questions tagged or ask your own question.