Grub 2 lost / Can I install again,keeping my files?

Questions about Grub, UEFI,the liveCD and the installer
Forum rules
Before you post please read how to get help
Post Reply
User avatar
sdim
Level 3
Level 3
Posts: 150
Joined: Fri Mar 21, 2008 6:19 pm

Grub 2 lost / Can I install again,keeping my files?

Post by sdim »

Hi,everyone.
I had to install XP Pro on a friend's pc recently,already dual booting with Helena.
As expected,Grub 2 was ruined.I tried to fix it,but nothing happened.Nevertheless,I'm not asking about Grub 2,as I've found the guide,and I'll try to follow it.
The question is whether I can re-install Helena over the previous Helena installation,without losing the files that already exist there.
Someone suggested that I install Helena again,and when I get to the point where the installer asks about formatting the disk,select NO FORMAT.
Is this true?Can it be done? No file of the previous installation will be lost that way...?
Many thanks.
MB:MSI 770 C-45 / HD1:500 GB-->Windows / HD2:320 GB-->Mint 18 Cinnamon
CPU:AMD X4 640 3.00 GHz / RAM:4.0 GB / VGA: NVidia GeForce GT630
Biker
Level 5
Level 5
Posts: 514
Joined: Sat Apr 17, 2010 1:58 am
Location: Where my hat is

Re: Grub 2 lost / Can I install again,keeping my files?

Post by Biker »

Depends on how you set up your partitions. Normally, if you tell gparted not to format the partition, it will still delete the files in preparation for the install.

You should be able to get to the partition by booting from a Live CD and at that point, you can fix GRUB.
Linux User #384279
vincent
Level 8
Level 8
Posts: 2217
Joined: Tue Feb 09, 2010 4:10 am

Re: Grub 2 lost / Can I install again,keeping my files?

Post by vincent »

Hmmm...I've also heard of the "no format" way to install Grub, for those who don't want the hassle of installing Grub via some simple terminal commands, but I have never tried it myself and I believe it would be safer and less riskier to re-install Grub directly from the LiveCD (which I have done successfully in the past). You say you tried to fix it, but nothing happened...could you explain in more detail so we can help you out?
Debian Testing x64/LM9 Main x64/Windows 7 x64 - LG R580 laptop w/ Intel Core 2 Duo T6500 2.1 GHz, 4 GB DDR2 RAM, Nvidia Geforce G 105M, Ralink rt2860 802.11n, 300 GB WD HD 5400 rpm
User avatar
markcynt
Level 6
Level 6
Posts: 1115
Joined: Sun May 17, 2009 10:53 am
Location: Lakeland Florida

Re: Grub 2 lost / Can I install again,keeping my files?

Post by markcynt »

sdim wrote: As expected,Grub 2 was ruined.I tried to fix it,but nothing happened.
Reinstalling/restoring Grub 2 is really very simple.

Can you tell us the steps you took to restore GRUB 2 ?

A link to the guide,the portion of it you used, and a Gparted screenshot would also be helpful.
Image
P5N-E SLI, Core2Duo E6850 3GHZ X 2
2 GB DDR2 800MHZ
EVGA 8800GTS 320MB
2x320GB Hitachi
Arctic Cooling Freezer 7 Pro
User avatar
sdim
Level 3
Level 3
Posts: 150
Joined: Fri Mar 21, 2008 6:19 pm

Re: Grub 2 lost / Can I install again,keeping my files?

Post by sdim »

Many thanks for the eagerness to help,guys.
The thing is,it's not my pc,so I don't have a GParted screenshot.I can tell you,though,that I followed this tutorial:https://help.ubuntu.com/community/Grub2 ... m%20LiveCD
The message I get when I' ve tried all this (I don't know if I did it OK,though...) is "cannot find /" or something.
Is it certain that if I follow the above tutorial,Grub 2 will be OK?
MB:MSI 770 C-45 / HD1:500 GB-->Windows / HD2:320 GB-->Mint 18 Cinnamon
CPU:AMD X4 640 3.00 GHz / RAM:4.0 GB / VGA: NVidia GeForce GT630
User avatar
markcynt
Level 6
Level 6
Posts: 1115
Joined: Sun May 17, 2009 10:53 am
Location: Lakeland Florida

Re: Grub 2 lost / Can I install again,keeping my files?

Post by markcynt »

The partitioning info is needed.

Either from a Gparted screenshot or:

In a terminal

Code: Select all

sudo sfdisk -l
Please reply back with the output.
Image
P5N-E SLI, Core2Duo E6850 3GHZ X 2
2 GB DDR2 800MHZ
EVGA 8800GTS 320MB
2x320GB Hitachi
Arctic Cooling Freezer 7 Pro
Post Reply

Return to “Installation & Boot”