LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-27-2008, 02:43 PM   #1
bettyhills
LQ Newbie
 
Registered: Jun 2007
Location: Maryland
Distribution: Ubuntu II 8.10
Posts: 22

Rep: Reputation: 15
How to save the GRUB loader to the Linux boot partition?


How to save the GRUB loader to the Linux boot partition?

I am backing up my Dell AMD64 Dual Boot WinXP Home/UbuntuGG PC using Acronis True Image 9.0 to an external drive. The instructions caution that later restoring will overwrite the MBR with an Acronis boot code, thus destroying the GRUB startup sequence.

Can anyone tell me how to save the GRUB loader to the Linux root (boot) or boot partition record?
 
Old 05-27-2008, 04:06 PM   #2
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Arch/XFCE
Posts: 17,802

Rep: Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738
Using dd, you can save a copy of the GRUB code to a file or to a zone of the raw disk. Be aware, however, that GRUB gets "hard-coded" to point to the location of its files in /boot/grub. If this relationship changes, then the relocated code will not work.

To copy the MBR portion of GRUB to a file:
(assumes SCSI/SATA drives, GRUB on first drive.)
dd if=/dev/sda of=/path/to/grubfile bs=446 count=1

"/path/to/grubfile" could be--eg--/home/username/grubfile

To copy to the boot sector of a partition (#2):
dd if=/dev/sda of=/dev/sda1 bs=446 count=1

See the booting link below for more info.
 
  


Reply


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
How to change from grub boot loader to lilo boot loader linuxjamil Linux - Software 1 05-27-2008 02:47 PM
Two hard disks - dual boot ( XP - Linux ) using microsoft boot loader, not grub cristy88 Linux - General 2 12-17-2007 07:26 PM
deleted linux partition adn the boot loader was deleted also,now i have only gnu grub boris199 Linux - Laptop and Netbook 2 01-29-2005 05:53 PM
Grub boot loader menu shows two linux boot options pramos Linux - Newbie 3 09-13-2004 12:40 AM


All times are GMT -5. The time now is 02:41 PM.

Main Menu
Advertisement
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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration