I have encountered a very similar problem. Fortunately, the answer of @user3049102 has lead me in the right direction and I have found the explanation.
The problem was with the filesystem where the image file was stored (and it seems to me it could also have been your case).
My issue was with an ISO image on a prototype of a FUSE filesystem. I was not sure if I haven't implemented something or there was some other reason. In fact, the problem is quite simple and well explained but specific to exactly the FUSE-based filesystems (like the mentioned above sshfs
, which current implementation is using FUSE). For security reasons, FUSE refuses accessing the files on the mounted filesystem to any other user besides the one who has mounted it. This behaviour can be changed by some FUSE mount options - this is explained on FUSE's gihub - see the section "Security implications".
I guess this may be an issue also with some other filesystems - so if sudo mount ... -o loop
fails with its generic error info, the first thing to do is checking if root
can access the mounted image file. Then I'd also check if the filesystem where you store the image does not have some specific properties / limitations which may also cause that a file stored there cannot be configured as a loop device.
The simplest solution, as mentioned in the answer about sshfs
, is to copy the file to some more "local" filesystem, or - at least in case of ISO images - use eg. fuseiso
to mount the image as the same user.
file R2018a_glnxa64_dvd1.iso
– Bob Aug 15 '18 at 08:19