Sunday, November 10, 2013

Grub2 bootloader ျပန္ထည့္နည္း

Linux beginner user ေတာ္ေတာ္မ်ားမ်ားမွာျဖစ္တတ္တဲ့ျပသာနာက Grub ျပသာနာပါပဲ ။Linux တင္ထားပီး ေနာက္မွ Window ထပ္လာတင္ရင္ OS တစ္ခုမွ boot တက္ေတာ့မွာမဟုတ္ပါဘူး ။ အဲ့လိုမျဖစ္ခ်င္ရင္ေတာ့ တင္တုန္းက ေသေသခ်ာခ်ာေလး partation ပိုင္းဖုိ႔လိုပါတယ္ ။ဥပမာ Windows တင္ထားပီး Linux OS ကိုထပ္တင္မယ္ဆိုရင္ linux တြက္ partation ပိုင္းတဲ့ခ်ိန္မွာ boot တြက္မပိုင္းေပးလည္းရပါတယ္။ ဘာျဖစ္လည္းဆိုေတာ့ boot တက္ဖုိ႔ Windows က boot loader နဲ႔ တက္လို႔ရပါတယ္ ။ ခင္ဗ်ားလည္း beginner ဆိုရင္ေတာ့ ၾကံဳရမွာပါ

(ဆုေတာင္းေပးတာခ္ခ္ ) ။ ဒီေန႔ကြ်န္ေတာ္ေျပာျပမွာကေတာ့ boot မတက္ရင္
ျပန္တက္လာေအာင္လုပ္တဲ့နည္းေလးပါ ။ကြ်န္ေတာ္လည္း beginner တစ္ေယာက္ပါပဲခုထိ ။ၾကံဳေနရတဲ့ျပသာနာေတြနဲ႔ ေျဖရွင္းပီးေအာင္ျမင္လုိ႔ ျပန္မွ်ေ၀ပါတယ္ ။

ေအာက္ကတစ္ဆင့္ခ်င္းဆီ လိုက္လုပ္လုိက္ပါ။ျပန္တက္လာပါလိမ့္မယ္။


၁.Boot from an Ubuntu Live CD or Live USB
၂.Once up and running, Open a Terminal
၃.Type sudo su (press enter after typing each command)
၄.Type fdisk -l
၅.Note which device contains your Linux partition (IE: /dev/sda1)
၆.Type mount /dev/sdx# /mnt (replacing x# with your actual device and partition number)
၇.Type mount --bind /dev /mnt/dev
၈.Type mount --bind /proc /mnt/proc
၉.Type cp /etc/resolv.conf /mnt/etc/resolv.conf
၁၀.Type chroot /mnt
၁၁.Type grub-install --recheck /dev/sdx (replacing x with your actual device)
၁၂.Type reboot (to reboot your PC)

Make sure to remove your Live USB or CD. Upon reboot you should be presented with a GRUB2 menu. However, Windows is missing. Now, I show you how to fix that.
Making GRUB 2 detect Windows Installs:
Proceed to boot into your Linux environment.
Open a terminal and type sudo update-grub (enter your root password when prompted)

If all went well, grub should have updated it’s menu entries to reflect what it detected. Including existing Windows partitions.

အိုင္တီပင္လံုသား

0 comments:

Post a Comment