Does it only happen when you are installing software or running software on the CD drive? If so, then it sounds like your power supply will have to be replaced...as the cd drive is accessed, it drains power from the system and the computer restarts due to the drain on the power supply.