There are a couple of ways to try and reset the password. The first thing you can try is to remove the CMOS battery and leave it out for about 20 min and then put it back in. This will clear all the settings and should clear the password too. You will most likely have to reset the system time etc in the BIOS.
Another option is to see if there is a generic password for your brand of computer that you can use to get into the settings and clear the password. Many companies use a standard password just in case something like this happens.
If you can find the motherboard manual then there might be a jumper you can short to clear the BIOS password.
Automatic reboots can be caused by several different things and are hard to diagnose. One thing you can try is turn off the automatic reboot option under the recovery options for your computer. This will make it so your computer won’t reboot on errors so you can see any problems. Go to to System in Control Panel and go to Advanced System Settings. Then click on the Advanced tab and then the Startup and Recovery Settings button and uncheck the box that says Automatically restart. The next time you reboot, it should stop on the Blue Screen so you can read what it says.
The next thing to look at is to see if you have installed any new software or drivers or even any new hardware on your system. Faulty drivers can cause reboots as well. If so you may want to uninstall the software or remove the new hardware and see what happens.
There can possibly be a problem with your motherboard's< a href="/support-categories/hardware/487-what-is-the-bios" target="blank">BIOS. You may want to do a BIOS update if there is one available. Just be really careful to do it correctly because you can ruin your motherboard if you don't.
It sounds as though your motherboard CMOS battery is dying. When you are prompted to go into setup at boot up it usually means there is a configuration problem. One thing you can try is to go into setup and check the date and time in the BIOS and change it if it's wrong. Then save and exit and see if that solves your problem.
Once you fix the configuration problem in the BIOS then that message should go away. If your time continues to be off then you should change the CMOS battery. They are only a couple of dollars and you can get them at an electronics store or even Amazon. Just be sure to bring the old one in to make sure you get the right one.
If the fan on the CPU is not running then that is very bad. Processors run very hot and will overheat quickly if they are not cooled. If its shutting down then its most likely a case of it over heating. You can go into the BIOS and see if you have anything set to shut off the computer at a certain temperature. This setting is to prevent the computer from being damaged from overheating. You can also let it run in the BIOS and watch the displayed temperature and see if it keeps rising or use a program like Speccy within Windows
I would get that fan replaced before using the computer again otherwise you might ruin your processor. When they go bad they will either start giving you problems in Windows with lots of errors or the computer wont boot up at all.