 Menggunakan dua sistem operasi—Windows dan Ubuntu Linux—dalam sebuah
komputer memang sangat menyenangkan. Selain tetap bisa menggunakan
Windows, Anda juga bisa belajar menggunakan Ubuntu Linux secara
bertahap.
Komputer dengan sistem dual boot ini akan menampilkan sebuah boot
loader, yaitu pilihan menu sistem operasi yang ingin digunakan, apakah
Windows atau Ubuntu Linux. Namun boot loader ini akan hilang, jika
Windows terpaksa diinstall ulang karena suatu sebab tertentu. Jadi
bagaimana? Haruskah Ubuntu
diinstall ulang?
Anda tidak perlu repot menginstall ulang Ubuntu, tapi cukup
merestore/memulihkan bootloader-nya saja.
Berikut ini cara mengembalikan bootloader pada Ubuntu 9.10
yang saya kutip ditulis ulang dari blog mas Iqbal.
- Nyalakan PC/laptop dan booting dari LiveCD Ubuntu atau flashdisk
(yang sudah terisi OS Ubuntu). Cara mengubah urutan booting (boot
priority) pada BIOS bisa dilihat lagi di
sini.
- Masukkan LiveCD Ubuntu ke dalam CD-ROM (atau flashdisk, tergantung
mana yang ingin digunakan).
- Pilih Try Ubuntu without any changes to your computer.
Tunggu sampai Ubuntu tampil dengan sempurna.
- Setelah berhasil masuk ke Ubuntu, buka terminal (klik Applications
> Accessories > Terminal, atau tekan kombinasi tombol Ctrl+Alt+F2).
- Ketik sudo fdisk -l untuk
melihat partisi yang ada. Hasilnya muncul tulisan seperti di bawah ini:
Disk /dev/sda: 120.0 GB,
120034123776 bytes
255 heads, 63 sectors/track, 14593 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xb196b196 Device Boot Start
End Blocks Id System
/dev/sda1 * 1 4570 36703768+ 7 HPFS/NTFS
Partition 1 does not end on cylinder boundary.
/dev/sda2 4570 14593 80514441+ f W95 Ext’d (LBA)
Partition 2 does not end on cylinder boundary.
/dev/sda5 4570 10394 46781248+ 7 HPFS/NTFS
/dev/sda6 10395 10643 2000061 82 Linux swap /
Solaris
/dev/sda7 10644 12108
11767581 83 Linux
/dev/sda8 12109 14593 19960731 83 Linux Disk /dev/sdb: 8088 MB,
8088715264 bytes
249 heads, 62 sectors/track, 1023 cylinders
Units = cylinders of 15438 * 512 = 7904256 bytes
Disk identifier: 0x0005bb5f Device Boot Start
End Blocks Id System
/dev/sdb1 * 1 1023 7896506 b W95 FAT32
Partition 1 has different physical/logical endings:
phys=(1023, 248, 62) logical=(1022, 248, 62) - Sekarang ketik sudo mount -t ext4 /dev/sda7 /mnt/. CATATAN: sda7 adalah
nama partisi Linux di komputer saya. Lihat tulisan yang dicetak
tebal pada langkah nomor 5 di atas. Anda bisa menggantinya
sesuai dengan nama partisi Linux di komputer Anda.
- Ketik sudo mount -t proc proc /mnt/proc/
- Ketik sudo mount -t sysfs sys /mnt/sys/
- Ketik sudo mount -o bind /dev/ /mnt/dev/
- Ketik sudo chroot /mnt/ /bin/bash
- Ketik grub-install /dev/sda. Hasilnya muncul
tulisan seperti di bawah ini:
Installation finished. No error
reported.
This is the contents of the device map /boot/grub/device.map.
Check if this is correct or not. If any of the lines is incorrect,
fix it and re-run the script `grub-install’. (hd0) /dev/sda
(hd1) /dev/sdb - Ketik grub-install /dev/sda7. Hasilnya muncul pesan
seperti ini:
grub-setup: warn: Attempting to
install GRUB to a partition instead of the MBR. This is a BAD idea.
grub-setup: warn: Embedding is not possible. GRUB can only be installed
in this setup by using blocklists. However, blocklists are UNRELIABLE
and its use is discouraged.
Installation finished. No error reported.
This is the contents of the device map /boot/grub/device.map.
Check if this is correct or not. If any of the lines is incorrect,
fix it and re-run the script `grub-install’. (hd0) /dev/sda
(hd1) /dev/sdb - UPDATE (20 Nov 2009): ketik update-grub.
Hasilnya seperti di bawah ini:
Generating grub.cfg …
Found linux image: /boot/vmlinuz-2.6.31-14-generic
Found initrd image: /boot/initrd.img-2.6.31-14-generic
Found memtest86+ image: /boot/memtest86+.bin
Found Microsoft Windows XP Professional on /dev/sda1
done PS: Tip ini penting untuk mencegah kasus Windows yang tidak bisa booting dan selalu muncul
pesan error: no such device, meski tampil (dan bisa
dipilih) pada menu bootloader. Lihat posting soal error: no such device selengkapnya. - Sekarang ketik reboot untuk merestart komputer.
Hasilnya, bootloader akan kembali seperti semula.
- Jangan lupa mengeluarkan LiveCD Ubuntu atau Flashdisk (berisi OS
Ubuntu) yang dipakai untuk booting tadi. Jika tidak, komputer akan
booting lagi dari CD/Flashdisk.
Selamat mencoba!
|