LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices

Reply
 
Search this Thread
Old 12-01-2009, 08:59 AM   #16
RazorV
LQ Newbie
 
Registered: Nov 2009
Posts: 10

Original Poster
Rep: Reputation: 0

Quote:
Originally Posted by tommcd View Post
I have not heard of Vista rewriting the MBR every time it boots before. Do you have some antivirus program or security app installed in Vista that protects the MBR or something like that?
Yes in Vista I have TrendMicro Worry Free Business Security Installed. I thought this may be the issue as TM may be monitoring the MBR and if it sees a change it somehow tries to fix it -leaving me with a screwed up GRUB install that just consistently reboots.

Thanks for all the links for help. I am getting an SSD 250GB drive for my notebook that I will install as the Primary Drive with Ubuntu on it. Before I install that drive I will access Vista and try to follow the steps in the links above and see I can fix GRUB. If not then I will continue to install Ubuntu on the SSD drive that I will make Primay in my HP Notebook.

thanks again.

Greg
 
Old 12-01-2009, 09:04 AM   #17
RazorV
LQ Newbie
 
Registered: Nov 2009
Posts: 10

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by ronlau9 View Post
What you posted is that really you're GRUB.CFG ?
To answer your Q, I don't know. I do know that what I posted was from a file called GRUB in the /etc/default/ folders/directory. As far as I can see that file, "Grub" does not have an extension on it.

Would there be another location that would have a Grub.cfg file that I should be looking for or to edit?

thanks,
Greg
 
Old 12-01-2009, 10:01 AM   #18
pepe_le_piu
LQ Newbie
 
Registered: Nov 2009
Distribution: Karmic Koala
Posts: 4

Rep: Reputation: 0
Hi Greg.

Here's my attempt at customizing the instructions to your situation:

Quote:
Originally Posted by RazorV View Post
So in response to this statement in the instructions:

* Now, you need to remember which device listed is your linux distribution, for reference, /dev/sda1 will be used. Now we need to mount the filesystem to /mnt

$ sudo mount /dev/sda1 /mnt"



What would I type?
Use this:
Code:
$ sudo mount /dev/sdb1 /mnt
The command mounts sdb1 to the file system. The "sdb1" notation loosely means "hard disk B, partition 1", which is where you have Ubuntu installed.

Quote:
Originally Posted by RazorV View Post
Then, the instructions say:
* Now mount the rest of your devices

$ sudo mount --bind /dev /mnt/dev



What other devices would I mount according to my fdisk output above?
Use this:
Code:
$ sudo mount --bind /dev /mnt/dev
This command basically mounts the other partitions to the filesystem, so you don't have to modify it.

Quote:
Originally Posted by RazorV View Post
* Now you need to edit the /etc/default/grub file to fit your system

$ nano /etc/default/grub
As far as I can tell, this is only in case you want to make any changes to the way the GRUB 2 menu is displayed. In my particular situation, I have never had to change it.


Note that this procedure will only repair GRUB 2, but won't fix whatever is screwing around with it in the first place, so chances are you will have to repeat this procedure again in the future. Apparently it is a detected bug reported here:https://bugs.launchpad.net/ubuntu/+s...b2/+bug/441941

To make my life simpler I made it a habit of carrying around a USB stick with a bootable liveCD, just in case the boot record got screwed up again. The instructions I used to create a USB LiveCD are here:http://www.pendrivelinux.com/create-...sb-in-windows/

I'm also experimenting with a different setup, which I've described here:http://ubuntuforums.org/showthread.php?t=1341624

However, I still haven't tested it for extended periods, so I don't know how well it works yet.

Hope this helps.
 
Old 12-01-2009, 10:04 AM   #19
pepe_le_piu
LQ Newbie
 
Registered: Nov 2009
Distribution: Karmic Koala
Posts: 4

Rep: Reputation: 0
Quote:
Originally Posted by tommcd View Post
I have not heard of Vista rewriting the MBR every time it boots before. Do you have some antivirus program or security app installed in Vista that protects the MBR or something like that?
Hehehehe, ok. maybe I exaggerated a bit. It doesn't re-write the MBR EVERY time, but it does after running vista over an extended period (3-4 hours).

Last edited by pepe_le_piu; 12-01-2009 at 10:07 AM.
 
Old 12-01-2009, 02:48 PM   #20
RazorV
LQ Newbie
 
Registered: Nov 2009
Posts: 10

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by pepe_le_piu View Post
Hehehehe, ok. maybe I exaggerated a bit. It doesn't re-write the MBR EVERY time, but it does after running vista over an extended period (3-4 hours).
When I do decide to boot into Vista again, I will remove Trend Micro completely and then reboot Vista. I know GRUB will be trashed then, but if I can fix/repair Grub then I'll be fine. If not I will continue to install a new version of Ubuntu on my SSD drive and just go COLD TURKEY Ubuntu all the way.

