Jump to content

Photo

[SOLVED] Grub2: Loopback boot of Bodhi Linux 2.0.0 iso fails


  • Please log in to reply
25 replies to this topic

#1 sogae

sogae

    Member

  • Members
  • 16 posts
  • LocationGermany

Posted 28 July 2012 - 11:04 AM

Hi.

I (manually) made a multiboot-USB Stick with Grub2.
In the past the Bodhi 1.4 iso booted perfectly with Grub2's loopback boot function.
Now I'm trying to boot Bodhi 2.0.0 this way. I just edited my grub.cfg to point to the right iso image file - everything else remains unedited.
When booting the Bodhi 2.0.0 image I get the error "unable to find a medium containing a live file system".
I already checked the iso's md5, it's fine.
My Ubuntu 12.04 iso boots as well as previous versions of Ubuntu, just by editing the grub.cfg in the same way as I've done it with the Bodhi entry now.
Has something changed significantly in Bodhi's boot process, that differs from the standard Ubuntu?

Here is my grub.cfg entry for Bodhi which doesn't boot:

# Entry 01 - Bohdi Linux
menuentry "Bohdi Linux 2.0.0 (32bit) (Enlightenment)" {
  loopback loop /boot/iso/bodhi-2.0.0-32.iso
  linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=/boot/iso/bodhi-2.0.0-32.iso file=(loop)/preseed/custom.seed quiet locale=de_DE bootkdb=de console-setup/layoutcode=de splash --
  initrd (loop)/casper/initrd.gz
}

Here are my grub.cfg entrys for Bodhi 1.4 and Ubuntu which are booting fine:

# Entry 01 - Bohdi Linux
menuentry "Bohdi Linux 1.4 (32bit) (Enlightenment)" {
  loopback loop /boot/iso/bodhi_1.4.0.iso
  linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=/boot/iso/bodhi_1.4.0.iso file=(loop)/preseed/custom.seed quiet locale=de_DE bootkdb=de console-setup/layoutcode=de splash --
  initrd (loop)/casper/initrd.gz
}

# Entry 05 - Ubuntu 12.04
menuentry "Ubuntu 12.04 LTS (32bit) [Unity]" {
  loopback loop /boot/iso/ubuntu-12.04-desktop-i386.iso
  linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=/boot/iso/ubuntu-12.04-desktop-i386.iso quiet locale=de_DE bootkdb=de console-setup/layoutcode=de splash noeject noprompt --
  initrd (loop)/casper/initrd.lz
}

Maybe someone can help me with my issue.
Thanks in advance.

sogae



A big thank you to everyone who contributes to Bodhi Linux


#2 fassil

fassil

    Member

  • Members
  • 347 posts

Posted 28 July 2012 - 11:37 AM

Hi,

Yep, first, try bodhi instead of bohdi for the entry ;)

A +
The truth is spread out. J.Derrida

Mini-311c XPsp3/Bhodi-2.0.1/Bhodi-1.4.0

#3 sogae

sogae

    Member

  • Members
  • 16 posts
  • LocationGermany

Posted 28 July 2012 - 11:46 AM

Oh. :rolleyes:

Very attentive, thank you.
But I guess this will not solve my actual problem ... ;)

#4 fassil

fassil

    Member

  • Members
  • 347 posts

Posted 28 July 2012 - 12:35 PM

You guess or you are are sure ?

I've recreated the same mistake with a recovery entrie (to be sure but safely) & it didn't boot on anymore...

good luck

edit: Sorry, it reboot, I'm a bit tired...

good luck again
The truth is spread out. J.Derrida

Mini-311c XPsp3/Bhodi-2.0.1/Bhodi-1.4.0

#5 sogae

sogae

    Member

  • Members
  • 16 posts
  • LocationGermany

Posted 28 July 2012 - 02:08 PM

Yes, I'm pretty sure.
Because it just affects the displayed title of this entry inside of Grub2's boot menu.

I really wonder why bodhi 2.0.0 fails to boot that way, because it's based on Ubuntu (which boots very well).

#6 sogae

sogae

    Member

  • Members
  • 16 posts
  • LocationGermany

Posted 28 July 2012 - 02:52 PM

I researched a bit.

Bodhi 1.4 iso's initrd contains the script "/scripts/casper-premount/20iso_scan".

Bodhi 2.0.0 iso's initrd does not contain the script "/scripts/casper-premount/20iso_scan"!

I guess this difference prevents Grub2 from booting the Bodhi 2.0.0 iso image.
What do you think about my assumption?

Next step for me is to build a new initrd containing this script and exchange the Bodhi 2.0.0 iso on my Multiboot Stick with the new one.

If this will solve my issue what are the odds that a fixed Bodhi iso (maybe a version 2.0.1) will be released?

