Comment 3 for bug 1903959

Revision history for this message
Ian Johnson (anonymouse67) wrote :

I don't think this is a race condition, snap auto-import was recently updated to only consider removable devices, so in order for snap auto-import to recognize your block device as a valid auto-import target, it must have the removable bit set in sysfs, see https://github.com/snapcore/snapd/blob/master/cmd/snap/cmd_auto_import.go#L293

TBH, it seems a bug that it worked for you on the third boot...

What I do to test auto-import of assertions with QEMU is to add the following options:

     -drive "if=none,id=stick,format=raw,file=assertions.disk,cache=none" \
     -device nec-usb-xhci,id=xhci \
     -device usb-storage,bus=xhci.0,removable=true,drive=stick \
     -usb \

where assertions.disk is the disk image that you create with auto-import.assert