Unfortunately, with 6.12 it is not possible anymore to replace a drive while keeping parity intact. The corresponding script or the manual command "dd bs=1M if=/dev/zero of=/dev/mdX status=progress" does nothing in regard of writing zeros to the drive. The script doesn't recognize the error and "thinks" it has finished correctly.
corresponding docs entry: https://docs.unraid.net/de/legacy/FAQ/shrink-array#the-clear-drive-then-remove-drive-method
Log of script:
*** Clear an unRAID array data drive *** v1.4
Checking all array data drives (may need to spin them up) ...
Found a marked and empty drive to clear: Disk 2 ( /mnt/disk2 )
* Disk 2 will be unmounted first.
* Then zeroes will be written to the entire drive.
* Parity will be preserved throughout.
* Clearing while updating Parity takes a VERY long time!
* The progress of the clearing will not be visible until it's done!
* When complete, Disk 2 will be ready for removal from array.
* Commands to be executed:
***** umount /mnt/disk2
***** dd bs=1M if=/dev/zero of=/dev/md2
You have 60 seconds to cancel this script (click the red X, top right)
Unmounting Disk 2 ...
Clearing Disk 2 ...
dd: error writing '/dev/md2': No space left on device
1+0 records in
0+0 records out
0 bytes copied, 0.000486246 s, 0.0 kB/s
A message saying "error writing ... no space left" is expected, NOT an error.
Unless errors appeared, the drive is now cleared!
Because the drive is now unmountable, the array should be stopped,
and the drive removed (or reformatted).
Script Finished Jun 19, 2023 09:22.50
Full logs for this script are available at /tmp/user.scripts/tmpScripts/Shrink Array/log.txt
Recommended Comments
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.