General Category > Boot Managers

Noob questions: plopkexec entry for grub2 AND/OR running plopkexec with kexec

(1/3) > >>

prenex:
Hello!

TL;DR I have two questions:

1) Can anyone show an example about how to install plopkexec into an existing grub2 as an extra entry?
2) Is it possible to run plopkexec with kexec itself? Can anyone show an example call for this latter?
+) If you think I am doing something dumb just tell me what I should do instead :-)

Rationale:

I have a laptop that cannot boot from its internal SD card reader and now has an archlinux32 installation that is fast for all things except gaming as it seems the latest drivers dropped 3D performance by 50-100%... Earlier I had an ubuntu 16.04 with good-enough 3D but it is always best to update the system or make it more light. I have failed miserably with updating to 18.04 as they tend to not test stuff as 32 bit is not supported anymore so I changed to arch32 just to find out that despite there is 3D acceleration it is too slow. Then came an idea: why don't just install a really old kernel and a really old system for which I have fglrx driver - just for playing and 3D work - and keep the original system as-is if the open drivers slowed down?

This is how I have found "kexec" originally, but from there I have found your plopkexec.

The "old" kernel I want to change into is 2.6 (really old!) and it also can do kexec already but as far as I see the target kernel does not need to know kexec to be able to kexec-ed into.

This is what I am trying:
- I have installed a really old ubuntu 8.04 on an USB stick (32bit like my machine)
- I can boot from this on a PC, but my laptop cannot boot from it. Interesting as it can boot from the arch stick I made... no UEFI though. No problem as I will install it on an internal SD card anyways.
- I have tried various kexec towards this usb key without much success (I had no success with the arch usb loader neither despite that works by bios too)
- I just want a way to start the old kerneled operating system from the new one when I want it.
- My machine cannot boot from sd card, but who cares if there is plopkexec :-)


So my plan is to first install plopexec as a menu entry in the existing grub (I have just spent days to set up arch properly so I prefer not to mess up things and this looks failsafe) and maybe even better start your app using kexec myself from a running system.

I understand that it is redundant to use kexec to run plopkexec that will indeed use kexec, but I like the menu you are providing and all the functions I see on screenshots :-)

My problem is that I find examples nowhere... I understand the concepts, but not deeply enough to write them :-(

prenex:
This is what I am thinking so far for adding plopkexec in grub2, but it seems messy to me:


--- Code: ---menuentry "Other Linux" {
#set root=(hd0,2) # I do not think I should set anything here should I?
linux /boot/plopkexec          #(add other options here as required)
initrd /boot/plopkexec.img  #(if the other kernel uses/needs one)
}

--- End code ---

I am especially unsure about the initrd part and if I need to set some root or whatever....

prenex:
Pfff murphy's law stricked as usual  ;D

Just after asking, I have found the german page here:

https://www.plop.at/de/ploplinux/desktop/grub2.html

Anyways. I was trying also to run plopkexec with kexec without luck so I am also interested in that part ;-)

These are the stuff I have tried for kexec starting:


--- Code: ---sudo ./kexec -l ./plopkexec

sudo  ./kexec -l /home/prenex/install/grub4dos/grub4dos-0.4.4/grub.exe --initrd=/home/prenex/install/kexec-tools/build/sbin/plopkexec.iso --command-line="--config-file=debug on; map --mem (rd)+1 (0xff); map --hook; chainloader (0xff)"

sudo  ./kexec -l /home/prenex/install/grub4dos/grub4dos-0.4.4/grub.exe --initrd=/home/prenex/install/kexec-tools/build/sbin/plopkexec.iso

sudo  ./kexec -l /home/prenex/install/grub4dos/grub4dos-0.4.4/grub.exe --initrd=/home/prenex/install/kexec-tools/build/sbin/plopkexec.img

--- End code ---

Of course always followed by a ./kexec -e command. The kexec-tools I have compiled on my own but haven't installed it system-wide yet so that is why I am using "./" everywhere so far. The files I have downloaded from your page but I haven't compiled them as I have very latest gcc in arch and I read sometimes it cause problem and I can be happy with prebuilt ones if I they work. If this is the problem of course I will compile plopkexec too ;-)

prenex:
Also I was finally able to run plopkexec from my grub menu, but it does not find any linuxes :-(

I can plug in an SD card, an USB stick with linux and of course have my arch32 on the same hdd where plopkexec is in the boot folder, but it is not finding any of these... I am not sure about what is going on. I see from the logs that it sees mmblk01 and stuff like that. Also rarely (1-2 times as far as I was trying) I got a kernel panic when I removed the usb stick while plopkexec is running. Once it paniced without me touching it, but otherwise only when I plugged out something.

I was trying with the version prebuilt on your page. I will try building my own if it is not taking too long. Should I send you some logs? Can I save the logs somewhere or I need to photo them? :-)

Elmar:
Hello,

as you already figured out,

--- Code: ---sudo ./kexec -l ./plopkexec
sudo ./kexec -e

--- End code ---

should work. initrd is not required. Are there any messages after "kexec -e"?

You should also try a systemwide installation.




--- Quote from: prenex on May 18, 2019, 22:48:50 PM ---Also I was finally able to run plopkexec from my grub menu, but it does not find any linuxes :-(

I can plug in an SD card, an USB stick with linux and of course have my arch32 on...

--- End quote ---

The easiest would be to create a custom plopkexec.cfg with your kernel settings.

Best regards
Elmar

Navigation

[0] Message Index

[#] Next page

Go to full version