[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug in wheezy images, busybox enters infinite loop when mounting .iso



Hi guys,

I found a bug in Busybox 1.20.2 (Debian 1:1.20.0-7), but before I report
it, I want to make sure it's not a dup of #367605
(https://groups.google.com/forum/?fromgroups=#!searchin/linux.debian.bugs.dist/busybox$20loop/linux.debian.bugs.dist/fT4wUlqfCV4/d920VARKhCwJ).

It seems very similar, but there are a number of significant differences,
so I think the cause for the same symptom may be something entirely
unrelated.

So, here's what I did:

Boot debian-7.0.0-amd64-netinst.iso (or any other image, I also
tested ...CD-1.iso) via grub2 installed on my USB thumb drive. This of
course only loads the kernel and initrd, so the installer fails to
"Detect and mount CD-ROM". This is perfectly expected, so I press Alt+F2,
mount my USB (mount /dev/sdb1 /mnt) and try to mount the image:

mount -o loop /mnt/debian-7.0.0-amd64-netinst.iso /cdrom

This is where the trouble begins. The command never finishes, gives no
output whatsoever, but does not hang, so you can cancel it anytime
pressing Ctrl+C. I discovered that after this, there are tons of loop
device nodes in /dev, so I suspect what happens is something like this:

Busybox tries to setup the .iso to /dev/loop0 (or any other number),
this fails, so it increases the number (creating the device node if it
does not exist) and tries again. The real bug seems to be that
setting up the loop device always fails, so the above logic enters an
infinite loop.

You can work around the bug by unpacking the iso into a folder on the
USB drive and symlinking (or bind-mounting) that to /cdrom.


Additional info:

Kernel 3.2.0-4-amd64 SMP #1 Debian 3.2.41-2 x86_64
Busybox 1.20.2 (Debian 1:1.20.0-7)
eglibc 2.13-38

I tested this on multiple machines, including a Dell PowerEdge R520 and
some Dell laptops.

Ubuntu 13.04 (server) ships Busybox 1.20.2 (Ubuntu 1:1.20.0-8ubuntu1) +
Linux 3.8.0-19, and is not affected, mounting the image works fine, I
can continue normal installation pressing Alt+F1 and selecting "Load
installer components from CD".
Likewise for Ubuntu 12.04.2 (Busybox 1.18.5, Linux 3.5.0-23).

I tried to confirm it was not a kernel bug by building a new initrd with
Ubuntu's busybox (and Ubuntu's eglibc 2.17 that it depends on), but ran
into various incompatibilities and gave up.

Can someone confirm the bug and/or my assumptions?
I would also appreciate some insight into whether this could be the same
problem as in bug #367605.

Thank you in advance.


Best regards,
Julian

PS: please CC me, as I'm not subscribed to the list.




Reply to: