diff options
| author | John Ogness <john.ogness@linutronix.de> | 2018-03-20 21:39:58 +0100 |
|---|---|---|
| committer | John Ogness <john.ogness@linutronix.de> | 2018-03-20 21:39:58 +0100 |
| commit | 8b00ac2e9c3f434793cbfda376cf58e2d6ae4503 (patch) | |
| tree | 84d626fb97c5dff9f061e6fe159903ffd2b97212 /lx-trainer-vm | |
| parent | dfc810e07e10787a72291c81b1bd6946d1379349 (diff) | |
dd-multi.sh: loop partprobe until success
When partitioning many devices, it is possible that partprobe
returns with a "EBUSY" error. Loop until partprobe succeeds.
Signed-off-by: John Ogness <john.ogness@linutronix.de>
Diffstat (limited to 'lx-trainer-vm')
| -rwxr-xr-x | lx-trainer-vm/dd-multi.sh | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lx-trainer-vm/dd-multi.sh b/lx-trainer-vm/dd-multi.sh index 2408a66..c99fca7 100755 --- a/lx-trainer-vm/dd-multi.sh +++ b/lx-trainer-vm/dd-multi.sh @@ -75,7 +75,10 @@ for dest in $DESTS; do done # rescan devices -partprobe $DESTS +while ! partprobe $DESTS; do + echo "waiting for partprobe..." + sleep 1 +done # wait for partitions to appear for dest in $DESTS; do |
