Synopsis
After reinstalling windows in a dual boot machine (2 operating systems). Windows deletes the default boot loader for linux (i.e grub). The result is that you lose access your linux os.Solution
- You will need your Ubuntu or Mint or PCLinux OS (whichever version of linux or distro of linux with grub) live cd.
- Boot from the live cd
- Go to terminal and type: sudo grub
- Inside grub, type : find /boot/grub/stage1 {This finds the partition that contains the grub boot loader files. and returns its address}
- The result often is in the format : hd0,1
- Next type : root (hd*,*) (note: replace the * with the disk and partition number respectively. e.g for this case type root (hd0,1))
- Finally type : setup (hd*){note: replace * with the disk number e.g for this case type setup (hd0)}
In Brief:
- sudo grub
- find /boot/grub/stage1
- root (hd0,1)
- setup (hd0)
i will upload pictures to demonstrate this later