I unable to run
echo test > /dev/sdb in the runtime shell after connecting to this interface, is there other requirements for the block device access?
$ snap run --shell wild-block-device-filler
$ stat /dev/sdb
Size: 0 Blocks: 0 IO Block: 4096 block special file
Device: 6h/6d Inode: 880 Links: 1 Device type: 8,10
Access: (0660/brw-rw----) Uid: ( 0/ root) Gid: ( 6/ disk)
Access: 2020-12-21 11:12:47.311745859 +0800
Modify: 2020-12-21 11:12:47.311745859 +0800
Change: 2020-12-21 11:12:47.311745859 +0800
$ echo test >/dev/sdb
bash: /dev/sdb: Permission denied
The device is a USB pen drive to be specific.
- Works in devmode when run as root
- I expect the command should work when run as a regular user after connecting to the interface.