Try this:Restart in Safe Mode.
Goto your Device manager.
Delete ALL cd-rom drives that are present.
shut down the system, Unplug it from power and open the case.
First, check the jumpers carefully:
Hard drive should be set to Master.
CD-Rom drive should be set to Slave.
DO NOT USE CABLE SELECT!
There are only a few (Server) boards that use CableSelect.
There are also special cables needed for this.
Restart and check if it will be there again.
If not, Shut down again and unplug it from power.
Take the IDE cable from the CD-Rom drive.
If an extra IDE cable present, connect it to the Secondairy IDE on your Mainboard, Jumper your CD-Rom drive as Master (If that position is free afcourse!) and conect it to the second IDE cable.
Restart your system and see if it will do the trick.
If all of this does not work, Your CD-Rom drive has failed.