I have 2 installs of Devuan4 one on HD install which was upgraded from Devuan3ā¦ the other a fresh install of Devuan4 in Vbox.
So what loop devices are present in these 2 installs?
They are both the same. When you login ls /dev/lo*
shows only loop-control
, no devices loop0, loop1,...
If I do a loop mount
mkdir /tmp/nj
(to keep @Akito happy)
then
mount V*.iso /mnt/nj
the mount works and I can see the files inside the .iso
andā¦ the devices loop0, loop1, .....loop7
are now present.
So mount automatically makes them.
If I reboot they disappear, and I am back to just loop-control
So Devuan works differently, and there is no upgrade issue.
In Void and Solus, the devices loop0, ... loop7
and 'loop-control` are present when you login, and are persistant. Loop mounts work in Solus and Void.
Back to Debian 11ā¦ that is my Debian 11 upgraded from Debian 10 ( which @Rosika has verified has the loop devices and will do loop mounts successfully).
When I login there are no devices loop0,.. loop7
and no loop-control
device. Loop mounts do not work.
An attempt to use losetup
failed
$ dd if=/dev/zero of=file.img bs=1MiB count=10
# losetup /dev/loop0 file.img
losetup: /dev/loop0: failed to set up loop device: No such file or directory
So, after a bit of reading I decide to see if the loop.ko
kernel module is actually present in the current kernel
# lsmod | grep loop
#
Nothing there , so add the loop module to the running kernel
# modprobe -a loop
# lsmod | grep loop
loop 36864 1
#
So now the loop module is added, look again at /dev
$ ls /dev/lo*
/dev/log /dev/loop1 /dev/loop3 /dev/loop5 /dev/loop7
/dev/loop0 /dev/loop2 /dev/loop4 /dev/loop6 /dev/loop-control
and all the loop devices are now present
Now try the loop mount again
# mount Downloads/void-live-x86_64-20210930.iso /mnt/nj
mount: /mnt/nj: WARNING: source write-protected, mounted read-only.
# ls /mnt/nj
boot LiveOS
# umount /mnt/nj
So now the loop mount works, and I can see the content of the .iso file.
So, last stepā¦ try gnome-disk-image-mounter again
# gnome-disk-image-mounter
Error creating proxy: The connection is closed (g-io-error-quark, 18)
Error creating proxy: The connection is closed (g-io-error-quark, 18)
...........
(gnome-disk-image-mounter:2952): dconf-WARNING **: 17:45:57.219: failed to commit changes to dconf: The connection is closed
..........
It brings up the file selection window , I click on the .iso file, and it fails with no message other than those above.
So failed at the last!
Correction: ā¦ gnome-disk-image-mounter works if I use it as nevj
. It does not work if I use it as root
???
Also the modprobe -a loop
is not permanent. I need to put something in /etc/modules to make it add the loop module in at every restart.
Final question:
Why is my Debian 11 install deficient in the loop.ko
module?
Three possibilities
- it was lost in upgrading from Debian 10
- Debian developers deliberately removed it from Debian 11
- Debian developers accidentally left it out of Debian 11
We can sort that out if someone has a fresh install of Debian 11 ( ie not one upgraded from Debian 10 like mine).
Would you please have a look at your /dev
ls /dev/lo*
and see if the loop device files are present?
Thanks to @Rosika and @Akito for assistence
Neville