jeff / Murder Filesystem on Drive
0 喜歡
0 分支
1 檔案
最後活躍
Script all the filesystem signatures off a drive so that ZFS doesn't get all grumpy when reusing old disks.
1 | #!/bin/bash |
2 | zpool labelclear /dev/$1 |
3 | dd if=/dev/zero of=/dev/$1 bs=1M count=100 status=progress |
4 | dd if=/dev/zero of=/dev/$1 bs=1M seek=$(( $(blockdev --getsize64 /dev/$1) / 1048576 - 100 )) status=progress |
5 | wipefs --all /dev/$1 |
上一頁
下一頁