Linux operating system every year is gaining more and more fans.Among its undoubted advantages include the lack of licensing and high reliability.Nevertheless, a beginning user Linux system can often falter, leading to the need to restore it.
One of the fundamental differences between Linux and Windows is that when working with her "fallen" made to repair the system, and not to reinstall.To recovery was quick and painless, this should still take care when installing the operating system.
Before installing Linux, no matter what distribution you use, you should break up the drive correctly.Make the following partitions: / boot - the size of about 130 MB, the file system ext2./ SWAP - swap, its size is equal to twice the amount of RAM, but no more than 4 GB. / - The root partition size of 50 GB, the file system ext3, or reiserfs. / Home - the rest of the disk space, ext 3 or reiserfs.Pravilnoe partitioningIt will help you keep user data in almost any failure.
In the event that a violation of the file system for Linux, you need to restore a LiveCD recovery utility fsck.Boot the LiveCD, log in to the console as an administrator.If you do not know the path to your file system, determine his command fdisk -l.
you've found the file system - for example, its path / dev / sda1.Now start the process of its recovery command fsck -fy -t ext4 / dev / sda1.Pay attention to the specified type of file system - it must be the same as you.The -f option specifies the automatic check, the key -t - file system type, -y automatically answers yes to all the questions in the audit.
To restore the boot loader (usually Grub2) you must boot from the LiveCD.If / boot you are on a separate partition, first create the appropriate folder: sudo mkdir / mnt / boot.Then mount the partition with Linux, by entering the terminal command: sudo mount / dev / sda1 / mnt / boot.Note that in the example used previously mentioned section sda1.You it can be different.If you could not stand / boot in a separate partition, immediately mount Linux partition command: sudo mount / dev / sda1 / mnt.
Now run the installation Grub2: sudo grub-install --root-directory = / mnt / boot / dev / sda.Note that installing the boot loader on the hard drive (sda), and not on the field.After installation, reboot the system, then refresh Grub2 command sudo update-grub.
Given that there are many flavors of Linux, before restoring the system search the web for information on restoration of the name of your operating system version.The above examples are designed for widespread distribution Ubuntu and Kubuntu.