I haven't missed Vista very much. However, I do miss Adobe Acrobat PRO and Adobe Indesign. I tried to get Acrobat Pro running under Wine but I get a error at the end of the install about MSCEXIE (or something like that). Acrobat will run but then just quits randomly. I'll put more effort into it after I figure out Grub.

Thanks to all and I'll report back in a few days or 1-2 weeks.
 
Old 12-02-2009, 04:54 AM   #21
tommcd
Senior Member
 
Registered: Jun 2006
Location: Philadelphia PA USA
Distribution: Lubuntu, Slackware
Posts: 2,229

Rep: Reputation: 286Reputation: 286Reputation: 286
Quote:
Originally Posted by RazorV View Post
To answer your Q, I don't know. I do know that what I posted was from a file called GRUB in the /etc/default/ folders/directory. As far as I can see that file, "Grub" does not have an extension on it.
Would there be another location that would have a Grub.cfg file that I should be looking for or to edit?
The grub.cfg file is located in /boot/grub. So the path to it is: /boot/grub/grub.cfg.
This file is not supposed to be edited like the old menu.lst. So grub.cfg is made read-only whenever update-grub is run:
https://wiki.ubuntu.com/Grub2#grub.c...grub/grub.cfg)
The /etc/default/grub file is the one you can edit to change the behavior of grub2:
https://wiki.ubuntu.com/Grub2#grub (/etc/default/grub)
The files in /etc/grub.d/ manage the options that you see on the grub2 menu when the computer boots. The /etc/grub.d/ directory is also where you place custom rules for booting an OS if you need them:
https://wiki.ubuntu.com/Grub2#/etc/grub.d/ (folder)
This takes some getting used to, as it is a bit more complicated than grub-legacy. I am still trying to get up to speed on grub2 myself.

Last edited by tommcd; 12-02-2009 at 04:57 AM.
 
Old 12-02-2009, 05:50 AM   #22
aus9
Guru
 
Registered: Oct 2003
Posts: 5,056

Rep: Reputation: Disabled
hi

as you have 2 drives you have about 3 main options.
Assuming ms=windows has an error ...wt? lol

Option 1) Change bios boot order to drive 2....which I will calll the linux hd.....and remove from bios option the ms drive which currently has the alleged grub2 in it and chainloades to ms

then boot the live cd....and run command on from ubuntuo

Code:
sudo upgrade-from-grub-legacy
...the response should show only one drive which from bios order change is now /dev/sda...hit space bar to select and allow grub2 into that mbr.
Now remember...grub2 is still in mbr of drive1 but it now on drive2 as well...ok?

to boot linux from now on....change bios boot order to linux hd

/etc/fstab should not need changing if UUIDs are in it.
/boot/grub/grub.cfg should also have UUIDs so no changed needed.

YMMV

Now still in option (1)...reset bios to ms drive and disable linux drive.
use windows dvd to restore = recovery mode....fixmbr.

this overwrites the mbr of drive1....deliberately and linux mbr is gone.

To boot ms...change bios boot order to drive1
to boot linux change bios boot order to drive2

Option (2)
Keep existing boot order

allow ms to fixmbr of its first drive....loosing linux.

use a linux live cd to install linux grub2 into the "root" of the boot partition....and edit ms to chainload linux.

my legacy style signature has info on this.

Then you no longer have to be scared of overwrites.

Option (3) is messy to explain but bear with me

a) to boot ms....you first your windows recovery to fixmbr for mbr drive 1..same as option (2)

b) put grub2 into mbr of drive2 ...a bit like option (1) but no bios boot order change

c) when ms starts....hopefully there is F12 key or F8? that allows you to change hard drive order?

so to boot ms....no pressing F keys
to boot linux press whatever F (number) needed

2) The explanation of alleged ms bootloader overwrite may be due to your computer manufacturer....using a recovery partiton.

When changes are made no consistent with how it first was active....the sytem will revert (restore) and older mbr
 
  


Reply

Tags
grub2, mbr


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Ultra Noob-stuck on Login screen after first reboot-Fedora9 isaliveart Linux - Newbie 26 09-03-2008 04:21 PM
correct grub.conf, reboot and cannot get grub prompt... sportivo888 Linux - Newbie 1 12-10-2007 11:47 PM
FC3 - Computer stuck in continual reboot loop brandor Fedora 1 11-15-2004 09:47 AM


All times are GMT -5. The time now is 08:59 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration