This article only for a dual system that does not have separate boot partitions with software like EASYBCD, after reinstalling Win7, because Win7 covers Ubuntu grub, which causes Ubuntu to fail to start.
(1) Regardless of the method used, the first need to determine the original installation of Ubuntu/partition, and originally installed Ubuntu/boot partition, assuming SDA7 root sda8 (if there are multiple disks, there may be sdb ...) )
(2) Start Ubuntu with Ubuntu live CD and start the terminal:
Sudo-i
Mount/dev/sda7/mnt
Mount/dev/sda8/mnt/boot (if there is no/boot separate partition, this step skips)
Grub-install--ROOT-DIRECTORY=/MNT/DEV/SDA
Then you should see ... with no error hint, meaning the installation was successful
(3) Restart, hard drive system, you can see the grub of Ubuntu.
Fix Ubuntu grub after reinstalling Windows on a Windows and Ubuntu-installed machine