#7 Jeff

Jeff

    Lead Developer

  • Developer
  • 12493 posts
  • LocationBloomington, IL

Posted 29 July 2012 - 07:01 AM

I recall a user requesting during our 1.2.0 or 1.3.0 release that I add an extra package to the ISO image that adds the ability to boot the ISO image directly from grub - do you have any idea what this package is called? Because I do not and I cannot seem to find the old forum post at this time.

If you can find I am more than happy to add it to the next release.

~Jeff

#8 Elw3

Elw3

  • Moderators
  • 1769 posts

Posted 29 July 2012 - 07:25 AM

lupin-casper or lupin-support, those two packages look promising
Bad Wolf

#9 gohlip

gohlip

    Member

  • Members
  • 664 posts

Posted 29 July 2012 - 08:44 AM

I recall a user requesting during our 1.2.0 or 1.3.0 release that I add an extra package to the ISO image that adds the ability to boot the ISO image directly from grub - do you have any idea what this package is called? Because I do not and I cannot seem to find the old forum post at this time.

If you can find I am more than happy to add it to the next release.

~Jeff


That would be me and yes, the package "lupin-casper" is still missing in Bodhi 2.

Sogae, install lupin-casper before you remaster your Bodhi OS.
You menu entry looks fine. I don't use locale-de, but here's mine if it helps.

menuentry "Podhi O" {
insmod part_msdos
insmod ext2
set isofile="/biso/bodhi.iso"
search --no-floppy --file --set=root $isofile
loopback loop $isofile
linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile nopersistent noeject noprompt noatime ro
initrd (loop)/casper/initrd.gz
}

Oh, I also remove /~home/.e/e/config/profile1-8 (not profile.cfg) before remastering each time.
And if you remaster from a booted up iso (yes, you can do that! But remaster to a different partition.), at /etc/remastersys.conf, make sure you have the following in the EXCLUDE line
EXCLUDES="/cdrom /isodevice /rofs /sys"
but note kernel changes (for remastering iso files) are not remastered without much complicated maneuvers.


ps: Bodhi is the best OS, IMHO, for putting in a portable usb,(together with grub2),
you can include "toram" in the linux line, but I find this unnecessary nowadays for most computers, nor a swap in usb for it.

Life is a sexually transmitted disease with a 100% mortality rate.


#10 sogae

sogae

    Member

  • Members
  • 16 posts
  • LocationGermany

Posted 29 July 2012 - 12:47 PM

Thanks to all of you for your help.

Jeff, I can confirm that the package lupin-casper (which is missing in Bodhi 2.0.0 iso) is needed to create an initrd which is capable of iso loopback booting, because it contains the needed file "/usr/share/initramfs-tools/scripts/casper-premount/20iso_scan".
It would be very nice if the next Bodhi release will be loopback bootable again.

Gohlip, thank you for your hints about remastering.

ps: Bodhi is the best OS, IMHO, overall! ;)

#11 Jeff

Jeff

    Lead Developer

  • Developer
  • 12493 posts
  • LocationBloomington, IL

Posted 29 July 2012 - 03:17 PM

Thanks guys. 2.0.1 is coming due to firmware issues - this will be added as well.

~Jeff

#12 gohlip

gohlip

    Member

  • Members
  • 664 posts

Posted 29 July 2012 - 03:36 PM

Gohlip, thank you for your hints about remastering.


Glad it works well for you now and you're welcome.

ps: Bodhi is the best OS, IMHO, overall! ;)


Careful, it can get better and we don't want Jeff to get too arrogant now, do we? :)
[Look what happen to Mark Shuttleworth, Dictator for Life and he takes it seriously; we don't want that to happen to our Jeff.]

But seriously, thanks again, Jeff. Good job.

There's a write up on Bodhi ....
http://www.techradar...ibution-1090058

Even though it's complimentary, but I think Bodhi's much more than just its speed.

Life is a sexually transmitted disease with a 100% mortality rate.


#13 sogae

sogae

    Member

  • Members
  • 16 posts
  • LocationGermany

Posted 31 July 2012 - 12:31 PM

Careful, it can get better and we don't want Jeff to get too arrogant now, do we? :)
[Look what happen to Mark Shuttleworth, Dictator for Life and he takes it seriously; we don't want that to happen to our Jeff.]


:unsure: :rolleyes: :)


Thanks guys. 2.0.1 is coming due to firmware issues - this will be added as well.


Bodhi 2.0.1 is out and my issue is fixed. Thank you, Jeff, for scratching my itch ... B)

#14 dman

dman

    Member

  • Members
  • 53 posts
  • LocationWiesbaden, Germany

Posted 30 September 2013 - 10:55 AM

