Unusual boot up problems

Hi All, Specs of system in signature. Once every week or so my PC fails to finish booting up. It fails just before it says Loading Grub 5. I get a cursor at the top. Keyboard or mouse do not work. All I can do is a reboot and its works very well.
How can I find out what is causing this?
How can I find out what is causing this?