Jump to content











Photo
- - - - -

Dual boot Help Please XP & Q4OS? (Solved by Wonko the Sane)


  • Please log in to reply
38 replies to this topic

#1 ispy

ispy

    Silver Member

  • Tutorial Writer
  • 646 posts
  • Location:PILGRIM

Posted 22 September 2019 - 11:59 AM

To whom can help please :D ?

 

Not sure if this is the right forum to post this message but it is in connection with XP & Grub4Dos
 
I currently am using a HP Elite 8300 SFF PC with 4Gb of Ram & i7 processor. The PC has two SATA3 Hdds fitted, one is installed with XPPRO (x86) 32Bit fitted to a partition /dev/sda1 = 17.57Gb file system Ntfs. The remaining partition /dev/sda2 = 195gb  also with the ntfs file system that is used for programs documents & backed up programs etc. The second separate drive is currently installed with a ntfs filesystem of a similair size to the first drive without partitions. The PC is capable of UEFI boot but I have it set t

#2 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 22 September 2019 - 01:10 PM

Ok, you got almost completely "wrong" information :w00t: :ph34r:, of course not your fault, but there is so much wrong info dispensed by completely clueless people that is much more probable to find that info instead of the right one.
 
First let us solve the issue the "right" way, and only later (i.e. once the issue has been properly solved) we'll talk of the incorrect info you got. :)
 
FORGET anything you have read till now "here and there".
 
 
DO NOT rename ANYTHING.
 
Restore the "normal" booting chain of XP.
 
This means that the BIOS boot disk should be the one with XP, it should contain a "normal" MBR booting the partition marked active bootsector that will load NTLDR, and NTLDR will access BOOT.INI (i.e. the "normal" configuration file for NTLDR).
 
Then get this grub4dos from Chenall site:
http://grub4dos.chen....6a-2019-07-16/
 
For your use *any* version would do, including the "old" 0.4.5c : http://grub4dos.chen....5c-2016-01-18/
but the 0.4.6a one above is "recent enough" while not being latest-latest, so  it is afvised to use that one.
 
From the downloaded .7z extract ONLY the example menu.lst and grldr placing them in the same volume where NTLDR, NTDETECT:COM and BOOT.INI.
Add a line in BOOT.INI *like*:
C:\grldr="grub4dos"
under [operating systems], see also:
http://reboot.pro/to...sults/?p=184060
 
And you should already know all of this:
http://reboot.pro/to...-with-grub4dos/
 
Anyway, open your GRUB2 configuration file, usually grub.cfg, find the entry that actually boots your Q4OS x86 and post it, and I will help you "translate" it to a grub4dos menu.lst entry (that is if you want to bypass GRUB2) otherwise chainload the GRUB2 from grub4dos, which normally amounts to:
title grub2
find --set-root /boot/grub/core.img
kernel /boot/grub/core.img
See also:
http://reboot.pro/to...th-hard-drives/

:duff:
Wonko

#3 ispy

ispy

    Silver Member

  • Tutorial Writer
  • 646 posts
  • Location:PILGRIM

Posted 22 September 2019 - 04:04 PM

Hi Wonko the Sane  <_<

 

Firstly Many Thanks for responding to my post

 

FORGET anything you have read till now "here and there".

 

 

Really when you have the I.Q. of a gold fish that is not hard to do LOL

 

DO NOT rename ANYTHING.

 

 

Nope Not renamed anything yet but I have scrubbed the Q4OS HDD so I will need to reformat to the Ext4 File system & reinstall Q4OS. If however I do this it will take some time to re-setup as i do not yet have a working copy of the .cfg Grub2 file.

 

Then get this grub4dos from Chenall site:
http://grub4dos.chen....6a-2019-07-16/

 

 

Yep got it & extracted the files to C:\ (Grldr & Menu.lst)

 

C:\grldr="grub4dos"

 

Entered this line of script into boot.ini & saved (Made a backup of boot.ini just in case I stuff-up)

 

under [operating systems], see also:
http://reboot.pro/to...sults/?p=184060

 

 I will humbly take a raincheck on this I will need to reinstall Q4OS shortly to the second Hdd to obtain a .cfg file for amendmant if that route is taken?

 

And you should already know all of this:

http://reboot.pro/to...-with-grub4dos/

 

 

Your NOT wrong there but Me Lud it was 3 year ago & your expecting WAAAaaaay to much from a gold fish mentality but point taken respectfully.

 

Anyway, open your GRUB2 configuration file, usually grub.cfg, find the entry that actually boots your Q4OS x86 and post it, and I will help you "translate" it to a grub4dos menu.lst entry (that is if you want to bypass GRUB2) otherwise chainload the GRUB2 from grub4dos, which normally amounts to:

title grub2
find
--set-root /boot/grub/core.img
kernel
/boot/grub/core.img

 

 

I'm going to bow to your experience here & ask in your opinion what would you do if it was you? I'm all for taking the path of least resistance and not amending the Grub2 file as it looks darn complicated but that option may have residual consequences that I am un-aware of.

 

See also:
http://reboot.pro/to...th-hard-drives/

 

As a preference I don't really want to mess around with the Mbr unless necessary my moto is K.i.S.S where ever possible  but also I don't remember on the previous occaision being asked by the Q4OS installer if I wanted the Grub2 loader to amend the MBR??

 

