Debian: No common CD-ROM drive was detected #85

Closed
bagage opened this Issue Jan 2, 2017 · 16 comments

Comments

Projects
None yet
9 participants
@bagage
Contributor

bagage commented Jan 2, 2017

Issue

Blocked when installing Debian to second step Detect and mount CD-ROM.

I'm trying to install a Debian net-install ISO using master, but it fails at this step. According to a comment on cobbler#1518:

nacc:

I think I recalled now what is needed. When you use Debian or Ubuntu (in my experience), you need to replace the kernel and initrd from the full ISO with that from the netinstaller. Can you verify this fixes the issue?
So, what I'm suggesting is use the *DVD-1.iso and then copy over to /var/lib/cobbler appropriately the initrd & kernel from the corresponding netinst.iso.

I also tried with Debian stable ISO or Debian live one, but still facing the same issue.

Workaround

None found yet, except of using another OS (windows, archlinux work OK) or maybe another USB installer software. See comment #85 (comment)

@mbusb

This comment has been minimized.

Show comment
Hide comment
@mbusb

mbusb Jan 4, 2017

Owner

There is one more workaround within multibootusb itself. Make bootable USB from imager option. Let me know if you find any other solution exist.

Owner

mbusb commented Jan 4, 2017

There is one more workaround within multibootusb itself. Make bootable USB from imager option. Let me know if you find any other solution exist.

@bagage

This comment has been minimized.

Show comment
Hide comment
@bagage

bagage Jan 4, 2017

Contributor

