trying to setup grub2 for Porteus Mate

Get help with MATE specific problems
gotPortee
Black ninja
Black ninja
Posts: 43
Joined: 14 Oct 2014, 01:49
Distribution: Porteus-MATE
Location: U.S.

trying to setup grub2 for Porteus Mate

Post#16 by gotPortee » 27 Mar 2019, 17:02

I've been trying different solutions such as adding EXIT

changes=EXIT:UUID:5b0b2620-6c98-43a9-b0aa-ad18b60c1df0/porteus/porteussaved.dat

But this isn't working either

Where is the RO cheatcode located?
I assume this means "R"ead "O"only?

neko
DEV Team
DEV Team
Posts: 2109
Joined: 09 Feb 2013, 09:55
Distribution: APorteus-FVWM-ja-x86_64.iso
Location: japan

trying to setup grub2 for Porteus Mate

Post#17 by neko » 27 Mar 2019, 17:26

@gotPortee

Long time ago , I have made a "changes data" as follow.

Code: Select all

% su
# dd of=porteussaved.dat count=0 seek=2691616
# mkfs.ext2 porteussaved.dat

Thanks.

User avatar
Ed_P
Contributor
Contributor
Posts: 8343
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

trying to setup grub2 for Porteus Mate

Post#18 by Ed_P » 27 Mar 2019, 17:42

gotPortee wrote:
27 Mar 2019, 17:02
Where is the RO cheatcode located?
I assume this means "R"ead "O"only?
gotPortee wrote:
27 Mar 2019, 00:06
linux /boot/syslinux/vmlinuz root=UUID=5b0b2620-6c98-43a9-b0aa-ad18b60c1df0 ro recovery nomodeset
After the "cidfo" and before the "recovery".

You might want to review the Porteus /boot/docs/cheatcodes.txt file at some point. Find out what root, recovery, nomodeset, changes and ro mean. :happy62:
Ed

gotPortee
Black ninja
Black ninja
Posts: 43
Joined: 14 Oct 2014, 01:49
Distribution: Porteus-MATE
Location: U.S.

trying to setup grub2 for Porteus Mate

Post#19 by gotPortee » 27 Mar 2019, 18:01

I removed the text "ro recovery nomodeset"

And it didn't make a difference

And I don't understand what neko is doing - is that code to create the dat file?

neko
DEV Team
DEV Team
Posts: 2109
Joined: 09 Feb 2013, 09:55
Distribution: APorteus-FVWM-ja-x86_64.iso
Location: japan

trying to setup grub2 for Porteus Mate

Post#20 by neko » 27 Mar 2019, 18:27

@gotPortee
"is that code to create the dat file?"
--->
Yes, it is the example of making "Changes Data".

"changes" has 2 types.
One is a directory.
Another is a file.

The file is the image that contains a valid filesystem, Porteus will mount it on a loop.

Thanks.

User avatar
Ed_P
Contributor
Contributor
Posts: 8343
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

trying to setup grub2 for Porteus Mate

Post#21 by Ed_P » 27 Mar 2019, 18:34

Try removing the root= part too. Just leave your changes= code. Be sure you have a /porteus folder on the Porteus drive.

And once we get this working for you try this menu.

Code: Select all

menuentry 'Porteus TEST' { 
# recordfail
# savedefault
# load_video
# gfxmode $linux_gfx_mode
# insmod gzio
# if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
# insmod part_msdos
# insmod ext2
set root=(hd0,msdos6)
linux /boot/syslinux/vmlinuz root=UUID:5b0b2620-6c98-43a9-b0aa-ad18b60c1df0 changes=UUID:5b0b2620-6c98-43a9-b0aa-ad18b60c1df0/porteus
initrd /boot/syslinux/initrd.xz
 }
And yes the code neko showed is for creating a save.dat file but you've already created one and on a EXT4 drive you don't need one.
Ed

gotPortee
Black ninja
Black ninja
Posts: 43
Joined: 14 Oct 2014, 01:49
Distribution: Porteus-MATE
Location: U.S.

trying to setup grub2 for Porteus Mate

Post#22 by gotPortee » 27 Mar 2019, 21:11

Thank you Ed - for sticking with me!
It is now saving changes.
I realized also that I had the /Porteus - with uppercase P and this was wrong.
The system couldn't find this folder at boot up.

I did use your latest menu code and it is working now!
Big huge thanks!!

User avatar
Rava
Contributor
Contributor
Posts: 5401
Joined: 11 Jan 2011, 02:46
Distribution: XFCE 5.01 x86_64 + 4.0 i586
Location: Forests of Germany

trying to setup grub2 for Porteus Mate

Post#23 by Rava » 27 Mar 2019, 21:50

Ed_P wrote:
26 Mar 2019, 05:38
Well, if you have only one /32bit_v30/boot/syslinux/vmlinuz file on your system you could replace your set root with:

search -f /32bit_v30/boot/syslinux/vmlinuz --set=root
But... that would mean the boot process would look in all partitions for /32bit_v30/boot/syslinux/vmlinuz, and not only on hd0,5? Slowing down the boot process?

Just for comparison, this is what one entry for the menu.lst for GRUB2DOS looks like, I had to use this one since I did pay for the sad excuse for an OS, SM-WItless7, so I wanted to keep it, and install all my Linux stuff parallel.

Code: Select all

title Porteus 4.0 x86-64 XFCe
rootnoverify (hd0,0)
kernel (hd0,0)/Boot/vmlinuz_Porteus_4.0_x86_64 from=/mnt/sda1/Porteus_4.0/ ramsize=40% zram=25% timezone=Europe/Berlin volume=75% kmap=de 3
initrd (hd0,0)/Boot/initrd.xz_Porteus_4.0_x86_64
boot
Be aware that my setup chooses the German keymap, and it boots into text mode. Both things that many people would not want to have.

Also, I put all the kernel and initrd into the /Boot/ folder of the hidden Witless boot and recovery partition (hd0,0), and I do rename the kernel and initrd accordingly, since otherwise I could not have several different Linux and especially several different Porteus variants in the same folder.

Like I said, just meant as one example for a grub installation that does work. :)
Cheers!
Yours Rava

User avatar
Ed_P
Contributor
Contributor
Posts: 8343
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

trying to setup grub2 for Porteus Mate

Post#24 by Ed_P » 27 Mar 2019, 22:14

Rava wrote:
27 Mar 2019, 21:50
But... that would mean the boot process would look in all partitions for /32bit_v30/boot/syslinux/vmlinuz, and not only on hd0,5? Slowing down the boot process?
True but computers are pretty fast so only a second or 2. The savings are when the hard drive is replaced or the existing one's partitions moved around, Mate will still boot with no changes necessary.
Just for comparison, this is what one entry for the menu.lst for GRUB2DOS
GRUB2DOS!! hmmm :no: It looks like the menu from an old Grub4DOS system. It was my main bootloader till I got an EFI machine then I had to switch.

Code: Select all

title Porteus 4.0 x86-64 XFCe
rootnoverify (hd0,0)
kernel (hd0,0)/Boot/vmlinuz_Porteus_4.0_x86_64 from=/mnt/sda1/Porteus_4.0/ ramsize=40% zram=25% timezone=Europe/Berlin volume=75% kmap=de 3
initrd (hd0,0)/Boot/initrd.xz_Porteus_4.0_x86_64
boot
Interesting code vmlinuz_Porteus and initrd.xz_Porteus. I don't recall connecting the names. Oh, wait, you renamed the files didn't you. :o
I do rename the kernel and initrd accordingly,
Yup, I knew it.

You do realize that gotPortee is using Grub2 right, which has differ commands than Grub4DOS?

So gotPortee you said you got your system to boot. :Bravo: :Yahoo!: Have you tried the test menu I showed you?
Ed

User avatar
Rava
Contributor
Contributor
Posts: 5401
Joined: 11 Jan 2011, 02:46
Distribution: XFCE 5.01 x86_64 + 4.0 i586
Location: Forests of Germany

trying to setup grub2 for Porteus Mate

Post#25 by Rava » 27 Mar 2019, 22:33

Ed_P wrote:
27 Mar 2019, 22:14
GRUB2DOS!! hmmm :no: It looks like the menu from an old Grub4DOS system. It was my main bootloader till I got an EFI machine then I had to switch.
Indeed, my bad. It is Grub4DOS not GRUB2DOS.
Ed_P wrote:
27 Mar 2019, 22:14
You do realize that gotPortee is using Grub2 right, which has differ commands than Grub4DOS?
I do, and my quote is not about copying the commands verbatim, but as info for file, partition and folder structure.
Cheers!
Yours Rava