Is it okay to reinstall Q4OS on the second Hdd (I will unplug the XPPro Drive to keep things separated seeing as I have setup the Grldr Menu.lst & edited Boot.ini? I will need to post the .cfg file from Q4OS system if it is needed?

 

I will await your answer in antiscipation

 

Best Regards & Thanks!,

 

David

 



#4 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 22 September 2019 - 05:19 PM

Sure, that will be fine, if you remove the "XP hard disk" wherever the GRUB2 will be installed it will surely NOT be on first hard disk.

The grub.cfg is only needed if you want to by-pass completely the GRUB2 and you cannot find/compose yourself the correct grub4dos menu.lst entry for the distro, and - possibly - if for any reason chainloading from grub4dos either the MBR or PBR or GRUB2 on the second disk doesn't work when you re-connect the first one.

The general idea is to "tag" one (and one only) Boot Manager as MAIN one and choose the simpler, more direct path.

You have three possibilities:
1) tag NTLDR as "main" <- this can boot either XP or chainload grub4dos BUT NOT chainload GRUB2 nor any Linux distro directly
2) tag grub4dos as "main" <- this can boot either XP (chainloading NTLDR) or GRUB2 or *anything*, including a Linux distro, directly
3) tag GRUB2 as "main" <- this can boot either XP (also chainloading NTLDR but it will need several modules) or grub4dos or (almost) *anything*

The easiest is to keep everything "as is", i.e. keeping NTLDR as the "main" one, adding to the BOOT.INI choices grub4dos and use the latter either as a "bridge" to GRUB2 or to boot directly the linux distro.

Possible boot sequences if #1:
BIOS->MBR of first disk->PBR of active partition on first disk->NTLDR->BOOT.INI->
either
XP directly
or
grub4dos chainloading *something else*

The *something else* can be:
a. the second disk MBR (if you installed the GRUB2 loader to it)
b. the PBR of the second disk volume (if you installed the GRUB2 loader to it)
c. the GRUB2
d. the actual Linux distro directly <- this is what is advised

Possible boot sequences if #2:
BIOS->MBR of first disk->grub4dos->menu.lst->
either
NTLDR->BOOT.INI->XP
or
*something else* (as above)

Possible boot sequences if #3:
BIOS->MBR of second disk (I doubt you can install GRUB2 on first disk if the volume is NTFS, but I may well be wrong :dubbio: )->GRUB2->grub.cfg->
either
(load some modules)->NTLDR->BOOT.INI->XP
or
*something else* that in this case would be directly the Linux distro

Ultimately, if you run normally XP it makes more sense to be able to boot it directly, whilst if you run normally the Linux distro it makes more sense to boot to either GRUB2 or grub4dos and from any of them boot directly the Linux distro.

:duff:
Wonko

#5 ispy

ispy

    Silver Member

  • Tutorial Writer
  • 646 posts
  • Location:PILGRIM

Posted 22 September 2019 - 11:04 PM

Hi again Wonko :D,

 

Results brought to you from post Q4OS install

I have re-installed Q4OS with the XPPro drive disconnected. The setup is as follows. Q4OS is installed on a Ext4 filesystem and Q4OS setup a swap file 8.5Gb on a 320Gb sata3 Hdd. In respect of the grub.cfg file it is quite lengthy so I will try to upload it OOp's Error You aren't permitted to upload this kind of file 

 

Better luck as a text file, see below

grub.txt format but in reality is really the .cfg file.

 

My suspicion is that Q4OS does write to the Mbr because when I plugged in the Q4OS Hdd which I previously changed the file system from ext4 to NTFS I was met with the following error message
 

error: Unknown file system

entering rescue mode...

Grub Rescue>

 

 

So I assume grub has been written to the mbr of the Q4OS hdd even though the drive was formatted ntfs just guessing?

 

The easiest is to keep everything "as is", i.e. keeping NTLDR as the "main" one, adding to the BOOT.INI choices grub4dos and use the latter either as a "bridge" to GRUB2 or to boot directly the linux distro.

 

Seems like the above is the way to proceed, so if I go back to the XPPro hdd what syntax/script within the menu.lst of grub4dos would I use to provide a menu with the option to boot into XP (as default main) possibly with a 30Sec timeout countdown & Q4OS. One thing though XPPro will not be able to read the Q4OS drive & vice-versa unless possibly from Q4OS I installed NTFS-3G read-write NTFS driver for Linux. Would this help or benefit in some way possibly, I maybe getting ahead of myself though with this suggestion?

 

I will now go back to reading some of the links you have previously so graciously provided & will await your further proceeding comments.

 

Sign off for now

 

All the best,

 

David

 

 

 

 

Attached Files

  • Attached File  grub.txt   7.15KB   235 downloads


#6 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 23 September 2019 - 08:33 AM

Good. :)
All more or less as expected.
the relevant part is this one:

 

 

