Welcome to the forum thousands of useful things .Learn the truth about the world around youKnow the truth about the worldWelcome to the forum of the wise and intelligent people
Welcome to the forum thousands of useful things.
Learn the truth about the world around you
Know the truth about the world
Welcome to the forum of the wise and intelligent people


Ubuntologiya:Ubuntu Linux Ubuntu Lesson No. 1 loader Grub -2

Sunrise

The world around us. Find out the truth
 
HomeПорталLatest imagesSearchRegisterLog in



 

 Ubuntologiya:Ubuntu Linux Ubuntu Lesson No. 1 loader Grub -2

Go down 
AuthorMessage
Flight in a dream




Сообщения : 13
Дата регистрации : 2013-10-15

Ubuntologiya:Ubuntu Linux    Ubuntu Lesson No. 1 loader Grub -2 Empty
PostSubject: Ubuntologiya:Ubuntu Linux Ubuntu Lesson No. 1 loader Grub -2   Ubuntologiya:Ubuntu Linux    Ubuntu Lesson No. 1 loader Grub -2 Icon_minitimeMon Oct 21, 2013 3:47 am

      Ubuntologiya:Ubuntu Linux    Ubuntu Lesson No. 1 loader Grub -2    




     
Grub2 - recovery

Method 1 (simple as that)
This is the fastest and easiest way to restore the damaged / broken / not installed correctly / jammed installing windows / call it what you want files GRUB2. For this we need:
a) Terminal - 1 piece.
b) Knowledge of the disks on which we find the section with the installed system.
Our actions. We boot from LiveCD, primontiruem our ill-fated section and then copy the necessary files from the LiveCD.
 

Ubuntologiya:Ubuntu Linux    Ubuntu Lesson No. 1 loader Grub -2 9475110

     
2. Determine which of our drives installed Ubuntu. To do this, open the Terminal (Applications, Accessories, Terminal) and run the command
 


Quote :
 sudo fdisk -l
As a result, you will see something similar to what I have:
Ubuntologiya:Ubuntu Linux    Ubuntu Lesson No. 1 loader Grub -2 9023911


     
Then look for the line with the recording Linux, this is - drive and partition where you installed ubuntu. In this case, I have it sda5 you can be otherwise.
3. So, we decided to drive, now we have to mount it
 


Quote :


sudo mount /dev/sdXY /mnt
     
* note: sdXY - where X - disk in the system (sda, sdb, sdc, etc.) and Y - partition (first partition - 1, the second 2 and so on).
Example: sudo mount / dev/sda1 / mnt
** note: if you have a / boot partition submitted separately, then your team should look like this: first, create a folder sudo mkdir / mnt / boot, then install sudo mount / dev/sda1 / mnt / boot, do not forget to take this into account when performing the following commands.
4. The following command will launch the installation of GRUB2.
 


Quote :

sudo grub-install --root-directory=/mnt/ /dev/sdX
     
Example: sudo grub-install - root-directory = / mnt / / dev / sda
* Note: Please note that GRUB2 is installed on the device (physical disk).
5. reboot
6. Do not forget to update the GRUB2 menu command
 



Quote :

sudo update-grub
     
All simple))
 
Back to top Go down
Flight in a dream




Сообщения : 13
Дата регистрации : 2013-10-15

Ubuntologiya:Ubuntu Linux    Ubuntu Lesson No. 1 loader Grub -2 Empty
PostSubject: Re: Ubuntologiya:Ubuntu Linux Ubuntu Lesson No. 1 loader Grub -2   Ubuntologiya:Ubuntu Linux    Ubuntu Lesson No. 1 loader Grub -2 Icon_minitimeMon Oct 21, 2013 4:56 am

Method 2 - Copy the files from an already installed GRUB2 section
What is this way ? This implies a way that GRUB2 installed correctly , but not in that section , which should be (as an example , Ubuntu second system is installed near Windows, Windows and is on the same disk (sda), and on the other Ubuntu (sdb) ) . Therefore , we will copy the files from the / boot / grub on our chosen drive and MBR.
1. Boot the LiveCD and select " Run Ubuntu without installing "
2 . Mount the partition with an installed Ubuntu. To do this , click "Places", click on the desired category to us (in this case, we have chosen the partition to automatically mount the / media).

