As said in the title, what data in RAM is lost and what isn't when powering down?

I am just curious. I know RAM stands for Random Access Memory, is volatile (needs power to store data), and has higher read/write speeds than non-volatile memory (i.e. HDD, SSD).

I know if there is not much available RAM that can be written, I can empty RAM space by restarting, after restarting everything in RAM seems to be lost, the space they occupy is freed up, so the space becomes usable again.

However it is definitely not true that all data is lost; As far as I know, the computer's clock won't be reset by rebooting, it would still display the correct time, even after I shutdown completely and remove the power cable.

And the fact it is still bootable after shutting down, means the boot code used to boot the operating system is still in the RAM, otherwise it simply won't boot.

So what data is lost and what data remains in primary memory when you shut down the computer?

  • "I know RAM ... is volatile" -- Incorrect, you're describing Dynamic RAM, which is a semiconductor implementation for RAM. The concept of RAM in a computer does not have the attribute of volatility. I've used computers that, when powered off and then powered back up, the (ferrite core) RAM retained its data. Since you didn't know or care about the prior RAM contents before turnoff, the OS would be booted. Only the bootstrap program would be assumed to be intact in RAM. – sawdust Jan 8 at 21:26

Most of this is incorrect.

When power is lost, data stored in RAM will be lost as well within seconds. The current time is stored in the RTC, which is powered by its own battery. The boot code is partially stored in dedicated flash memory (Firmware/BIOS/UEFI) and on your HDD/SSD (bootloader), etc and not in RAM.

  • "When power is lost, data stored in RAM will be lost" -- You're repeating the same faulty syllogism: RAM is (commonly) implemented by Dynamic RAM; DRAM is volatile; therefore RAM is volatile. – sawdust Jan 8 at 21:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.