menuentry 'Q4OS Desktop 3.8 '\''Centaurus'\''' --class q4os --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-5011cf2d-8555-42a3-9b80-b74427e2fe0d' {
load_video
insmod gzio
if [ x$grub_platform = xxen ]; then insmod xzio; insmod lzopio; fi
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 5011cf2d-8555-42a3-9b80-b74427e2fe0d
else
search --no-floppy --fs-uuid --set=root 5011cf2d-8555-42a3-9b80-b74427e2fe0d
fi
echo 'Loading Q4OS operating system ...'
linux /boot/vmlinuz-4.19.0-6-686-pae root=UUID=5011cf2d-8555-42a3-9b80-b74427e2fe0d ro quiet loglevel=3 systemd.log_color=0 systemd.show_status=1
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-4.19.0-6-686-pae

 

So in grub4dos add in menu.lst an entry:

 

title Q4OS Desktop 3.8 Centaurus

find --set-root --ignore-floppies --ignore-cd /boot/vmlinuz-4.19.0-6-686-pae

root

uuid ()

pause

echo 'Loading Q4OS operating system ...'
linux /boot/vmlinuz-4.19.0-6-686-pae root=UUID=5011cf2d-8555-42a3-9b80-b74427e2fe0d ro quiet loglevel=3 systemd.log_color=0 systemd.show_status=1
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-4.19.0-6-686-pae

 

and see if it boots.

 

When you choose the above menu.lst you should see the output of the root and of the uuid() commands and then pressing any key should proceed to boot the OS.

The output of the root command will be something like (this in grub4dos means first partition of second disk):

(hd1,0)

The output of the uuid() command should be:

5011cf2d-8555-42a3-9b80-b74427e2fe0d

 

If everything works, then you can remove from the menu.lst the lines in red and also the lines (copied from the grub.cfg) that begin with the echo command (those are queer, as unless booting is very slow you won't normally be able to read them :unsure:)

 

Then, add these other four :w00t: menu entries:

 

title Q4OS Desktop 3.8 Centaurus (hd1) GRUB2

rootnoverify (hd1)

chainloader +1

 

 

title Q4OS Desktop 3.8 Centaurus (hd1,0) GRUB2

root (hd1,0)

chainloader +1

 

 

title Q4OS Desktop 3.8 Centaurus core.img GRUB2

find --set-root --ignore-floppies --ignore-cd /boot/grub/core.img
kernel /boot/grub/core.img

 

title Q4OS Desktop 3.8 Centaurus core.img 386-pc GRUB2

find --set-root --ignore-floppies --ignore-cd /boot/grub/i386-pc/core.img
kernel /boot/grub/i386-pc/core.img

 

One (or more than one) of them should bring you to the GRUB2 menu/grub.cfg choices.

 

:duff:

Wonko



#7 ispy

ispy

    Silver Member

  • Tutorial Writer
  • 646 posts
  • Location:PILGRIM

Posted 23 September 2019 - 11:11 AM

Good Mornin Wonko :D,

 

Outlined is this mornings endeavors. I will explain what I have done to explain what is my probable screw up as I now have a menu from the XPPro hdd but nuthin from the Q4OS hdd. I will explain, I disconnected Q4OS booted back into XPpro hdd went to the Menu.lst file in C: copied the menu.lst file to menu2.lst as a backup then removed the text completely from the Menu.lst file. entered the text below from title to pae
 

So in grub4dos add in menu.lst an entry:

 

title Q4OS Desktop 3.8 Centaurus

find --set-root --ignore-floppies --ignore-cd /boot/vmlinuz-4.19.0-6-686-pae

root

uuid ()

pause

echo 'Loading Q4OS operating system ...'
linux /boot/vmlinuz-4.19.0-6-686-pae root=UUID=5011cf2d-8555-42a3-9b80-b74427e2fe0d ro quiet loglevel=3 systemd.log_color=0 systemd.show_status=1
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-4.19.0-6-686-pae

 

and see if it boots.

 

& saved the resultant file. Was not sure if I was to retain the text from the original Menu.lst file (But seemed like sample text) & add yours or remove the sample text & go with yours the other text deleted?

Rebooted From XPPro hdd and sure enough two menu items presented XPPro & Grub. Selected the grub item and a new menu screen was presented which stated the following

 

Use the ^ & Down keys to highlight an entry. Press Enter of "b" to boot Press "e2 to edit the commands before booting or "c" for command line press "b" to boot option was selected

 

The screen then displayed Error 15: (http://grub4dos.Chenall.net/e/15)

File not found

Press any key to continue...

 

So I selected Ctrl+Alt+Delete & tried with both drives connected of course with Q4OS being the last drive to be installed it booted to Q4OS no grub menu shown though

 

Should I have left the original menu.lst text in the menu.lst file possibly?

 

Hope this illustrates the procedure & where things could have gone wrong?

 

Best Regards,

 

David

 



#8 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 23 September 2019 - 11:55 AM

What is the difficult part in "add"?  :dubbio:.

At least here :w00t: "add" always means "add" like in "Add a line in BOOT.INI" (which you understood just fine as "add") or "add in menu.lst an entry" (which you understood as "replace" or "replace everything with").

 

So, get again the example menu.lst from the .7z archive and this time add the entries.

 

You need both drives connected AND you need to boot to the first disk (in BIOS check the boot disk order).

 

There is NO way if when you installed the Q4os the XP disk was not connected that the GRUB2 MBR was written to it, it means that in some of your experiments you changed the boot disk order to second disk and when both are connected it boots to second disk but if the second is not connected it boots to first (the XP one) since it cannot find the second.

 

:duff:

Wonko

 

 

P.S. typo (copy/paste error) - my bad - in the menu entry to add, should be:

 

title Q4OS Desktop 3.8 Centaurus
find --set-root --ignore-floppies --ignore-cd /boot/vmlinuz-4.19.0-6-686-pae
root
uuid ()
pause
echo 'Loading Q4OS operating system ...'
kernel /boot/vmlinuz-4.19.0-6-686-pae root=UUID=5011cf2d-8555-42a3-9b80-b74427e2fe0d ro quiet loglevel=3 systemd.log_color=0 systemd.show_status=1
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-4.19.0-6-686-pae



#9 ispy

ispy

    Silver Member

  • Tutorial Writer
  • 646 posts
  • Location:PILGRIM

Posted 23 September 2019 - 12:48 PM

Hi Wonko :D,

 

No worries apologies, you mean all that text is required, its not like the older grub4dos when the op entered a few lines of text & it booted. Incidentally  I didn't delete the menu.lst file just made a backup of it just in case, as it turns out lucky for me I've got the original copy. I will reinstate it & add your text to it. Get back to you shortly.

 

The reasoning for installing the 2 OS's on two separate hdd's if one drive goes down you still have the second drive, perhaps it would have been easier to setup both OS's on one drive partitioned in hein-sight.

 

Anyways onwards & upwards as they say!

 

Best Regards,

 

David



#10 ispy

ispy

    Silver Member

  • Tutorial Writer
  • 646 posts
  • Location:PILGRIM

Posted 23 September 2019 - 01:24 PM

Okay Wonko Back again  :D ,

 

Altered the Menu.lst file and saved then shut down the PC booted into setup changed the boot order so the XPPro drive boots first saved and exit rebooted got the two menu screens XPPro and Grub clicked on grub got a rather lengthy coloured menu screen told it to find XP OS and exited shall I now add the remaining 4 options as per post #6 namely

 

title Q4OS Desktop 3.8 Centaurus (hd1) GRUB2

rootnoverify (hd1)

chainloader +1

 

 

title Q4OS Desktop 3.8 Centaurus (hd1,0) GRUB2

root (hd1,0)

chainloader +1

 

 

title Q4OS Desktop 3.8 Centaurus core.img GRUB2

find --set-root --ignore-floppies --ignore-cd /boot/grub/core.img
kernel /boot/grub/core.img

 

title Q4OS Desktop 3.8 Centaurus core.img 386-pc GRUB2

find --set-root --ignore-floppies --ignore-cd /boot/grub/i386-pc/core.img
kernel /boot/grub/i386-pc/core.img

 

 

& try again?

 

Cheers & Regards, 

 

David



#11 ispy

ispy

    Silver Member

  • Tutorial Writer
  • 646 posts
  • Location:PILGRIM

Posted 23 September 2019 - 01:47 PM

Hi Wonko  :D ,

 

I have added the four additional menu items as per post #6 saved and rebooted.

 

I Get the same colorful menu screen with about 10 different items slitaz etc

 

0) being "find & load NTLDR of windows NT/2K/XP

1) ...

2) ...

