LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   SUSE / openSUSE (https://www.linuxquestions.org/questions/suse-opensuse-60/)
-   -   Grub issue...total n00b (https://www.linuxquestions.org/questions/suse-opensuse-60/grub-issue-total-n00b-605494/)

Tweakerz 12-08-2007 09:39 PM

Grub issue...total n00b
 
First let me say I am sorry as this will probably not be so difficult for most, but I have been all over this site and others reading everything I could find and trying every combination of boot settings from linux users from other forums I belong to and decided it best to join here and ask, make that beg and plead for assitance. I also checked on the suse site and found so much but somehow haven't managed to fix my issues. As a side not the dependicies thing is a bit frustrating when trying to install Skype, finally got it installed but it attempts to load for 30 seconds and then it is gone...but that is of little importance right now. (I should have been more careful but this is a work machine which I thought I would keep safe by using seperate drives, so hopefully someone can describe the exact items to edit as I need to be able to get back into Windows more than I need the linux working, just wanted to learn more about it and possibly someday migrate to it as a main OS) Also allow me to thank anyone and everyone that replies, I am at your mercy here.


I have tried to include as much information as clearly stated as possible, I need my hand held possibly but managed to figure out how to get this info which is I hope a decent start...on to the specifics:

Ok, I have a Windows XP installation on an IDE 80GB HDD and a load of Suse 10.3 on a 36GB SATA. In the BIOS the 36GB (suse) drive is first and the 80GB (xp) is second, if I switch them around grub boot loader will not load, the current setup allows me to boot into suse where I am now, but Windows fails to load returning an error of:

rootnoverify (hd0,4)
chainloader (/dev/sda1,0)+1

Error 23: Error while parsing number

Press any key to continue...

Now I have made a backup of my menu.lst and am copying it here in hope someone can suggest a solution.

# Modified by YaST2. Last modification on Thu Dec 6 17:15:14 UTC 2007
default 0
timeout 8
gfxmenu (hd0,4)/message
##YaST - activate

###Don't change this comment - YaST2 identifier: Original name: linux###
title openSUSE 10.3
root (hd0,4)
kernel /vmlinuz-2.6.22.5-31-default root=/dev/mapper/via_jbgafbid_part7 vga=0x31a resume=/dev/mapper/via_jbgafbid_part6 splash=silent showopts
initrd /initrd-2.6.22.5-31-default

###Don't change this comment - YaST2 identifier: Original name: windows###
title Windows
rootnoverify (hd1,0)
chainloader (/dev/sda1,0)+1

###Don't change this comment - YaST2 identifier: Original name: floppy###
title Floppy
rootnoverify (hd0,4)
chainloader (fd0)+1

###Don't change this comment - YaST2 identifier: Original name: failsafe###
title Failsafe -- openSUSE 10.3
root (hd0,4)
kernel /vmlinuz-2.6.22.5-31-default root=/dev/mapper/via_jbgafbid_part7 vga=normal showopts ide=nodma apm=off acpi=off noresume edd=off 3
initrd /initrd-2.6.22.5-31-default

jdmcdaniel3 12-08-2007 11:21 PM

Try This Entry In Your Menu.Lst
 
I boot from a external USB drive and Windows is on an internal drive, this is kind of similar to your situation. This is my Windows Entry to load Windows from a second drive that was not the boot drive.


###Don't change this comment - YaST2 identifier: Original name: windows###
title Windows XP Professional
rootnoverify (hd1,1)
chainloader (hd1,0)+1
map (hd0) (hd1)
map (hd1) (hd0)


Thank You,

Tweakerz 12-09-2007 12:50 AM

I have copied this information and will will try it out but wished to ask first...so long as I leave the Suse portion alone it seems I won't make matters any worse, just curious if the mapping could in any way affect the suse portion, thanks for your reply!

EDIT: Ok, I tried what you suggested, what is weird is that I typed it as you have it here, then I double-checked it and it looked EXACT, then I rebooted and got almost the same error as I had been getting but slightly different, makes no sense the way it returned this error because before the reboot it looked identical to yours.
This is the somewhat new error:

rootnoverify (hd0,4)
chainloader ((hd1,0) )+1

then it was the Error 23: parsing etc., etc. and then press any key... just like posted above.

Perhaps I am somehow using the editor wrong? What I do is open YaST and type the password, then click System, then Boot Loader, then it scans and I have a few tabs, I then go to Other near the bottom right and cick that choosing Edit Configuration Files, then a dropdown menu called Filename is offered from which I select /boot/grub/menu.lst and below that the File Contents where I then proceed to edit the appropriate lines which are no longer matching yours like before the reboot and now look like I listed above...I am stumped on how/why this happens and why it autosetup/configured things this way to begin with, hopefully this is actually easily resolvable although it doesn't seem that way currently.

jdmcdaniel3 12-09-2007 09:56 AM

You must be logged in as Root User to Edit Menu.Lst
 
To be sure you must edit the file /boot/grub/menu.lst as root. If you go through the KDE menu system pick "/system/file manager/file manager - super user mode" and enter the root password. Navigate to the folder /boot/grub and elect to edit the file menu.lst using an editor like Kate. Make sure you save your changes and then restart. The entry you are seeing is not what I have requested you use. I don't know how you are changing this file and if those changes are being saved. Further I am assuming grub is loaded on the same boot drive that SuSE is loaded on and your BIOS is booting SuSe properly and it will run.

Thank You,

Tweakerz 12-09-2007 08:39 PM

Quote:

Originally Posted by jdmcdaniel3 (Post 2984963)
To be sure you must edit the file /boot/grub/menu.lst as root. If you go through the KDE menu system pick "/system/file manager/file manager - super user mode" and enter the root password. Navigate to the folder /boot/grub and elect to edit the file menu.lst using an editor like Kate. Make sure you save your changes and then restart. The entry you are seeing is not what I have requested you use. I don't know how you are changing this file and if those changes are being saved. Further I am assuming grub is loaded on the same boot drive that SuSE is loaded on and your BIOS is booting SuSe properly and it will run.

Thank You,


I was using Yast to go to system and boot loader, when i change like yours it switches to the odd look above, and grub is using the suse hdd which in bios is the first drive and suse does boot, if it is listed as the secondary in bios it won't load anything, not even grub. Thx again, will see if I can figure out how to click the right things to edit the file without using yast and the boot loader applet.

EDIT: Ok, thank you for your step by step as it allowed me to open and configure the file without it switching, it stayed the same this time, but it returned a new error message now...

rootnoverify (hd1,1)
chainloader (hd1,0) +1
Error 1: Filename must be either an absolute pathname or blocklist
Press any key to continue...

I am happy that it retained setting this time, man if ever there is a next time I guess allowing an automatic grub config to occur while installing suse isn't such a wise move.

syg00 12-10-2007 12:11 AM

From a Linux terminal, run "/sbin/fdisk -l" (that's a lower case ell, as in list) and post all the output here - else we're all just guessing.

Tweakerz 12-10-2007 09:01 AM

Quote:

Originally Posted by syg00 (Post 2985598)
From a Linux terminal, run "/sbin/fdisk -l" (that's a lower case ell, as in list) and post all the output here - else we're all just guessing.

Thank you as well for your assistance, this is the output from the above command:

Disk /dev/sda: 80.0 GB, 80026361856 bytes
255 heads, 63 sectors/track, 9729 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x283f283e

Device Boot Start End Blocks Id System
/dev/sda1 * 1 9729 78148161 7 HPFS/NTFS

Disk /dev/sdb: 37.0 GB, 37019566080 bytes
255 heads, 63 sectors/track, 4500 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x000d0046

Device Boot Start End Blocks Id System
/dev/sdb1 1 4500 36146218+ f W95 Ext'd (LBA)
/dev/sdb5 1 9 72229+ 83 Linux
/dev/sdb6 10 271 2104483+ 82 Linux swap / Solaris
/dev/sdb7 272 1989 13799803+ 83 Linux
/dev/sdb8 1990 4500 20169576 83 Linux

Disk /dev/dm-0: 37.0 GB, 37019516928 bytes
255 heads, 63 sectors/track, 4500 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x000d0046

Device Boot Start End Blocks Id System
/dev/dm-0p1 1 4500 36146218+ f W95 Ext'd (LBA)
/dev/dm-0p5 1 9 72229+ 83 Linux
/dev/dm-0p6 10 271 2104483+ 82 Linux swap / Solaris
/dev/dm-0p7 272 1989 13799803+ 83 Linux
/dev/dm-0p8 1990 4500 20169576 83 Linux
Warning: invalid flag 0x0000 of partition table 6 will be corrected by w(rite)

Disk /dev/dm-1: 37.0 GB, 37013727744 bytes
255 heads, 63 sectors/track, 4499 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000

Device Boot Start End Blocks Id System
/dev/dm-1p1 1 9 72229+ 83 Linux
/dev/dm-1p2 9 271 2104515 5 Extended
/dev/dm-1p5 10 271 2104483+ 82 Linux swap / Solaris
/dev/dm-1p6 ? 25463 50649 202309635+ 7 HPFS/NTFS

Disk /dev/dm-2: 73 MB, 73963008 bytes
255 heads, 63 sectors/track, 8 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000

Disk /dev/dm-2 doesn't contain a valid partition table

Disk /dev/dm-3: 2154 MB, 2154991104 bytes
255 heads, 63 sectors/track, 261 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000

Disk /dev/dm-3 doesn't contain a valid partition table

Disk /dev/dm-4: 14.1 GB, 14130998784 bytes
255 heads, 63 sectors/track, 1717 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000

Disk /dev/dm-4 doesn't contain a valid partition table

Disk /dev/dm-5: 20.6 GB, 20653645824 bytes
255 heads, 63 sectors/track, 2510 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00000000

Disk /dev/dm-5 doesn't contain a valid partition table

syg00 12-10-2007 03:33 PM

I would try
Code:

title Windows XP Professional
rootnoverify (hd1,0)
map (hd0) (hd1)
map (hd1) (hd0)
chainloader +1


Tweakerz 12-10-2007 07:16 PM

Quote:

Originally Posted by syg00 (Post 2986385)
I would try
Code:

title Windows XP Professional
rootnoverify (hd1,0)
map (hd0) (hd1)
map (hd1) (hd0)
chainloader +1


YES!!! Success, and to think it was the rearrange, switching to that order with map preceding chainloader solved the problem! I cannot express my gratitude, but I thank you for this solution. I have to go out of town tomorrow but hope to learn more from this forum and hopefully not have too many annoying questions, my next problem will be to get skype to launch. Only other thing for right now that I would like to know though is how would I, if or when it needs to happen, how would I go back to having only the Windows drive in the system? I do not wish to remove the drive but eventually if the need arises is that a simple thing to remove the suse and leave the windows hdd and return it to a functional state? I know it won't boot alone as I tried that already out of desperation when the problem first came about. Thanks again!!!

syg00 12-10-2007 07:22 PM

Just change the BIOS boot order - Windoze will ignore the Linux drive.

Tweakerz 12-11-2007 10:20 PM

Quote:

Originally Posted by syg00 (Post 2986594)
Just change the BIOS boot order - Windoze will ignore the Linux drive.

may have te retry that, I had the xp only drive connected and it wouldn't boot without the suse hdd for some reason, at that point I figure mbr related issues. Now messing with it for now, hopefully for awhile as I need to get some things done then worry about it later on, thanks again for the ultimate solution, I had several times tried it but with the lines in a different order, seemed everyone suggested that order, unsure why/how you thought to swap the map lines and chainloader lines but it worked and that's all that matters to me!!!

Tweakerz 12-16-2007 02:25 AM

Given all the information above and the fact things are still working fine in both Suse and XP, I do need the information on removing the Suse drive and leaving the XP drive, I plan to switch the Suse install to another drive, problem it seems is that if I remove the Suse hard drive I get only a Grub error since it cannot be found, so I take it to mean the MBR of XP has been affected? I either need to try fix /mbr or fix /boot I assume...or is there another way with Grubs involvement? So long as I lose none of the data on the XP drive there isn't any issues, I just need to get the hdd Suse is on and use it for another purpose, one of the other spares will become the replacement and have Suse or maybe another distro as I am attempting to figure out which I prefer, I think though it will end up being Suse and probably moved to another pc altogether. Thanks!

Tweakerz 12-16-2007 02:27 AM

nevermind...solved
 
I found several solutions but decided to just take a stab at it and all is well, feel free to delete this.

unSpawn 12-16-2007 02:40 AM

Tweakerz, you already have this thread, so a new thread for the same topic is a duplicate. I merged your threads.

Tweakerz 12-16-2007 02:52 AM

Quote:

Originally Posted by unSpawn (Post 2992012)
Tweakerz, you already have this thread, so a new thread for the same topic is a duplicate. I merged your threads.

Sorry bud, I thought because the other was considered solved it would require a second, I moderate on a forum (windows based mostly obviously) and generally if the problem is different then many times a new request is made, not always, but usually, thanks, as you may notice I solved the problem one with of several solutions I found.


All times are GMT -5. The time now is 02:52 AM.