Page 1 of 1

bootloader again /porteus 3.0

Posted: 30 Jul 2014, 12:04
by baszek
Hello - I have installed lubuntu and there was no option to boot porteus (it is newest 3.0).
So I added this in /etc/grub.d/40_custom

Code: Select all

#!/bin/sh
exec tail -n +3 $0
menuentry "porteus" {
set root=(hd0,6)  #it is installed on 6th partition - sda6 ext4
linux /boot/syslinux/vmlinuz 
initrd /boot/syslinux/initrd.xz
}
after grub-update I have entry porteus, but it is not booting anyway. What did I do wrong ? Menuentry looks fine.

Re: bootloader again /porteus 3.0

Posted: 30 Jul 2014, 14:27
by brokenman
hd0,0 = sda1
hd0,1 = sda2

therefore hd0,5 = sda6

Re: bootloader again /porteus 3.0

Posted: 30 Jul 2014, 14:35
by baszek
Changed to hd0,5 but it is not working also.

Re: bootloader again /porteus 3.0

Posted: 30 Jul 2014, 14:38
by fanthom
please show me a full path to the *.sgn file in your /porteus directory.

thanks

Re: bootloader again /porteus 3.0

Posted: 30 Jul 2014, 16:04
by brokenman
Francois has a nice write up of setting up grub here: http://forum.porteus.org/viewtopic.php?f=48&t=1790

Re: bootloader again /porteus 3.0

Posted: 30 Jul 2014, 21:37
by francois
Please give us the output of:

Code: Select all

cd /mnt/sda6/boot
ls > output_of_boot_dir.txt
and simultaneously have a try on adding the from cheatcode, replace:

Code: Select all

linux /boot/syslinux/vmlinuz
by

Code: Select all

linux /boot/syslinux/vmlinuz from=/dev/sda6
then from lubuntu:

Code: Select all

update-grub

Re: bootloader again /porteus 3.0

Posted: 31 Jul 2014, 22:13
by baszek
My sda6 partition is mounted in:

Code: Select all

/media/agent007/eb6f610f-e98e-cf01-0069-610fe98ecf01
output of ls > output_of_boot_dir.txt from sda6 is:

Code: Select all

boot
lost+found
porteus
and from sda6/boot:

Code: Select all

docs
Porteus-installer-for-Linux.com
Porteus-installer-for-Windows.exe
syslinux
My /etc/grub.d/40_custom file looks like this now:

Code: Select all

#!/bin/sh
exec tail -n +3 $0
menuentry "porteus" {
set root=(hd0, 5)
linux /boot/syslinux/vmlinuz from=/dev/sda6
initrd /boot/syslinux/initrd.xz
}
# This file provides an easy way to add custom menu entries.  Simply type the
# menu entries you want to add after this comment.  Be careful not to change
# the 'exec tail' line above.
P.S still not working

Re: bootloader again /porteus 3.0

Posted: 31 Jul 2014, 22:50
by beny
a question you have vmlinuz and initrd inside syslinux folder? sorry i have open an iso and i have the answer,but if you can do a fdisk -l in console maybe you have a picture of your partitions and a standalone system is ok for the boot loader but two disk with boot flag,you have a lot of problems

Re: bootloader again /porteus 3.0

Posted: 31 Jul 2014, 23:05
by baszek
beny wrote:a question you have vmlinuz and initrd inside syslinux folder?
yes, I have.
and this is fdisk -l output:

Code: Select all

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1              63    35162172    17581055    7  HPFS/NTFS/exFAT
/dev/sda2        35164158    78139391    21487617    5  Extended
/dev/sda5        35164160    68091894    16463867+  83  Linux
/dev/sda6   *    68093952    76292095     4099072    b  W95 FAT32
/dev/sda7        76294144    78139391      922624   82  Linux swap / Solaris

Re: bootloader again /porteus 3.0

Posted: 31 Jul 2014, 23:40
by beny
so the boot is on fat32 partition? i think fanthom have the answer for this,my usb keys boot with lilo ad a slackware with extlinux on hd
set root=(hd0, 5) it is correct or you have a space more from 0 to 5

Re: bootloader again /porteus 3.0

Posted: 01 Aug 2014, 15:40
by Ed_P
baszek your sda5 is a Logical partition rather than a Primary. That could be the problem. Logicals are usually non-bootable.

Re: bootloader again /porteus 3.0

Posted: 02 Aug 2014, 15:11
by router
disagree, my pclinux and my porteus are quite happily booting from logicals

root@porteus:/home/guest# fdisk -l

Disk /dev/sda: 60.0 GB, 60011642880 bytes
255 heads, 63 sectors/track, 7296 cylinders, total 117210240 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x17e917e9

Device Boot Start End Blocks Id System
/dev/sda1 2048 81922047 40960000 7 HPFS/NTFS/exFAT
/dev/sda2 81931500 117210239 17639370 5 Extended
/dev/sda5 81931563 100309859 9189148+ 83 Linux
/dev/sda6 100309923 102350114 1020096 82 Linux swap
/dev/sda7 * 102350178 117210239 7430031 83 Linux

i'm not that knowledgeable on grub and grub2 but either one of them if it can see the partition contents, and therefore the boot images in it, it can boot it

i'm too tired and spacey right now but when my mind is more clear i can look at this and maybe have an answer, if one hasn't been already found

Re: bootloader again /porteus 3.0

Posted: 02 Aug 2014, 20:09
by Ed_P
router wrote:i'm not that knowledgeable on grub and grub2 but either one of them if it can see the partition contents, and therefore the boot images in it, it can boot it
Me either but I agree.

Try (hd0,3) instead of (hd0,5) baszek. And if that doesn't work in grub go to command mode and enter:
root (hd0, plus the Tab key. This will list the drive's partitions as grub sees them. And while in command mode try:
find /boot/syslinux/vmlinuz

Re: bootloader again /porteus 3.0

Posted: 02 Aug 2014, 21:06
by tome
@brokenman
hd0,0 = sda1
hd0,1 = sda2

therefore hd0,5 = sda6
- wrong, it is valid for grub4dos and probably for grub legacy

@baszek
Edit manually (be careful) your grub.cfg file (/etc/boot/grub or similar path) and replace your code with my:

Code: Select all

#exec tail -n +3 $0
menuentry "porteus" {
search --no-floppy --file --set=root /boot/syslinux/vmlinuz
#or eventually use path to your .sgn file inside porteus directory
linux /boot/syslinux/vmlinuz
#add from=... cheatcode if needed
initrd /boot/syslinux/initrd.xz
}

Re: bootloader again /porteus 3.0

Posted: 02 Aug 2014, 21:44
by Ed_P

Code: Select all

--set=root /boot/syslinux/vmlinuz
set =root is an excellent idea tome. I didn't know grub had that. (Grub4DOS does.) But doesn't it conflict with the :lol: from=/dev/sda6 option that you just deleted.

We cross posted. :)