3) ...

4) being Switch to Grub2 core.img for booting linux (Ubuntu, etc)

5) ... etc

 

If I switch from item 0 to item 4) the closest I could find to Q4OS the booting operation worked that is XPPro to Q4OS

 

this is all from a menu of

 

- Windows XP professional

- Grub4dos

 

Should it be working like this or will the menu items description need to be amended to reflect the 2No OS's. Can the remaining items be deleted to have just 2?

 

Best Wishes

 

David :rolleyes:



#12 ispy

ispy

    Silver Member

  • Tutorial Writer
  • 646 posts
  • Location:PILGRIM

Posted 23 September 2019 - 08:37 PM

Hi W :D nko,

 

Can I take this oppertunity in expressing a great big thankyou for sorting out my dual boot problems with XP & Q4OS I think I have re-arranged things in the Menu.lst file of grub4Dos & changed the Boot.ini title to:

 

C:\grldr="Boot Menu for Centaurus Q4OS"

 

 

I have also trimmed down the menu.lst file to the bare minimum to:

0) Boot to Windows XP Professional

1) Switch to GRUB2 core.img To Boot Centaurus Q4OS

 

I changed the timeout from 30 to 60secs

 

So from the black screen A menu of:

 

- Windows XP Professional (&)

- Boot Menu for Centaurus Q4OS

 

Is displayed & when you select the boot menu for Centaurus Q4OS the sub menu of Grub4Dos is displayed (Bright colourful thingy)

the menu options within this menu I have reduced to

 

0) Boot to Windows XP Professional

1) Switch to GRUB2 core.img To Boot Centaurus Q4OS

2) Reboot

 

If you select option 0) from the grub4Dos menu you are returned to the previous black screen option "Boot to Windows XP Professional" so in effect it is a looping effect with a reboot option to start again & option 1) boots Q4OS nicely.

 

Again many thanks you are a star

 

Best Regards,

 

David

 

Oh, P.S. Would you mind if I was to provide a link to this topic on the Q4OS website (As They were also trying to help out -  particularly an op going by the handle of Dai_Trying as it might help others in a similair situation, I will of course give the credits to you W ;) nko the Sane

 

Best Regards,

 

David

 

 

 

 



#13 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 24 September 2019 - 09:51 AM

Yep, good the issue is somehow solved :), of course now you can remove anything that you  don't have/use.

But you actually failed to report how each of the entries behave.
 
You had 5 (five) entries to test:

title Q4OS Desktop 3.8 Centaurus
find --set-root --ignore-floppies --ignore-cd /boot/vmlinuz-4.19.0-6-686-pae
root
uuid ()
pause
echo 'Loading Q4OS operating system ...'
kernel /boot/vmlinuz-4.19.0-6-686-pae root=UUID=5011cf2d-8555-42a3-9b80-b74427e2fe0d ro quiet loglevel=3 systemd.log_color=0 systemd.show_status=1
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-4.19.0-6-686-pae

title Q4OS Desktop 3.8 Centaurus (hd1) GRUB2
rootnoverify (hd1)
chainloader +1

title Q4OS Desktop 3.8 Centaurus (hd1,0) GRUB2
root (hd1,0)
chainloader +1

title Q4OS Desktop 3.8 Centaurus core.img GRUB2
find --set-root --ignore-floppies --ignore-cd /boot/grub/core.img
kernel /boot/grub/core.img

