Recover Linux after install of Windows

1.Boot with Linux CD.
2.At : type linux rescue
3.Linux searches for Linux partitions.4.At shell prompt sh-2.05b#
Type chroot /mnt/sysImage
grub_install /dev/hda
vi /boot/grub.conf and add following lines
title Windows
rootnoverify (hdX, y)
chainloader +1
Then save the file :wq