I boot ISOs from grub2 sometimes too. I can boot 32-bit versions of Bodhi 2.3 and 2.4 from "out-of-the-box" ISOs on my X2 AMD hardware easily. But I cannot get the 64-bit 2.4.0 ISO to boot from the ISO. I get a kernel panic and machine lock-up with blinking keyboard lights. I've tried various things in my grub menu iterations, but I'm basically grasping at straws. Anybody got this working for 64-bit?

#15 gohlip

gohlip

    Member

  • Members
  • 664 posts

Posted 30 September 2013 - 12:06 PM

I boot ISOs from grub2 sometimes too. I can boot 32-bit versions of Bodhi 2.3 and 2.4 from "out-of-the-box" ISOs on my X2 AMD hardware easily. But I cannot get the 64-bit 2.4.0 ISO to boot from the ISO. I get a kernel panic and machine lock-up with blinking keyboard lights. I've tried various things in my grub menu iterations, but I'm basically grasping at straws. Anybody got this working for 64-bit?

Possibly, just a possibility, your graphics driver may not have dkms done properly.
Try booting with nomodeset in the grub linux line.
If that is the case, take heart, problem happens only in precise (which bodhi is based on), when it goes to quantal or rxxxx (?) or saucy, problem is fixed in the newer graphics drivers.
[too much work to fix currently with so many drivers - you can fix it using the manufacturer's direct website or just use older kernel, not 3.8.x]
Once you use older kernel, remaster it and it will boot that iso without nomodeset and with driver installed.

ps: I boot latest bodhi 64 bit 2.4 iso with kernel 3.5.x (3.2.x is fine too) with graphics driver installed.
My kubuntu is also fine with 3.11.x with graphics (and dkms) - same computer.

Life is a sexually transmitted disease with a 100% mortality rate.


#16 dman

dman

    Member

  • Members
  • 53 posts
  • LocationWiesbaden, Germany

Posted 30 September 2013 - 10:38 PM

Possibly, just a possibility, your graphics driver may not have dkms done properly.
Try booting with nomodeset in the grub linux line.


Thanks. Sounded promising, because I have a Radeon 4350 card and it is problematic in some Linuxes. But I got the same kernel panic and lockup.

Here is what I last tried as the menuentry:

menuentry "Bodhi Linux ISO" {
  insmod part_msdos
  insmod ext2
  set root=(hd0,msdos3)
  set isofile='/iso/bodhi-2.4.0-64.(000).iso'
  search --no-floppy --file --set=root $isofile

  loopback loop ($root)$isofile
  linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile \
         file=(loop)/preseed/custom.seed live-media-path=casper      \
         noeject noprompt nomodeset --
  initrd (loop)/casper/initrd.gz
}

Here's the console:
Kernel panic

Any ideas appreciated.
/dman

#17 gohlip

gohlip

    Member

  • Members
  • 664 posts

Posted 01 October 2013 - 02:19 AM

First..

loopback loop ($root)$isofile
linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile \
file=(loop)/preseed/custom.seed live-media-path=casper \
noeject noprompt nomodeset --


Try instead
loopback loop $isofile
linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile  noeject noprompt noatime nomodeset ro 

If still not bootable, then (normal) install Bodhi into a partition.
Check if this normal install can boot with 3.8.x
Otherwise boot into 3.2.x or 3.5.x and if okay, remaster an iso with it.
The iso file should then be bootable.

Good luck.

note: [reason] - booting original iso file means always booting 3.8 kernel; can only try with 'nomodeset'; cannot allow for booting 3.2 or 3.5 kernel.

Life is a sexually transmitted disease with a 100% mortality rate.


#18 dman

dman

    Member

  • Members
  • 53 posts
  • LocationWiesbaden, Germany

Posted 02 October 2013 - 11:54 AM

Try instead

loopback loop $isofile
linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=$isofile  noeject noprompt noatime nomodeset ro 

If still not bootable, then (normal) install Bodhi into a partition.
Check if this normal install can boot with 3.8.x
Otherwise boot into 3.2.x or 3.5.x and if okay, remaster an iso with it.
The iso file should then be bootable.


Thanks for the ideas. Nothing really changed, though, with the altered
linux-loop line for grub. (I'll have to look to see what "noatime" is
for and what the "--" I had at the end was supposed to do. "ro" seems
implied anyway by a non-writeable ISO, but can't hurt.)

I took another photo of the boot failure, but it looks essentially like
the first one I posted, so I won't bother posting it unless you want to
see it.

I don't have a ready technique in my toolkit for remastering, not yet
ever having done that with a Linux distro. I'm sure I could figure it
out with some web-search help, but if you have some easy references
at had, that would be helpful. I see some remarks of yours up above
in this thread, from last year, but will have to read that a couple of
times to digest it.

That said, I want the ISO to boot, for one, because I am too lazy or
stingy to burn a DVD (and because it seems wasteful and unnecessary)
and because it's a bit of a pain to load the various distros onto a
USB stick all the time. And because I enjoy knowing how to boot ISOs
from grub, though I admit I have had trouble with a number of distros --
as in, I couldn't get them to boot directly from ISOs despite hours
of screwing around. All the ones I couldn't boot so far were 64-bit
versions. I had lots of trouble with Debian 7.x Live, but did finally
get that to work.

Why do I want to upgrade the 3.2x kernel to 3.8.x, anyway? (I do have
a version of Raring on this machine, and I do know that each new Ubuntu
distro bumps the kernel. As a matter of fact, I have five working
Linuxes booting "real" on this machine and four more booting as VMs,
though I also run Win 8 Pro both in a real and a virtual scenario
and happen to be in that at this moment.) :-)

/d

#19 gohlip

gohlip

    Member

  • Members
  • 664 posts

Posted 02 October 2013 - 04:21 PM

Thanks for the ideas. Nothing really changed, though,

Okay (like me), looks like you will need to boot 3.5 or 3.2 kernel to make current Bodhi version work.
or see last line of this post

I don't have a ready technique in my toolkit for remastering,

http://forums.bodhilinux.com/index.php?showtopic=5697&view=getnewpost
but note the developer will no longer continue with it.
http://www.remastersys.com/
But there is a fork called system-imager.


That said, I want the ISO to boot, for one, because I am too lazy or...

Right, understand; but it's more useful than just that.

All the ones I couldn't boot so far were 64-bit
versions.

Hope this does not apply to you..
http://askubuntu.com...d-64-bit-ubuntu
"Ok, now I'm certain that it is due to the fact that one partition is 32-bit and one is 64-bit."

Life is a sexually transmitted disease with a 100% mortality rate.


#20 dman

dman

    Member

  • Members
  • 53 posts
  • LocationWiesbaden, Germany

Posted 03 October 2013 - 10:24 AM

Okay (like me), looks like you will need to boot 3.5 or 3.2 kernel to make current Bodhi version work.


Since 3.2.x is the stock kernel [I am editing this reply. I have meanwhile installed the 64-bit version of 2.4.0, and I see why I was confused at some of what you wrote. I see that the 64-bit version uses the 3.8.x kernel by default -- as opposed to 3.2.x for the non-PAE 32-bit version I also tried] for the Bodhi 2.4.0 ISO downloaded from the bodhilinux.com site, and since that is what I have been trying to boot from grub, I don't understand your comment. I also still am unclear on what the later kernels are supposed to fix to aid my problem. I have a couple of Linuxes on this machine that run 3.2.x (and are 64-bit), and they are fine and I can boot them from ISOs as a rule. (E.g., Ubuntu ISOs are always bootable from ISOs for me on this system.)

If I install Bodhi normally, it will have the 3.2.x kernel "out of the box" and will be working on my system. So, yes, I could upgrade the kernel then to 3.5.x or 3.8.x or whatever and then I could remaster and stick that revised ISO in my boot scenario. What is it I am trying to accomplish by doing it that way?

[So let me re-cast my question, now that I'm editing this post. I can boot and run the stock 2.4.0 Live version (with kernel 3.8.x) from a USB stick on my hardware, and I can (and did) install it without error. (I used the YUMI Multiboot Loader downloaded from pendrivelinux.com.) Why can't I, then, boot the stock ISO from grub2? Why would downgrading the kernel to 3.5.x or 3.2.x possibly change this? Color me confused.]

Hope this does not apply to you..
http://askubuntu.com...d-64-bit-ubuntu
"Ok, now I'm certain that it is due to the fact that one partition is 32-bit and one is 64-bit."


Well, he's sure messed himself up somehow. No, that is not at all my problem. In fact, I run a completely custom grub.cfg and boot from a separate grub-dedicated partition (on /dev/sda3 on this machine). I have it fully edited and under control. I have even been planning to write up extensive blogs about how it works and why it's useful to do something like that. The OS-probers on the various Linux partitions I run do not interfere with my grub, and I know how to turn them off if desired. (I did that on one, but it is not necessary in my situation to keep grub clean.)

All that said, I do understand how grub2 can be tricked into being confused sometimes, and I had that happen recently trying to boot from a Debian-based clonezilla ISO: grub switched mid-bootstrap to another partition that has Debian on it and then locked up. I figured out what was happening (after lots of head-scratching and swearing), though, and fixed it. In fact, that's why I had the "($root)" statement before the loop path I showed up above. :-)

More later on the other things you wrote, for which I thank you profusely.

/d




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users