title Q4OS Desktop 3.8 Centaurus core.img 386-pc GRUB2
find --set-root --ignore-floppies --ignore-cd /boot/grub/i386-pc/core.img
kernel /boot/grub/i386-pc/core.img


In short:
1) title Q4OS Desktop 3.8 Centaurus
2) title Q4OS Desktop 3.8 Centaurus (hd1) GRUB2
3) title Q4OS Desktop 3.8 Centaurus (hd1,0) GRUB2
4) title Q4OS Desktop 3.8 Centaurus core.img GRUB2
5) title Q4OS Desktop 3.8 Centaurus core.img 386-pc GRUB2

The "right" one is #1, it should work, and once it works the root/uuid/pause - and possibly also the echo commands - can be removed from it.
All the other ones are "wrong" (in the sense that they are not elegant and unneededly complex).
#2 should work.
#3 probably won't (as the GRUB2 loader is installed to the MBR ann not to the volume)
either #4 or #5 should work (it depends on where W4OS stores the GRUB2 core.img)

Without such a report, the good guys coming from the Q4OS website will have a hard time to understand what happened and what - besides the one you chose (which BTW it is also not very clear)- possible solutions are available in similar cases.

:duff:
Wonko

#14 ispy

ispy

    Silver Member

  • Tutorial Writer
  • 646 posts
  • Location:PILGRIM

Posted 24 September 2019 - 01:53 PM

Hi W :D nko,

Feed Back is as follows, You may want to brain me after this but just to test your patience to a whole new level LOL here is what I have been doing kinda experimenting sorry!:

 

Gulp here goes! I changed the boot.ini entry from grub4Dos to:

C:\grldr="Boot Menu for Centaurus Q4OS" (just a title alteration minor title edit in fact)

Then I started trimming down the entries in the Menu.lst file by using the # symbol & trial and Error until only 3 options remained 

 

0 = Boot to Windows XP Professional

1 = Switch to GRUB2 core.img To Boot Centaurus Q4OS

2 = Reboot

(As shown below in quote from Menu.lst file)

 

title Boot to Windows XP Professional
fallback +1
find --set-root --ignore-floppies --ignore-cd /ntldr
map () (hd0)
map (hd0) ()
map --rehook
find --set-root --ignore-floppies --ignore-cd /ntldr
chainloader /ntldr
savedefault --wait=2
 
title Switch to GRUB2 core.img To Boot Centaurus Q4OS
fallback +1
find --set-root --ignore-floppies --ignore-cd /boot/grub/i386-pc/core.img
kernel /boot/grub/i386-pc/core.img
 
title reboot
reboot
 
I'm afaid I used the # option and gradually cut back all the options you suggested via a process elimination to try to break the loading method & found that this entry loads Q4OS which is part of the original meny apart from the title see below quote
 
title Switch to GRUB2 core.img To Boot Centaurus Q4OS
fallback +1
find --set-root --ignore-floppies --ignore-cd /boot/grub/i386-pc/core.img
kernel /boot/grub/i386-pc/core.img

 

 

It did the trick on its own, it boots Q4OS without any additional entries but I could try these if you would like for testing purposes, let me know if it is of interest to you?

 

Also I will upload the resultant Menu.lst file so you can see amended menu.lst file. In my defence I did Not mess about with the colour sheme but I find it a bit "gordy" Sorry Grub4Dos developers it is just a subjective viewpoint.

I also changed the timeout in the Grub4Dos menu to 60-Seconds thereafter it defaults back to the Windows XP Prodfessional option (Black Screen) etc

 

I have also started writing a .rtf Readme help file to illustrate the whole process should someone else want to try the same thing. If you agree I could send you a copy via the internal messaging RebootPro to peruse & then I could post it here and on the Q4OS website with a link if you are in agreement & you don't mind being mentioned? I was wondering whether the 8.5Gb Linux swap file would be better located on the backend of the XPPro drive for performance sake and whether a cmd batch script uninstaller for returning the system back to its original setup if Op's don't like Q4OS maybe or for a myriad of reasons.

 

It would involve the removal of the C:\ Grldr & Menu.lst files along with reinstating a backed up copy of the original Boot.ini or just scrubbing the Grub4Dos line in the boot.ini somehow. The op would of course need to remove the power/sata3 cable to isolate the hdd for other usage. Anyway just some thoughts I hope I havn't strayed to far off the track but I have a character flaw of meddling with things. I could create a zip file with the readme Grldr, Menu.lst, boot.ini entry file etc

 

Best Regards,

 

David :wub: 

 

 

Attached Files

  • Attached File  menu.txt   2.55KB   254 downloads


#15 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 24 September 2019 - 03:14 PM


Yep, everything is fine  :)  , but the whole point is that you are now using 3 bootmanagers (NTLDR+grub4dos+GRUB2) when 2 are enough (NTLDR+grub4dos) in your case.

Everything should be as simple as possible (but not simpler).

Anyway, since you are not using the "C:\grldr" entry for anything but the Q4OS, you can remove altogether the menu.lst file (thus avoiding not only the ugly colours, but also the additional choosing the Q4OS) by editing the embedded menu in grldr.

The last few lines of grldr contain a menu.lst, the version you have, 0.4.6a-2019-07-16, has this:
 

pxe detect
configfile
default 0
timeout 1

