Cleaning your PC on a regular basis (like every 6 months or so) from accumulated dust and/or unnecessary software will work wonders. You will be amazed how much dust a PC collects when it isn't in a carefully controlled environment. And do not forget the power supply when cleaning out dust! Opening it up and remove dust from fans, cooling elements and electronics makes it last a lot longer.
Two things to watch out for, though. First, don't short out any of the electronics inside. Using a clean/new paint brush and your lungs is very safe for cleaning. Second, always check if the fan(s) still rotate smoothly. If not, fan replacement always trumps lubrication (for ball bearing based fans). Know that a fan that is not running smoothly, draws a lot more current from a power supply. A fan that is stuck, draws way more current!
Power supplies do not last forever, though. I have here several that still output 12 volt but cannot do the required 5 volt anymore, or vice versa. Your PC will behave in very strange ways if there is something wrong with the output of the power supply. Spontaneous reboots could be one of them as there is a power peak when starting up a "sleepy" PC. Before I forget, after opening and cleaning your PC always check if all cable connectors are (re-)seated properly.
In one of my older computers (Windows 2003) a somewhat similar problem occurred. Sometimes after a restart it wouldn't start because of not being able to load one of the registry hives. Replacing this registry hive with a copy (made with ERUNT) would make the computer boot again. Windows wouldn't return any error when checking the registry files or filesystem, S.M.A.R.T. reports that all is OK as well. Still, the computer behaved as if there were bad (or insufficiently functioning) blocks of the hard disk.
My solution was simple. But first a bit of background. The hard disk is divided up into several partitions and I always set up my Windows systems in such a way that the C:\ partition holds the Windows installation, but not the temporary folders, page file(s), user related files/folders and extra installed software. This way the Windows installation doesn't fragment much, leaving files and folders in a stable position on the C:\ partition. As a bonus, the C:\ partition can be quite small.
Now I took a look on that partition to see where the Windows files were located, which was around 5 GByte of the total 10GByte assigned and practically all of the files/folders were stored conveniently close together. Then I used a (freeware) partition tool
to shrink the next partition to <original size> - 5 GByte and moved the whole C:\ partition (as a whole) discarding the first 5 GByte of the hard disk.
This 7+ years old computer is doing it's job again as a LAN search engine without any hiccup. No repairs necessary even after seven power failures (or otherwise induced restarts).
Lessons I learned over time:
- Don't be cheap when buying a PC power supply (meaning: get a good brand and if for example your system requires a 400 Watt power supply, get one of 500 Watts!)
- Do maintenance on a regular basis