Dual boot, LILO, GRUB2, SYSLINUX

Post here if you are a new Porteus member and you're looking for some help.
mt12345
Black ninja
Black ninja
Posts: 66
Joined: 29 Jun 2014, 23:36
Distribution: Porteus RazorQT 32bit
Location: Europe

Dual boot, LILO, GRUB2, SYSLINUX

Post#1 by mt12345 » 15 Jul 2014, 00:28

machine was running debian with grub2 as boot loader then I installed porteus on spare partition.
how to update lilo (or syslinux or whatever is responsible for booting now) to add debian entry?
I understand I need to add some lines somewhere with image, initrd and location (sda1).

User avatar
fanthom
Site Admin
Site Admin
Posts: 4547
Joined: 28 Dec 2010, 02:42
Distribution: Porteus Kiosk
Location: Poland, currently - Cork, IE
Contact:

Re: Dual boot, LILO, GRUB2, SYSLINUX

Post#2 by fanthom » 15 Jul 2014, 06:57

if you had a bootloader already - what was the point of running Porteus installer?
you could add Porteus to your Grub2 instead ....

anyway - please show us your Grub2 config.
Please add [Solved] to your thread title if the solution was found.

mt12345
Black ninja
Black ninja
Posts: 66
Joined: 29 Jun 2014, 23:36
Distribution: Porteus RazorQT 32bit
Location: Europe

Re: Dual boot, LILO, GRUB2, SYSLINUX

Post#3 by mt12345 » 15 Jul 2014, 10:28

fanthom wrote:if you had a bootloader already - what was the point of running Porteus installer?
you could add Porteus to your Grub2 instead ....
I didn't think I would need to boot to debian anymore...
I just kept the partitions to save data.

I want to boot it again to compare software versions and behaviour or even convert some debs.

edit:

I could use supergrub cd or something but I want to learn how to dual boot porteus.

edit2:

documentation covers windows-porteus dual boot scenario only
Last edited by mt12345 on 15 Jul 2014, 10:40, edited 2 times in total.

mt12345
Black ninja
Black ninja
Posts: 66
Joined: 29 Jun 2014, 23:36
Distribution: Porteus RazorQT 32bit
Location: Europe

Re: Dual boot, LILO, GRUB2, SYSLINUX

Post#4 by mt12345 » 15 Jul 2014, 10:29

### BEGIN /etc/grub.d/10_linux ###
function gfxmode {
set gfxpayload="${1}"
}
set linux_gfx_mode=1024x768
export linux_gfx_mode
menuentry 'siduction 2013.2.0 paintitblack (lxqt) GNU/Linux' --class siduction --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-bead1e15-7d87-4a3a-840f-120f596ff64f' {
load_video
gfxmode $linux_gfx_mode
insmod gzio
insmod part_msdos
insmod ext2
set root='hd0,msdos1'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos1 --hint-efi=hd0,msdos1 --hint-baremetal=ahci0,msdos1 --hint='hd0,msdos1' bead1e15-7d87-4a3a-840f-120f596ff64f
else
search --no-floppy --fs-uuid --set=root bead1e15-7d87-4a3a-840f-120f596ff64f
fi
echo 'Loading Linux 3.15-5.towo-siduction-amd64 ...'
linux /boot/vmlinuz-3.15-5.towo-siduction-amd64 root=UUID=bead1e15-7d87-4a3a-840f-120f596ff64f ro quiet
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-3.15-5.towo-siduction-amd64
}
Last edited by mt12345 on 15 Jul 2014, 21:11, edited 1 time in total.

User avatar
francois
Contributor
Contributor
Posts: 4902
Joined: 28 Dec 2010, 14:25
Distribution: kde xfce porteus manjaro kubun
Location: Enfin l'été, le changement climatique attendu: le soleil.

Re: Dual boot, LILO, GRUB2, SYSLINUX

Post#5 by francois » 15 Jul 2014, 10:41

Personnally to work with porteus my preference is really to boot with grub legacy. Post on easily reinstalling porteus with grub legacy:
viewtopic.php?f=62&t=946

Some information on grub2 and porteus:
https://forum.porteus.org/viewtopic.php?f=48&t=1790

Repairing or reinstalling grub2:
http://www.howtogeek.com/114884/how-to- ... wont-boot/
https://help.ubuntu.com/community/Grub2 ... 20GRUB%202
Voltaire: Le mieux est l'ennemi du bien.

mt12345
Black ninja
Black ninja
Posts: 66
Joined: 29 Jun 2014, 23:36
Distribution: Porteus RazorQT 32bit
Location: Europe

Re: Dual boot, LILO, GRUB2, SYSLINUX

Post#6 by mt12345 » 15 Jul 2014, 13:10

I know how to repair grub but I thought it would be easier to edit porteus.cfg or lilo.conf instead of booting *buntu.
grub legacy thread - bookmarked, I will investigate later.
thanks for help.

User avatar
francois
Contributor
Contributor
Posts: 4902
Joined: 28 Dec 2010, 14:25
Distribution: kde xfce porteus manjaro kubun
Location: Enfin l'été, le changement climatique attendu: le soleil.

Re: Dual boot, LILO, GRUB2, SYSLINUX

Post#7 by francois » 15 Jul 2014, 17:13

Syslinux is quite similar to grub legacy with some small differences in syntax. 8)

Here are some grub legacy entries for debian type systems, crunchbang, ubuntu:
http://crunchbang.org/forums/viewtopic.php?id=15748
http://ubuntuforums.org/archive/index.p ... 94900.html

An example crunchbang adapted to syslinux menu entry:

Code: Select all

LABEL xfce CRUNCHBANG
MENU LABEL Graphics mode (XFCE)
KERNEL /boot/vmlinuz-3.7-1.towo-siduction-amd64
APPEND initrd=/boot/initrd.img-3.7-1.towo-siduction-amd64 root=/dev/sda6 ro noacpi quiet splash
TEXT HELP
Run Porteus the best way we can.
Try to autoconfigure graphics
card and use the maximum
allowed resolution
ENDTEXT
Last edited by francois on 15 Jul 2014, 21:18, edited 1 time in total.
Voltaire: Le mieux est l'ennemi du bien.

mt12345
Black ninja
Black ninja
Posts: 66
Joined: 29 Jun 2014, 23:36
Distribution: Porteus RazorQT 32bit
Location: Europe

Re: Dual boot, LILO, GRUB2, SYSLINUX

Post#8 by mt12345 » 15 Jul 2014, 20:53

looks like syslinux is looking for debian kernel in porteus partition (sda4)
I copied debian's files to porteus to get it booting.

# mkdir /mnt/sda4/boot/syslinux/debian
# cp /mnt/sda1/boot/* /mnt/sda4/boot/syslinux/debian/

Code: Select all

LABEL rqt SIDUCTION
MENU LABEL Debian
KERNEL debian/vmlinuz-3.15-5.towo-siduction-amd64
APPEND initrd=debian/initrd.img-3.15-5.towo-siduction-amd64 root=/dev/sda1 ro

User avatar
francois
Contributor
Contributor
Posts: 4902
Joined: 28 Dec 2010, 14:25
Distribution: kde xfce porteus manjaro kubun
Location: Enfin l'été, le changement climatique attendu: le soleil.

Re: Dual boot, LILO, GRUB2, SYSLINUX

Post#9 by francois » 15 Jul 2014, 21:23

Do we have a solution?

What about changing to root=/dev/sda4 as in:

Code: Select all

LABEL rqt SIDUCTION
MENU LABEL Debian
KERNEL debian/vmlinuz-3.15-5.towo-siduction-amd64
APPEND initrd=debian/initrd.img-3.15-5.towo-siduction-amd64 root=/dev/sda4 ro
Last edited by francois on 16 Jul 2014, 03:02, edited 1 time in total.
Voltaire: Le mieux est l'ennemi du bien.

mt12345
Black ninja
Black ninja
Posts: 66
Joined: 29 Jun 2014, 23:36
Distribution: Porteus RazorQT 32bit
Location: Europe

Re: Dual boot, LILO, GRUB2, SYSLINUX [SOLVED]

Post#10 by mt12345 » 16 Jul 2014, 00:36

It works with root=/dev/sda1 (sda4 = porteus)

Anyway debian doesnt boot to desktop, it hangs right after mounting sda2 (/home) that's probably because I shrank the partition.
Nevermind.
I have just replaced debian with salix and changed entry in porteus.cfg:

Code: Select all

LABEL salix
MENU LABEL Salix
KERNEL vmlinuz-huge-3.10.17
APPEND root=/dev/sda1 ro
(again I had to copy kernel to porteus partition - sda4/boot/syslinux)
The problem is solved (till next kernel upgrade on salix side).
Thanx!

User avatar
francois
Contributor
Contributor
Posts: 4902
Joined: 28 Dec 2010, 14:25
Distribution: kde xfce porteus manjaro kubun
Location: Enfin l'été, le changement climatique attendu: le soleil.

Re: Dual boot, LILO, GRUB2, SYSLINUX

Post#11 by francois » 16 Jul 2014, 03:02

Thus salix is on sda1, isn't it?
Voltaire: Le mieux est l'ennemi du bien.

mt12345
Black ninja
Black ninja
Posts: 66
Joined: 29 Jun 2014, 23:36
Distribution: Porteus RazorQT 32bit
Location: Europe

Re: Dual boot, LILO, GRUB2, SYSLINUX

Post#12 by mt12345 » 16 Jul 2014, 03:13

yes

User avatar
fanthom
Site Admin
Site Admin
Posts: 4547
Joined: 28 Dec 2010, 02:42
Distribution: Porteus Kiosk
Location: Poland, currently - Cork, IE
Contact:

Re: Dual boot, LILO, GRUB2, SYSLINUX

Post#13 by fanthom » 16 Jul 2014, 06:08

(again I had to copy kernel to porteus partition - sda4/boot/syslinux)
yes - seems that syslinux wont allow you to load kernel from other partition (unlike grub) but you could install syslinux in salix as well, set the timeout to 0 and chainload to /dev/sda1 as per this thread:
link

on the other hand i remember someone posting a solution to similar problem on our forum and he was using syslinux only - cant find it right now...
Please add [Solved] to your thread title if the solution was found.

mt12345
Black ninja
Black ninja
Posts: 66
Joined: 29 Jun 2014, 23:36
Distribution: Porteus RazorQT 32bit
Location: Europe

Re: Dual boot, LILO, GRUB2, SYSLINUX

Post#14 by mt12345 » 16 Jul 2014, 09:57

t you could install syslinux in salix
nah I want to keep it the way it is.
portreus is my main OS , salix is installed on 'testing' partition it may be replaced soon by opensuse fedora anything

User avatar
francois
Contributor
Contributor
Posts: 4902
Joined: 28 Dec 2010, 14:25
Distribution: kde xfce porteus manjaro kubun
Location: Enfin l'été, le changement climatique attendu: le soleil.

Re: Dual boot, LILO, GRUB2, SYSLINUX

Post#15 by francois » 17 Jul 2014, 19:44

You need to use extlinux, according to this archlinux thread:
https://wiki.archlinux.org/index.php/Sy ... ux_systems

I will try that.
Voltaire: Le mieux est l'ennemi du bien.

Post Reply