title find /menu.lst, /boot/grub/menu.lst, /grub/menu.lst
errorcheck off
configfile /boot/grub/menu.lst
configfile /grub/menu.lst
if "%@root%"=="(ud)" && calc *0x82A0=*0x82b9&0xff
if "%@root:~1,1%"=="f" && find --set-root --devices=f /menu.lst && configfile /menu.lst
find --set-root --ignore-floppies --ignore-cd /menu.lst && configfile /menu.lst
find --set-root --ignore-floppies --ignore-cd /boot/grub/menu.lst && configfile /boot/grub/menu.lst
find --set-root --ignore-floppies --ignore-cd /grub/menu.lst && configfile /grub/menu.lst
configfile http://b.chenall.net/menu.lst
errorcheck on
commandline

title commandline
commandline

title reboot
reboot

title halt
halt

 
If you replace that with:

default 0
timeout 1

title find Switch to GRUB2 core.img To Boot Centaurus Q4OS
fallback +1
find --set-root --ignore-floppies --ignore-cd /boot/grub/i386-pc/core.img
kernel /boot/grub/i386-pc/core.img

title commandline
commandline

title reboot
reboot

title halt
halt


You will normally get to GRUB2 and conversely to Q4OS "directly".

 

To do the repplacing you need a hex editor (not a text editor like Notepad or Wordpad) or you can strip the relevant bytes and re-add the new menu with a dd-like utility.

:duff:
Wonko



#16 ispy

ispy

    Silver Member

  • Tutorial Writer
  • 646 posts
  • Location:PILGRIM

Posted 24 September 2019 - 04:49 PM

Hi W :D nko,

 

So over simplified if you were to translate the text in your quote1 of post #15 into hexidecimal (Lets call it Trans1 for ease of understanding) like this using an online text to Hex editor hex representation of Quote1 post #15 e.g

 

70 78 65 20 64 65 74 65 63 74 0a 63 6f 6e 66 69 67 66 69 6c 65 0a 64 65 66 61 75 6c 74 20 30 0a 74 69 6d 65 6f 75 74 20 31 0a 0a 74 69 74 6c 65 20 66 69 6e 64 20 2f 6d 65 6e 75 2e 6c 73 74 2c 20 2f 62 6f 6f 74 2f 67 72 75 62 2f 6d 65 6e 75 2e 6c 73 74 2c 20 2f 67 72 75 62 2f 6d 65 6e 75 2e 6c 73 74 0a 65 72 72 6f 72 63 68 65 63 6b 20 6f 66 66 0a 63 6f 6e 66 69 67 66 69 6c 65 20 2f 62 6f 6f 74 2f 67 72 75 62 2f 6d 65 6e 75 2e 6c 73 74 0a 63 6f 6e 66 69 67 66 69 6c 65 20 2f 67 72 75 62 2f 6d 65 6e 75 2e 6c 73 74 0a 69 66 20 22 25 40 72 6f 6f 74 25 22 3d 3d 22 28 75 64 29 22 20 26 26 20 63 61 6c 63 20 2a 30 78 38 32 41 30 3d 2a 30 78 38 32 62 39 26 30 78 66 66 0a 69 66 20 22 25 40 72 6f 6f 74 3a 7e 31 2c 31 25 22 3d 3d 22 66 22 20 26 26 20 66 69 6e 64 20 2d 2d 73 65 74 2d 72 6f 6f 74 20 2d 2d 64 65 76 69 63 65 73 3d 66 20 2f 6d 65 6e 75 2e 6c 73 74 20 26 26 20 63 6f 6e 66 69 67 66 69 6c 65 20 2f 6d 65 6e 75 2e 6c 73 74 0a 66 69 6e 64 20 2d 2d 73 65 74 2d 72 6f 6f 74 20 2d 2d 69 67 6e 6f 72 65 2d 66 6c 6f 70 70 69 65 73 20 2d 2d 69 67 6e 6f 72 65 2d 63 64 20 2f 6d 65 6e 75 2e 6c 73 74 20 26 26 20 63 6f 6e 66 69 67 66 69 6c 65 20 2f 6d 65 6e 75 2e 6c 73 74 0a 66 69 6e 64 20 2d 2d 73 65 74 2d 72 6f 6f 74 20 2d 2d 69 67 6e 6f 72 65 2d 66 6c 6f 70 70 69 65 73 20 2d 2d 69 67 6e 6f 72 65 2d 63 64 20 2f 62 6f 6f 74 2f 67 72 75 62 2f 6d 65 6e 75 2e 6c 73 74 20 26 26 20 63 6f 6e 66 69 67 66 69 6c 65 20 2f 62 6f 6f 74 2f 67 72 75 62 2f 6d 65 6e 75 2e 6c 73 74 0a 66 69 6e 64 20 2d 2d 73 65 74 2d 72 6f 6f 74 20 2d 2d 69 67 6e 6f 72 65 2d 66 6c 6f 70 70 69 65 73 20 2d 2d 69 67 6e 6f 72 65 2d 63 64 20 2f 67 72 75 62 2f 6d 65 6e 75 2e 6c 73 74 20 26 26 20 63 6f 6e 66 69 67 66 69 6c 65 20 2f 67 72 75 62 2f 6d 65 6e 75 2e 6c 73 74 0a 63 6f 6e 66 69 67 66 69 6c 65 20 68 74 74 70 3a 2f 2f 62 2e 63 68 65 6e 61 6c 6c 2e 6e 65 74 2f 6d 65 6e 75 2e 6c 73 74 0a 65 72 72 6f 72 63 68 65 63 6b 20 6f 6e 0a 63 6f 6d 6d 61 6e 64 6c 69 6e 65 0a 0a 74 69 74 6c 65 20 63 6f 6d 6d 61 6e 64 6c 69 6e 65 0a 63 6f 6d 6d 61 6e 64 6c 69 6e 65 0a 0a 74 69 74 6c 65 20 72 65 62 6f 6f 74 0a 72 65 62 6f 6f 74 0a 0a 74 69 74 6c 65 20 68 61 6c 74 0a 68 61 6c 74 

 