Ubuntologiya:Ubuntu Linux    Ubuntu Lesson No. 1 loader Grub -2 6239010


   3. Unit is mounted. Now reinstall the GRUB2. Here's how:



Quote :
 sudo grub-setup -d /media/XXXX/boot/grub /dev/sdX  
 
* Note: XXXX - your UUID or volume label, sdX - where X - disk in the system which we will overwrite GRUB2 (sda, sdb, sdc, etc.).
Rewrite UUID extremely inconvenient, so you can simplify your life follows. In the menu "Places" choose our drive and then left click the icon with the pencil, select and copy (CTRL-SHIFT) address in the address bar, and paste (CTRL-SHIFT-V) in the Terminal.


Quote :

example

Quote :

sudo grub-setup -d /media/7848138a-41a0-4eba-8aed-d1b625ac8759/boot/grub /dev/sda
 
If you are executing this command will give an error "error: Cannot open / boot / grub / device.map", in this case, you should add the option-m and set the path to the file device.map


Quote :

sudo grub-setup -d /media/XXXXX/boot/grub -m /media/XXXXX/boot/grub/device.map /dev/sdX
example
Quote :

sudo grub-setup -d /media/7848138a-41a0-4eba-8aed-d1b625ac8759/boot/grub -m /media/7848138a-41a0-4eba-8aed-d1b625ac8759/boot/grub/device.map /dev/sda
 

If you're kicked back an error "error: Cannot open / boot / grub / device.map", do not despair, now you just need to restart your computer.
4. If you did not restart the computer, then you should do so now.
5. After the reboot, do not forget to update GRUB2 command sudo update-grub
Back to top Go down
Flight in a dream




Сообщения : 13
Дата регистрации : 2013-10-15

Ubuntologiya:Ubuntu Linux    Ubuntu Lesson No. 1 loader Grub -2 Empty
PostSubject: Re: Ubuntologiya:Ubuntu Linux Ubuntu Lesson No. 1 loader Grub -2   Ubuntologiya:Ubuntu Linux    Ubuntu Lesson No. 1 loader Grub -2 Icon_minitimeMon Oct 21, 2013 5:04 am

Method 3 - CHROOT
I will not dwell on the notes that such a chroot, and what it eats. You can find this much information on the Internet. We proceed directly to those actions that we need to do. So.
1. Boot the LiveCD and select "Run Ubuntu without installing"
2. Open the Terminal (Applications, Accessories, Terminal).
3. Determine which of our drives installed Ubuntu.


Quote :
sudo fdisk -l

4. Mount the partition with Ubuntu installed



Quote :
sudo mount /dev/sdXY /mnt

Example: sudo mount / dev/sda1 / mnt
* note: sdXY - where X - disk in the system (sda, sdb, sdc, etc.) and Y - section (Section - 1, the second 2 and so on).
** note: if you have a / boot partition submitted separately, then your team should look like this: first, create a folder sudo mkdir / mnt / boot, then install sudo mount / dev/sda1 / mnt / boot, do not forget to take this into account when performing the following commands.


5. Mount the disk:




Quote :
sudo mount --bind /dev/ /mnt/dev
Back to top Go down
Sponsored content





Ubuntologiya:Ubuntu Linux    Ubuntu Lesson No. 1 loader Grub -2 Empty
PostSubject: Re: Ubuntologiya:Ubuntu Linux Ubuntu Lesson No. 1 loader Grub -2   Ubuntologiya:Ubuntu Linux    Ubuntu Lesson No. 1 loader Grub -2 Icon_minitime

Back to top Go down
 
Ubuntologiya:Ubuntu Linux Ubuntu Lesson No. 1 loader Grub -2
Back to top 
Page 1 of 1

Permissions in this forum:You cannot reply to topics in this forum
Sunrise :: Computer technology and software, the global network. :: Computer technology and software, the global network.-
Jump to: