単一のUSBデバイスでホストされているLUKSデバイスでzfsを実行しています。デバイスに障害があります(他のシステムではディスクが正しく読み取られているため、ケーブル/接続が悪い場合があります)。
しかし、GNU / Linuxにデバイスを強制的に削除させるにはどうすればよいですか?
$ zpool status
pool: freenetpool
state: SUSPENDED
status: One or more devices are faulted in response to IO failures.
action: Make sure the affected devices are connected, then run 'zpool clear'.
see: http://zfsonlinux.org/msg/ZFS-8000-HC
scan: scrub repaired 0B in 0 days 05:09:40 with 0 errors on Sun May 10 05:37:46 2020
config:
NAME STATE READ WRITE CKSUM
freenetpool DEGRADED 0 0 0
freenet DEGRADED 3 344 0 too many errors
errors: 5263 data errors, use '-v' for a list
$ sudo zpool export freenetpool
umount: /freenet: target is busy.
cannot unmount '/freenet': umount failed
$ lsof /freenet | field 2 | grep -v PID | uniq | xargs kill -9
$ sudo umount -l /freenet/
(OK)
$ sudo zpool export freenetpool
cannot export 'freenetpool': pool I/O is currently suspended
$ sudo zpool clear freenetpool
cannot clear errors for freenetpool: I/O error
$ sudo zpool clear -F freenetpool
cannot clear errors for freenetpool: I/O error
$ sudo zpool clear -FX freenetpool
cannot clear errors for freenetpool: I/O error
$ sudo zpool clear -nFX freenetpool
(OK)
$ sudo zfs unmount /freenet
cannot unmount '/freenet': not a mountpoint
$ sudo zpool destroy -f freenetpool
cannot open 'freenetpool': pool I/O is currently suspended
$ zpool detach freenetpool freenet
cannot detach freenet: pool I/O is currently suspended
$ zpool remove freenetpool freenet
cannot remove freenet: pool I/O is currently suspended
$ zpool remove freenetpool /dev/mapper/freenet
cannot remove /dev/mapper/freenet: pool I/O is currently suspended
$ zpool set cachefile=/etc/zfs/zpool.cache freenetpool
cannot set property for 'freenetpool': pool I/O is currently suspended
マシンを再起動できますが、再起動を防ぐ方法を知りたいです。
答え1
プールが一時停止すると、一時停止を解除できません。コンピュータを再起動する必要があります。