open the Grldr file with say HxD Identify the translated text in the HxD Hexy editor then delete those Hex values. Then you were to subsequently translate the text in your quote 2 post#15 into hexidecimal values call it trans2 & paste/enter them it into the same area you removed trans1 from, then saved the results would it achieve the same result hyperthetically. I have to admit I have never used a hex editor as it is well above my pay scale & abilities.

Subtract Trans1 once hex is identified then add Trans2 and save it as a new Grldr file, a frankenstein amendmant.

 

The additional question is what would the developers of Grub4Dos think & do if you were to alter their source code would you find yourself having to hire a legal person if you know what I mean as they may inadvertantly spit their dummy out?

 

The problem is grub2 is the new model that linux systems are opting for & with each new development a new layer is created resulting in additional steps or workarounds to achieve the same goal but more inbuilt complexities. 3 instead of 2 maybe at the end of the day a fair trade-off.

 

Would you like me to interchange those additional menu items as stated in your previous post & give you the results?

 

Best Regards,

 

David

 

 



#17 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 24 September 2019 - 06:45 PM

It's easier than that, it is the very end of the file.

 

1) open the grldr file with a hex editor

2) search (and hopefully) find the string "pxe detect"

3) make sure visually (*any* hex editor represents on the left the actual hex values and on the right the "normal" characters corresponding to them)   that the above string is followed by "configfile", etc. or more simply scroll until the end of the file and then go back up a little until you find it.

4) select from "pxe" to the end of the file

5) cut

6) save the grldr file

7) copy and paste the proposed menu with (say) Notepad and save it as - still say - C:\mymenu.txt

8) open a command prompt and in it run: COPY /B C:\grldr + C:\mymenu.txt

 

 

 

The additional question is what would the developers of Grub4Dos think & do if you were to alter their source code would you find yourself having to hire a legal person if you know what I mean as they may inadvertantly spit their dummy out?

 

It's fine, you are not altering the source code, you are actually altering the binary.

 

 

 

 

The problem is grub2 is the new model that linux systems are opting for & with each new development a new layer is created resulting in additional steps or workarounds to achieve the same goal but more inbuilt complexities. 3 instead of 2 maybe at the end of the day a fair trade-off.

 

Every trade off is fair in the eyes of anyone that cannot use "better" trade offs and of course "better" is in the eye of the beholder.

 

Whatever "linux systems" are "opting for" is their business, when something is overcomplex I reserve the right to say so:

https://jdebp.eu/FGA...oolishness.html

 and - if possible - provide simpler, easier, less intrusive solutions, i.e. provide options as opposed to removing them.

 

Without grub4dos you would have needed to accept the GRUB2 MBR on first disk or set the second disk as boot one and go through GRUB2 everytime you wanted to boot the XP, or, if you prefer, you would have been forced to have the GRUB2 as "main" bootmanager/bootloader, what they (the "linux systems") are "opting for" essentially removes some of your options (among which there is the one of leaving the first disk "as is" and boot XP directly).

 

:duff:

Wonko



#18 ispy

ispy

    Silver Member

  • Tutorial Writer
  • 646 posts
  • Location:PILGRIM

Posted 24 September 2019 - 08:14 PM

HI W :D nko,

 

I have amended the grldr file as outlined in your previous post using portable HxD Hex Editor. I will upload a copy for you to check if you like to peruse & confirm if okay.

 

The grldr remains the same 322 Kbs as the original heres a brief description of what I did

  1. Created a folder called "C:\grldr copy" copied the original or what i used grldr into it opened it with HxD Hex editor found the PXE text highlighted it down to the very bottom and cut then saved it the file became 321Kbs in size 1 kb reduction in size
  2. Opened Notepad copy the amended proposed menu text in quote 2 of your explanantion & saved as mymenu.txt in same folder.
  3. Opened CMD Changed Dir to C:\grldr copy
  4. Ran command COPY /B grldr + mymenu.txt (new file created back upto 322Kbs) 

I have uploaded a screenie showing the new grldr file opened by HxD post CMD stage showing the amendmant along with the new grldr for you to look at within grldr.zip below.

 

Let me know what you think and the next step going forward.

 

Best Regards,

 

David  :)

 

 

Attached Files



#19 ispy

ispy

    Silver Member

  • Tutorial Writer
  • 646 posts
  • Location:PILGRIM

Posted 25 September 2019 - 08:18 AM

Hi W :D nko,

 

Tried out the hacked new grldr file in the root of C:\ without the meunu.lst file and it works, it boot Q4OS without the Gordy Grub4dos Menu screen, it just offers the boot options of Windows XP Professional & Boot Menu for Centaurus Q4OS which I have changed the desription to Boot Centautus Q4OS in the boot.ini file.

 

I can confirm some text is very briefly displayed after selecting the Q4OS option but this method is cleaner & only the grldr file is needed, I don't how you know all this magic but I am impressed. If I was to play around with Grub4dos  for a million years II wouldn't have got to this stage, so really I do feel guilty about not knowing this stuff, you are one gifted individual.

 

I could write a small tutorial as hinted in previous posts if you like as this method bypasses the Grub2 Bootloader in favour of the Grub4Dos grldr loader & utiliizes the Ntldr. I could also link to Q4OS site as it would be useful for those wanting to dual boot XPPro & Q4OS

 

Maybe the newly created file should be renamed from grldr to Wonko & rename the the entry in the boot.ini to:

