Use host_device mode for qemu-img
When writing to a host device, possibly one that does not support holes, it is preferable to use host_device instead of the raw mode. Not doing so means holes are simply skipped and the deployed image is invalid. Change-Id: I24f8b4daf099af8bb03c3a4f6417b6c87bd49021 Closes-Bug: #1466632
This commit is contained in:
parent
6c28c22ad3
commit
63851b72ee
@ -39,7 +39,7 @@ log "Erasing existing mbr from ${DEVICE}"
|
||||
dd if=/dev/zero of=$DEVICE bs=512 count=10
|
||||
|
||||
log "Imaging $IMAGEFILE to $DEVICE"
|
||||
qemu-img convert -t directsync -O raw $IMAGEFILE $DEVICE
|
||||
qemu-img convert -t directsync -O host_device $IMAGEFILE $DEVICE
|
||||
sync
|
||||
|
||||
log "${DEVICE} imaged successfully!"
|
||||
|
Loading…
x
Reference in New Issue
Block a user