Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Installing Gentoo
  • Search

Can not boot to gentoo iso file with grub2 [SOLVED]

Having problems with the Gentoo Handbook? If you're still working your way through it, or just need some info before you start your install, this is the place. All other questions go elsewhere.
Post Reply
Advanced search
2 posts • Page 1 of 1
Author
Message
ville.aakko
Tux's lil' helper
Tux's lil' helper
Posts: 113
Joined: Sun Aug 06, 2006 1:34 pm
Location: Oulu, Finland

Can not boot to gentoo iso file with grub2 [SOLVED]

  • Quote

Post by ville.aakko » Thu Jun 24, 2021 1:15 pm

Hi,

I can not boot from the Gentoo installation CD by chainloading as per the wiki

First, the wiki is not up-to-date; gentoo and gentoo.igz do not reside in isolinux anymore but in boot.

Despite making this change, the booy process fails after it is trying to load the root filesystem. Apparently the boot process can not find the squashfs inside the looped back ISO - but, as per the wiki, it did find it at some point?

An important detail is, that I'm trying the x86 minimal installation ISO - i.e. install-x86-minimal-20210621T214502Z.iso.

<EDIT>
Other details:

grub2 boot entry:

Code: Select all

menuentry "STG3-i486" {
        set cmdline="dokeymap looptype=squashfs loop=/image.squashfs cdroot"
        set iso=/boot/install-x86-minimal-20210621T214502Z.iso
        loopback loop ${iso}
        linux  (loop)/boot/gentoo $cmdline root=/dev/ram0 init=/linuxrc initrd=/boot/gentoo.igz
        initrd (loop)/boot/gentoo.igz
}
cmdline of the failed boot:

Code: Select all

$ cat cmdline 
BOOT_IMAGE=(loop)/boot/gentoo dokeymap looptype=squashfs loop=/image.squashfs cdroot root=/dev/ram0 init=/linuxrc initrd=/boot/gentoo.igz
Also, after I've gotten to the emergency shell, if I losetup -f image.squashfs, and then give /dev/loop1 as the block device for root, I can "kind of" get the liveCD to boot. However, it can not remount the root as rw, but fails with "read only filesystem" and plethora of other errors, while trying to initialize; which is weird, since the original (USB/CD) and squashfs is still read-only. It is probable it doesn't like the fact the squasfs image is in: [mount ext4 partition]->[mount looped iso]->[losetup].
</EDIT>

Cheers!

p.s.
Before workarounds are being suggested: this is a very old PC (hence the x86 image) which can not (easily) boot from an USB drive. BIOS can not do it, but I could puit plob on an floppy to boot from USB, but it is unreliable and horribly slow (that's how I got Gentoo on the machine in the first place).

I could also burn the image to a CD as in the golden olden days, but that, too, is unreliable and slow. Old optical drives are even less reliable, and the process is usually similar to: burn->put the CD in the drive->fail because of a bad burn->burn again...).

In this case, I would much rather boot from a chainloaded .iso file, since I can already boot from MBR Grub2. As a workaround, some other boot manager (for BIOS/Legacy) could for for me!
Last edited by ville.aakko on Fri Jun 25, 2021 9:03 am, edited 2 times in total.
- Ville
Top
ville.aakko
Tux's lil' helper
Tux's lil' helper
Posts: 113
Joined: Sun Aug 06, 2006 1:34 pm
Location: Oulu, Finland

  • Quote

Post by ville.aakko » Fri Jun 25, 2021 9:02 am

Replying to myself:

This works for me:

Code: Select all

menuentry "gentoo-install-i686" {
        # set cmdline="dokeymap looptype=squashfs loop=/image.squashfs cdroot"
        set iso=/boot/gin.iso
    bootoptions="isoboot=$iso root=/dev/ram0 init=/linuxrc dokeymap looptype=squashfs loop=/image.squashfs cdroot vga=791"
        loopback loop ${iso}
        linux  (loop)/boot/gentoo $bootoptions
        initrd (loop)/boot/gentoo.igz
}
Obviously gin.iso is shorthand (renamed) for Gentoo's install-x86-minimal-20210621T214502Z.iso :D

I think the culprit here is isoboot=XXX. I'm not sure how one is supposed to know that; I found the information from many places by searching, for example this site. Seems like other distributions are not better at all..

If one is faced with the rescue shell after a failed boot, one can possibly mount the squasfs image in /mnt/livecd, but I didn't try.

:!: is there a documentation somewhere explaining the parameters the livecd kernel knows of? :!: It would be nice to find the documentation easily, as there are use cases for booting from the .iso file directly - one might have lost all their USB thumb drives etc :)

In any case, marking as SOLVED!

(Wiki page edited)
- Ville
Top
Post Reply

2 posts • Page 1 of 1

Return to “Installing Gentoo”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic