In computer networking, Computer data storage, often called storage or memory, is a technology consisting of computer components and recording media that are used to retain digital data. It is a core function and fundamental component of computers. The computer storage mainly classified in the two categories primary storage and secondary storage.
What is primary storage?
Primary storage (also known as main memory or internal memory), often referred to simply as memory, is the only one directly accessible to the CPU. The CPU continuously reads instructions stored there and executes them as required. Any data actively operated on is also stored there in uniform manner.
Types of primary storage devices
There are several types of primary storage devices; random access memory (RAM), Read-only Memory (ROM) and cache memory are common examples of primary storage devices.
- Random Access Memory(RAM)
RAM is considered the fastest storage and can achieve very high transfer rates of data. When programs or files are accessed, the data is temporarily loaded from your hard drive into your RAM where it can be smoothly accessed. However, if your RAM becomes filled, your operating system will adjust and send some of the open programs and files to your hard drive's paging file. This file is slower than your RAM because it resides on your hard drive and is one of the causes of your computer being unresponsive. For this reason, having enough RAM to handle all your work allows you to keep multiple programs open without any concerns with slowed down or unresponsive memory.
- Read-only Memory (ROM)
Read-only memory (ROM) is a type of non-volatile memory used in computers and other electronic devices. Data stored in ROM can only be modified slowly, with difficulty, or not at all, so it is mainly used to store firmware (software that is closely tied to specific hardware, and unlikely to need frequent updates) or application software in plug-in cartridges.
- Cache Memory
Cache memory is generally joined onto the motherboard and installed on the core processor or main RAM. It provides quicker access by storing an instance of the programs or data regularly accessed by the processor. With the information in cache memory, the processor does not need to go to RAM or the hard drive to get the data, it already has an instance of it in its memory. An example of this is using the Internet and a web browser. The cache will store the website's HTML, images and other information so that a page will load more rapidly after its first visit.
- Other types of primary storage
In addition to the above three types, there are some others, programmable read-only memory(PROM), Erasable programmable read-only memory(EPROM), registers and etc.
What is secondary storage?
Secondary storage (also known as external memory or auxiliary storage), differs from primary storage in that it is not directly accessible by the CPU. The computer usually uses its input/output channels to access secondary storage and transfers the desired data using intermediate area in primary storage. Secondary storage does not lose the data when the device is powered down—it is non-volatile. Per unit, it is typically also two orders of magnitude less expensive than primary storage. Modern computer systems typically have two orders of magnitude more secondary storage than primary storage and data are kept for a longer time there.
Types of secondary storage devices
The common hard drive and optical drive are both secondary storage devices. In addition, magnetic tapes, floppy disk, USB drives, paper tape, punched cards and so on.
What are the differences between primary and secondary storage?
There are some differences between primary and secondary storage, the following table shows the differences.