C:\Wonko="Boot Centaurus Q4OS" therein you would get some just credit for this boot loader, I will have to try that & get back to you. Edit - Just to confirm this option does not work it keeps looking for the grldr file claiming it cannot be found sorry!

 

Anyways many thanks is an understatement as I have arrived at a destination I never thought I would get to all because you with the technical skill took the time to answer a request to put this together, Cheers Matey!!!

 

All the best 

 

David   :thumbup:  :thumbup:  :thumbup:  :thumbup:



#20 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 25 September 2019 - 12:12 PM

Good. :)
 
Now, if you are still in the experimenting, try the following:
1) disconnect the second disk with Q4OS
2) boot
3) choose in boot.ini the Q4OS entry
4) the first (default) menu.lst entry (the one for Q4OS) will fail since no /boot/grub/i386-pc/core.img can be found
5) the "fallback+1" provision (which means "if this entry fails to boot try the next one") should then boot second menu.lst entry and you should find yourself at a grub> command prompt
6) type in it "chainloader /ntldr" (without double quotes) and you should find yourself back to the boot.ini choices (and this time choose the XP entry and it should boot normally)
 
About this:
 
 

I can confirm some text is very briefly displayed after selecting the Q4OS option

 
There are - if you want - a couple tricks/mods to remove that.
Since the patching may be "version specific" it has to be checked if existing solutions:
http://reboot.pro/to...-loading-grldr/
http://reboot.pro/to...-debug-feature/
actually apply to a later release or need to be changed/adapted.
  :duff:
Wonko

#21 ispy

ispy

    Silver Member

  • Tutorial Writer
  • 646 posts
  • Location:PILGRIM

Posted 25 September 2019 - 02:35 PM

Hi W :D nko,

 

Carried out instructs in your previous post.

 

1) Disconnected Q4OS hdd

2) Tried to boot to Q4OS hdd & of course it failed to load. it went to Grub > commandline 

3) Typed in chainloader /ntldr & the following message was displayed.

 

Will boot ntldr from drive=0x80, partition=0x0 (hiden sectors=0x800)

 

 

Then it went back to

 

Grub> commandline Not ntldr menu

 

(did this operation twice to check if typo human error was at fault but same result both times.

So I Ctrl+Alt+Delete rebooted and selected XP Professional option - I do remember previously or I did in the legacy Bios setup having to change the boot order of the Hdds to ensure XP drive booted first, could this have something to do with the not getting back to the menu screen possibly? 

 

So supressing the text while booting is a bit like >Nul command in dos/cmd? It may be prudent to retain the text for possible diagnostics not that you get a chance to read it as it is only momentary & what about forwarding to a log file if unsucessful boot occurs but gets deleted if successful boot occurs kinda complicates things somewhat.

 

Anyways feedback results as requested

 

Best Regards,

 

David  :)

 

 



#22 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 25 September 2019 - 04:10 PM

Yep, my bad :blush: , after typing:
chainloader /ntldr
[ENTER]
and the grub4dos feedback:
Will boot ntldr from drive=0x80, partition=0x0 (hiden sectors=0x800)

Type:
boot
[ENTER]

:duff:
Wonko



#23 ispy

ispy

    Silver Member

  • Tutorial Writer
  • 646 posts
  • Location:PILGRIM

Posted 25 September 2019 - 06:14 PM

Hi W :D nko,

 

Sorry to report that option also failed repeated the same process but typed boot <Enter> & the following error code was displayed:

 

Error8:(http://grub4dos.chenall.net/e/8)

Kernel must be loaded before booting

 

Then went back to grub command prompt

grub>

 

Any further thoughts?

 

Best Regards,

 

David  :)



#24 Wonko the Sane

Wonko the Sane

    The Finder

  • Advanced user
  • 16066 posts
  • Location:The Outside of the Asylum (gate is closed)
  •  
    Italy

Posted 25 September 2019 - 07:04 PM

That is "queer".

 

Unless - for whatever reasons - there is something else going on.

 

Maybe root was not established? :dubbio:

 

Plese try again, this time:

find --set-root /ntldr

chainloader /ntldr

boot

 

or:

root (hd0,0)

chainloader /ntldr

boot

 

or:

rootnoverify (hd0)

chainloader +1

boot

 

or:

root (hd0,0)

chainloader +1

boot

 

all of these should work.

 

 

:duff:

Wonko



#25 ispy

ispy

    Silver Member

  • Tutorial Writer
  • 646 posts
  • Location:PILGRIM

Posted 25 September 2019 - 08:04 PM

Hi W :D nko,

 

Feedback on previous post listed as follows:

 

find --set-root ntldr   ......................Error Code 15 - File Not found

chainloader /ntldr     ......................Didn't proceed any further due to error code

boot                          .....................Ditto to above

 

root (hd0,0)              .....................File system type ntfs, partition type 0x07

chainloader /ntldr     .....................Will boot ntldr from drive=0x80, partition=0x0 (hiden sectors=0x800)

boot                          ....................Didn't proceed any further due to error code

 

rootnoverify (hd0)    .....................Error: No such command: rootnotfy

chainloader +1        .....................Didn't proceed any further due to error!

Boot                         ....................Ditto to above

 

root (hd0,0)            ......................Filesystem type ntfs, partition type 0x007

Chainloader +1      ......................no output nuthin happened

Boot                       ......................Went to menu - Microsoft Windows XP Professional

                                                                            - Boot Centaurus Q4OS

 

4th one appeared to work sumfin swirly gowin-on?

 

Best regards,

 

David  :D 






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users