DebianThis forum is for the discussion of Debian Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
It appears that you have a mixed up MBR thinking that you are using grub-legacy while attempting to use the menu from grub-pc.
That's the impression I have, as well.
Anyway, try the following, not sure if it will work, but it won't harm. Boot a live cd, -it has to be a new one that uses grub2-, and execute the these commands logged in as root:
Code:
mkdir /mnt/debian
mount /dev/sda6 /mnt/debian
grub-install --root-directory=/mnt/debian --recheck /dev/sda
(More info about how to reinstall grub2 here). I will keep investigating about this issue, too.
Distribution: Debian Testing, Stable, Sid and Manjaro, Mageia 3, LMDE
Posts: 2,628
Rep:
I have been studying and find the this very confusing.
One problem is that I have never seen the boot info script come up with errors.
How about trying it again but use this link to get the script. It may be the same, I did not check the one you used but the authors ask that folks be directed to this page. http://bootinfoscript.sourceforge.net/
One problem is that you have grub-legacy installed on an OS using a kernel that was put out long after support for grub-legacy ended. I do not think this is the direct cause of your troubles but when you get back into that install I would install grub-pc on it.
It could be that the lack of info from that install was due to the boot info script errors. Lets try it again and see if it works better with the link above.
How can i tell if the version of grub on the liveCD is grub2 or grub-legacy? is it 'grub -v' or something?? [liveCD is puppy4, i'd rather not burn another CD if i don't have to]
Right.. so both voyage's version and puppy 4's version of grub was 0.97.. ie legacy. [sidenote: it really would have been nice for the debian installer to have figured this out.. also WTF is up with seemingly no WPA support??]
I have no wifi with the LiveCD so i'll go try plugging in and see what i can do..
[its 2011, you should really get yourself a USB drive! ]
Distribution: Debian Testing, Stable, Sid and Manjaro, Mageia 3, LMDE
Posts: 2,628
Rep:
Quote:
Originally Posted by sdfi
Right.. so both voyage's version and puppy 4's version of grub was 0.97.. ie legacy. [sidenote: it really would have been nice for the debian installer to have figured this out.. also WTF is up with seemingly no WPA support??]
I have no wifi with the LiveCD so i'll go try plugging in and see what i can do..
[its 2011, you should really get yourself a USB drive! ]
I have a usb drive. Dual 320GB WB SATA2 pc type internal drives in an external enclosure.
You are right though, I really should have one of the sticks. Next time I am in some damned town that sells them at a decent price I will get one. Here (population 500) they are do much for me.
Go on to ebay, i guarantee you'd get a low-ish capacity one for <$2, sent to your door! ..unless you're not a fan of ebay.
ANYWAY; i've ran the grub2 install command, and it has come back at me
Code:
The following command line was extrated from /etc/default/grub or the 'kopt' peram in GRUB Leg's menu.1st Please verify that it is correct and modify it if necessary.
L Command line:
[blank]
mkdir /mnt/debian
mount /dev/sda6 /mnt/debian
grub-install --root-directory=/mnt/debian --recheck /dev/sda
Done, no change. NB: /dev/hda5 (no idea why it went from s to h.. i never got that-- but 6 is the swap partition and it wouldn't let me use that. Also, it complained about post mbr gap again.
Distribution: Debian Testing, Stable, Sid and Manjaro, Mageia 3, LMDE
Posts: 2,628
Rep:
Quote:
Originally Posted by sdfi
Done, no change. NB: /dev/hda5 (no idea why it went from s to h.. i never got that-- but 6 is the swap partition and it wouldn't let me use that. Also, it complained about post mbr gap again.
Sorry for the delay. Had to go to the bar. Yes that does sound weird. This town is the county seat. Biggest town in the county. 500 population. Wife is off tonight but is one of the main bartenders. What does this have to do with me? Would take to long to explain.
Grub-pc has no menu.list. Does not exist. Will never be found.
Does have a /boot/grub/grub.cfg that serves a similar role. It is not editable, not true. Makes no sense to edit it as it is over written every time "update-grub is run.
Do you know how to do a full chroot to your system, preferably the Squeeze install?
The reason I ask is that I have no idea how to deal with Voyage. It is using an obsolete version of grub (one I dearly loved) but will not deal with modern OS's well).
What needs done is to remove grub-pc and grub-commmon from that install. This is not because it is bad. It is to make sure that everything knows it is there. Then it needs to be reinstalled.
As root;
Code:
ap-get install grub-pc grub-common
This will give you the conditions like a new install of Debian Squeeze. Hopefully it works this time.
urgh this is driving me mad.
I chrooted into debain (like below)
Code:
mkdir /debian
mount /dev/hda5 /debian
chroot /debian
I uninstalled grub with 'apt purge grub grub-common'.
The damn thing was asking for my debian CD for sources, but the CD drive would not open. I changed the sources to use online... and 'apt-get install grub-pc grub-common' returns 'unable to locate package grub-pc', same for grub-common! (although apt-get update works fine)!. urgh. I have figured how to force the CD drive open (there is no eject command found) and now of course i've deleted the line with the CD repo on it and i don't know how to add it back in!
urgh this is driving me mad.
I chrooted into debain (like below)
Code:
mkdir /debian
mount /dev/hda5 /debian
chroot /debian
I uninstalled grub with 'apt purge grub grub-common'.
The damn thing was asking for my debian CD for sources, but the CD drive would not open. I changed the sources to use online... and 'apt-get install grub-pc grub-common' returns 'unable to locate package grub-pc', same for grub-common! (although apt-get update works fine)!. urgh. I have figured how to force the CD drive open (there is no eject command found) and now of course i've deleted the line with the CD repo on it and i don't know how to add it back in!
I think the easiest thing to do is use the Debian installer to install grub again.
Boot the CD or USB stick the use the Advance options>Rescue mode enter your keyboard hostname and other info then select the partition your Debian is on then 'Reinstall the Grub Boot Loader '. That should do every thing for you. When done select reboot and you should be in your new Debian install.
It may or may not detect your other Linux install but it should see Window$ XP just fine.
Well, what I would do to get away of this situation fast would be to download supergrub and a) dd it to a floppy or b) install it into a usb stick. If you have a floppy drive, you can try downloading it from here, then simply execute:
There is no 'Reinstall the Grub Boot Loader' option under Advance options>Rescue mode on the install CD. The options are 'execute a shell in [root fs location]' 'execute a shell in installer location', change root fs, and reboot.
widget; like i said, i removed the CD from sources.list. (It has the normal online sources, and they 'hit' fine when running apt-get update.) How do i put the install CD back in sources.list?
Distribution: Debian Testing, Stable, Sid and Manjaro, Mageia 3, LMDE
Posts: 2,628
Rep:
I don't know how you removed it. If you deleted the lines they need put back in.
If you commented them out (easier to do and restore) just uncomment them.
As it was a default install this may not work but you could try chrooting in again and trying;
Code:
apt-get install --reinstall grub-pc grub-common
if the .debs are in your cache that should work. I am pretty sure they are not.
I use this script when chrooting. It works for partitions that are labeled which at least your Debian partition seems to be.
Code:
#!/bin/sh
echo "Debian"
mkdir /mnt/debian-root
mount /dev/sda5 /mnt/debian-root/
mount -o bind /proc /mnt/debian-root/proc
mount -o bind /dev /mnt/debian-root/dev
mount -o bind /dev/pts /mnt/debian-root/dev/pts
mount -o bind /sys /mnt/debian-root/sys
cp /etc/resolv.conf /mnt/debian-root/etc/resolve.conf
chroot /mnt/debian-root /bin/bash
this should give you full access. I believe this will work as is for you but if not check for typos and change the "sda" to "hda". I think that the "sda" will work.
Just copy this to the desktop of your Live Session, check the permission to make sure it is set to be executed as a program and double click on it. At least with the gnome terminal this will give you some options, just click on the one to run the bugger from terminal.
Run;
Code:
apt-get update
to make sure you have a good connection. Assuming that is good install the 2 packages.
This should install that grub on the MBR. This should get you into your Debian install.
Any further work to get grub working right should be done from there as it is more effective than doing it remotely.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.