gotPortee
Black ninja
Black ninja
Posts: 43
Joined: 14 Oct 2014, 01:49
Distribution: Porteus-MATE
Location: U.S.

trying to setup grub2 for Porteus Mate

Post#26 by gotPortee » 28 Mar 2019, 04:32

Ed
So gotPortee you said you got your system to boot. :Bravo: :Yahoo!: Have you tried the test menu I showed you?

Yes I'm using it as we speak - sorry I thought I mentioned that before.
I'll eventually transpose it into Grub2's 40_custom file.
I was editing the grub.cfg file as that was easier for testing purposes.

User avatar
Ed_P
Contributor
Contributor
Posts: 8343
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

trying to setup grub2 for Porteus Mate

Post#27 by Ed_P » 28 Mar 2019, 05:36

gotPortee post the grub2 menu that is working for you so others may see it and use it for their systems. :happy62:
Ed

User avatar
Ed_P
Contributor
Contributor
Posts: 8343
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

trying to setup grub2 for Porteus Mate

Post#28 by Ed_P » 30 Mar 2019, 15:34

Rava wrote:
27 Mar 2019, 22:33
I do, and my quote is not about copying the commands verbatim, but as info for file, partition and folder structure.
For more info here is one of my Grub4DOS menus.

Code: Select all

set ISO30=Porteus-RazorQT-v3.0.1-x86_64-nu.iso

# menu entries

title Porteus 3.0.1 changes=EXIT  \n213MB\n %ISO30% 
find --set-root                       /ISOs/%ISO30%
map --heads=0 --sectors-per-track=0   /ISOs/%ISO30% (0xff) 
map --hook
root (0xff)
kernel /boot/syslinux/vmlinuz    from=/ISOs/%ISO30% changes=EXIT:/porteus3.0/changes/porteussave.dat extramod=/porteus3.0/Modules volume=40 reboot=cold ramsize=80%
#initrd (hd0,4)/porteus3.0/testing/initrdx.xz
initrd /boot/syslinux/initrd.xz
:)
Ed

gotPortee
Black ninja
Black ninja
Posts: 43
Joined: 14 Oct 2014, 01:49
Distribution: Porteus-MATE
Location: U.S.

trying to setup grub2 for Porteus Mate

Post#29 by gotPortee » 30 Mar 2019, 22:23

Here is the final product written to etc/grub.d/40_custom
Notes follow below

menuentry 'Porteus Linux' {
recordfail
savedefault
load_video
gfxmode $linux_gfx_mode
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_msdos
insmod ext2
set root='hd0,msdos6'
linux /boot/syslinux/vmlinuz root=UUID=5b0b2620-6c98-43a9-b0aa-ad18b60c1df0 changes=UUID:5b0b2620-6c98-43a9-b0aa-ad18b60c1df0/porteus
initrd /boot/syslinux/initrd.x
}

Porteus kernel is: 3.14.15
The laptop being setup is for a friend
HP Pavilion DV6700 - 32-bit unit.
HD is split into 3 partitions, Ubuntu Mate, Porteus Mate, Linux Lite
I booted the unit up with a PartedMagic bootuable USB to gain quick access and edit /boot/grub/grub.cfg
Yes I know one is not supposed to edit this file - but it made for a more efficient validation process.

The partition UUIDs were acquired from PartedMagic also.
Once the bootup is successful - I moved the script over to /etc/grub.d/40_custom
And then performed the grub-update
And confirmed that the Porteus script was correctly loaded into the updated grub.cfg file.

Thanks to Ed - big time - for helping me work through this!
Porteus is totally awesome!!

User avatar
Ed_P
Contributor
Contributor
Posts: 8343
Joined: 06 Feb 2013, 22:12
Distribution: Cinnamon 5.01 ISO
Location: Western NY, USA

trying to setup grub2 for Porteus Mate

Post#30 by Ed_P » 31 Mar 2019, 01:01

Hi gotPortee. I don't think you need these lines.

Code: Select all

recordfail
savedefault
load_video
gfxmode $linux_gfx_mode
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
insmod part_msdos
insmod ext2
but I suspect you don't have the HP any more so we will never know for sure.
Ed

Post Reply