mirror of
https://github.com/kneutron/ansitest.git
synced 2025-01-16 04:42:55 +08:00
Sim disk failure in VM
This commit is contained in:
parent
a84264bb2d
commit
24725fd747
9
VIRTBOX/faildisk.sh
Normal file
9
VIRTBOX/faildisk.sh
Normal file
@ -0,0 +1,9 @@
|
||||
#!/bin/bash
|
||||
#d2f=$(ls -l /sys/dev/block |awk '/'$1'/ {print $9}')
|
||||
|
||||
echo "Failing $1"
|
||||
echo offline > /sys/block/$1/device/state
|
||||
echo 1 > /sys/block/$1/device/delete
|
||||
|
||||
sleep 2
|
||||
dmesg|grep $1
|
Loading…
x
Reference in New Issue
Block a user