@mbusb: I tried that but it doesn't work. I did:

  1. Install the Debian netinstall ISO via imager ISO option
  2. Run qemu from CLI (due to #88): `
  3. Select "Install" (and/or "Graphical install", same output), then press [enter], [enter], [enter].
  4. Then "No common CD-ROM drive was detected" appears.

edit: I also tried making the USB stick "bootable", but with no changes.
edit2: to ensure that the ISO is working, I tried (and succeeded) to use it directly using: qemu-img create -f qcow /tmp/vdisk.img 1G && qemu-system-x86_64 -hda /tmp/vdisk.img -cdrom debian-7.8.0-amd64-netinst.iso -boot d -m 1024.

Contributor

bagage commented Jan 4, 2017

@mbusb: I tried that but it doesn't work. I did:

  1. Install the Debian netinstall ISO via imager ISO option
  2. Run qemu from CLI (due to #88): `
  3. Select "Install" (and/or "Graphical install", same output), then press [enter], [enter], [enter].
  4. Then "No common CD-ROM drive was detected" appears.

edit: I also tried making the USB stick "bootable", but with no changes.
edit2: to ensure that the ISO is working, I tried (and succeeded) to use it directly using: qemu-img create -f qcow /tmp/vdisk.img 1G && qemu-system-x86_64 -hda /tmp/vdisk.img -cdrom debian-7.8.0-amd64-netinst.iso -boot d -m 1024.

@bagage

This comment has been minimized.

Show comment
Hide comment
@bagage

bagage Mar 2, 2017

Contributor

Anyone succeeded to install Debian via multibootusb? @mbusb?

Contributor

bagage commented Mar 2, 2017

Anyone succeeded to install Debian via multibootusb? @mbusb?

@bagage

This comment has been minimized.

Show comment
Hide comment
@bagage

bagage Mar 7, 2017

Contributor

Work-around

I finally succeeded using the following work-around (for amd64):

  1. Download debian netinstall from debian-installer website: debian ISO for amd64.
  2. Download hd-media files (bootloader and kernel files) for amd64 (i386 one won't work). Must get initrd.gz as well as vmlinuz.
  3. Use multibootusb to create the Debian entry, as usual
  4. Then mount the partition, say in /mnt.
  5. Replace vmlinuz and initrd.gz with the hd-media ones (assuming they are in the same folder as the current prompt):
    find /mnt/multibootusb/debian-7.8.0-amd64-netinst/ -name vmlinuz -exec sudo cp vmlinuz {} \;
    find /mnt/multibootusb/debian-7.8.0-amd64-netinst/ -name initrd.gz -exec sudo cp initrd.gz {} \;
    
  6. Copy debian ISO on the USB stick direcly: cp debian-stretch-DI-rc2-amd64-netinst.iso /mnt/multibootusb/. You can also put it in /mnt/multibootusb/debian-7.8.0-amd64-netinst/, but in that case Debian installer will yield that it could not find the ISO and will ask if you want it to search more. You have to hit Yes.
Contributor

bagage commented Mar 7, 2017

Work-around

I finally succeeded using the following work-around (for amd64):

  1. Download debian netinstall from debian-installer website: debian ISO for amd64.
  2. Download hd-media files (bootloader and kernel files) for amd64 (i386 one won't work). Must get initrd.gz as well as vmlinuz.
  3. Use multibootusb to create the Debian entry, as usual
  4. Then mount the partition, say in /mnt.
  5. Replace vmlinuz and initrd.gz with the hd-media ones (assuming they are in the same folder as the current prompt):
    find /mnt/multibootusb/debian-7.8.0-amd64-netinst/ -name vmlinuz -exec sudo cp vmlinuz {} \;
    find /mnt/multibootusb/debian-7.8.0-amd64-netinst/ -name initrd.gz -exec sudo cp initrd.gz {} \;
    
  6. Copy debian ISO on the USB stick direcly: cp debian-stretch-DI-rc2-amd64-netinst.iso /mnt/multibootusb/. You can also put it in /mnt/multibootusb/debian-7.8.0-amd64-netinst/, but in that case Debian installer will yield that it could not find the ISO and will ask if you want it to search more. You have to hit Yes.
@ierpe

This comment has been minimized.

Show comment
Hide comment
@ierpe

ierpe Mar 20, 2017

Hi,

I have this problem on a (very) old laptop, i386 arch.
The setup starts but "cannot mount the CD-ROM".
Any workaround would be appreciated :)

ierpe commented Mar 20, 2017

Hi,

I have this problem on a (very) old laptop, i386 arch.
The setup starts but "cannot mount the CD-ROM".
Any workaround would be appreciated :)

@mbusb

This comment has been minimized.

Show comment
Hide comment
Owner

mbusb commented May 15, 2017

Documented this in official site http://multibootusb.org/page_faq/#debiann-no-common-cd-rom-drive-was-detected

Closing the issue.

@mbusb mbusb closed this May 15, 2017

@Erudition

This comment has been minimized.

Show comment
Hide comment
@Erudition

Erudition Sep 12, 2017

Better workaround:
For many installers, mounting the flash drive (say, /dev/sdb1) to /cdrom does the trick. However, in this case that still fails because the iso contents are not directly on the drive but in a subdirectory. So what if we instead mount that subdirectory at /cdrom?
We'll have to mount the drive itself somewhere else. For example
mount /dev/sdb1 /mnt/flash
Then, we can "mount" the folder with the installer contents onto /cdrom by making a symlink:
ln -s /mnt/flash/multibootusb/nameofdebianimagehere/ /cdrom
That's it!

Notes:

  • This can be accomplished in the installer menu item for launching a shell session, which will then return to the installer, or you can hit Ctrl+Alt+F(5 or any other number) to switch to a tty session, then return by looking for the tty the installer was on.
  • Obviously you should ls /mnt/flash/multibootusb/ to see what your target folder should be. Also, tab completion is your friend!
  • You may need to rm /cdrom first so you can replace it with the symlink.
  • Don't forget the -s, hardlinks can't cross devices so this must be a symlink.

This issue should be reported to upstream (debian). Other distros work fine without this treatment.

Better workaround:
For many installers, mounting the flash drive (say, /dev/sdb1) to /cdrom does the trick. However, in this case that still fails because the iso contents are not directly on the drive but in a subdirectory. So what if we instead mount that subdirectory at /cdrom?
We'll have to mount the drive itself somewhere else. For example
mount /dev/sdb1 /mnt/flash
Then, we can "mount" the folder with the installer contents onto /cdrom by making a symlink:
ln -s /mnt/flash/multibootusb/nameofdebianimagehere/ /cdrom
That's it!

Notes:

  • This can be accomplished in the installer menu item for launching a shell session, which will then return to the installer, or you can hit Ctrl+Alt+F(5 or any other number) to switch to a tty session, then return by looking for the tty the installer was on.
  • Obviously you should ls /mnt/flash/multibootusb/ to see what your target folder should be. Also, tab completion is your friend!
  • You may need to rm /cdrom first so you can replace it with the symlink.
  • Don't forget the -s, hardlinks can't cross devices so this must be a symlink.

This issue should be reported to upstream (debian). Other distros work fine without this treatment.

@thorsummoner

This comment has been minimized.

Show comment
Hide comment
@thorsummoner

thorsummoner Oct 19, 2017

@Erudition Can i get a link to the debian but report?

@Erudition Can i get a link to the debian but report?

@thorsummoner thorsummoner referenced this issue in aguslr/multibootusb Oct 19, 2017

Closed

Debian: No common CD-ROM drive was detected #124

@robertwolter

This comment has been minimized.

Show comment
Hide comment
@robertwolter

robertwolter Nov 26, 2017

I tried to use the suggested workarounds, but they didn't work for me.
I tested:
debian-9.2.1-amd64-netinst.iso
debian-live-9.2.0-amd64-xfce+nonfree.iso

I can't mount any existing partition though they are shown by blkid.
ls -la /dev/sdb* shows that /dev/sdb and the multibootusb partition /dev/sdb1 do exist.
Using the graphic installer I tried in a shell:
mkdir /flash
mount -t ext4 /dev/sdb1 /flash
I only got an error message that the device does not exist. The mount command fails completely.

I tried to use the suggested workarounds, but they didn't work for me.
I tested:
debian-9.2.1-amd64-netinst.iso
debian-live-9.2.0-amd64-xfce+nonfree.iso

I can't mount any existing partition though they are shown by blkid.
ls -la /dev/sdb* shows that /dev/sdb and the multibootusb partition /dev/sdb1 do exist.
Using the graphic installer I tried in a shell:
mkdir /flash
mount -t ext4 /dev/sdb1 /flash
I only got an error message that the device does not exist. The mount command fails completely.

@thorsummoner

This comment has been minimized.

Show comment
Hide comment
@thorsummoner

thorsummoner Nov 27, 2017

@robertwolter

This comment has been minimized.

Show comment
Hide comment
@robertwolter

robertwolter Nov 28, 2017

Now the reason is clear:
The mount command simply can't work because the module ext4 is missing in busybox in all Debian ISOs.

Now the reason is clear:
The mount command simply can't work because the module ext4 is missing in busybox in all Debian ISOs.

@tripLr

This comment has been minimized.

Show comment
Hide comment
@tripLr

tripLr Jan 29, 2018

is there a script we can put in the usb drive during boot that will tell grub to run the special mount for the debian disto's ? debian iso installed onto a single usb boot seem to work fine. whats the difference, I am new to this. thanks

tripLr commented Jan 29, 2018

is there a script we can put in the usb drive during boot that will tell grub to run the special mount for the debian disto's ? debian iso installed onto a single usb boot seem to work fine. whats the difference, I am new to this. thanks

@thorsummoner

This comment has been minimized.

Show comment
Hide comment
@thorsummoner

thorsummoner Feb 5, 2018

@mbusb

This comment has been minimized.

Show comment
Hide comment
@mbusb

mbusb Feb 5, 2018

Owner

Any of you tried booting Debian directly from ISO? Does the same issue occur in direct ISO booting as well?

Owner

mbusb commented Feb 5, 2018

Any of you tried booting Debian directly from ISO? Does the same issue occur in direct ISO booting as well?

@wijnand2

This comment has been minimized.

Show comment
Hide comment
@wijnand2

wijnand2 Feb 24, 2018

Couldn't get the debian-9.3.0-amd64-netinst iso to work after making a bootable usb with unetbootin due to the error described in this issue. The workarounds suggested here didn't work either (possibly due to a lack of linux know-how but I did follow them to the best of my abilities). Ended up trying rufus 2.18 instead of unetbootin and used the 'Write in DD Image mode' option that is presented after clicking 'start'. This way I could install debian just fine.

Couldn't get the debian-9.3.0-amd64-netinst iso to work after making a bootable usb with unetbootin due to the error described in this issue. The workarounds suggested here didn't work either (possibly due to a lack of linux know-how but I did follow them to the best of my abilities). Ended up trying rufus 2.18 instead of unetbootin and used the 'Write in DD Image mode' option that is presented after clicking 'start'. This way I could install debian just fine.

@chewi

This comment has been minimized.

Show comment
Hide comment
@chewi

chewi Mar 23, 2018

I ran into this while trying to create a multiboot system that includes an installer for Kali. I installed the hd-media kernel and initrd.gz along with the ISO as documented. I found that it would work if I started a shell, umounted /media, and then retried. I guess it can't mount the USB device at /hd-media if it's already mounted at /media. Editing /usr/lib/fetch-url/file in the initrd to umount /media after copying the preseed file also made it work first time. I checked the initrd for Stretch and that file has not changed but the issue doesn't occur there anyway because I find that /hd-media is already correctly mounted. I don't know what's changed but I guess this fix will eventually make its way into Kali.

chewi commented Mar 23, 2018

I ran into this while trying to create a multiboot system that includes an installer for Kali. I installed the hd-media kernel and initrd.gz along with the ISO as documented. I found that it would work if I started a shell, umounted /media, and then retried. I guess it can't mount the USB device at /hd-media if it's already mounted at /media. Editing /usr/lib/fetch-url/file in the initrd to umount /media after copying the preseed file also made it work first time. I checked the initrd for Stretch and that file has not changed but the issue doesn't occur there anyway because I find that /hd-media is already correctly mounted. I don't know what's changed but I guess this fix will eventually make its way into Kali.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment