Different Types of Router Memory: RAM, ROM, NVRAM and Flash

The router is a fundamental building block of modern business networks, providing traffic with a gateway to both the Internet and other networks.

Router acts as a gateway that enables communication between local area network and other private networks or the internet.  The major functions of the router are selecting the best path for data to be transmitted and securely transmit the data over selected path.

To perform these operations, router needs the data related to the network like routing tables, metric values etc.  Apart from this information, router must have an Operating System to perform all its functions. Router stores OS, routing information etc in its memory.

Router contains different memory components that provide storage for OS, configuration files, BOOT up instructions, Packet buffer etc. The major components of memory of router are RAM, ROM, NVRAM and Flash

RAM:

RAM, similar to RAM in a PC, is a volatile memory, which means as the router is turned off all the data present in RAM is erased. RAM is used at run time for executable operating system code, and its subsystems, routing tables, caches, running configuration, packets, and so forth. In most cases DRAM is used for its simplicity and low cost.

RAM memory is broken into two major areas:

Main processor memory where routing tables, ARP tables, running configurations are stored

Shared I/O memory is used as buffer to store the packets before processing them.

NVRAM:

Non Volatile Random Access memory is a permanent storage that stores the start up configuration files. Once the IOS (OS in Cisco routers) is loaded, the settings found in the NVRAM are applied to the router. Whenever changes are made to running configurations that are stored on RAM, NVRAM must be updated with the same settings. Or else they will be lost during shut down or restart of the router.

ROM:

ROM stands for Read Only Memory. In older Cisco models ROM was used to store IOS. Now Flash memory is used for this purpose. The router begins its booting process from the ROM. It maintains instructions for power on self test (POST), boot strap programming and basic diagnostic software. ROM chips on Cisco routers are removable and can be upgraded or replaced

Flash Memory:

Flash memory is an Erasable Programmable Read only memory (EPROM), which means the program or configuration in flash is not erased even when the system is powered off. It stores the Cisco IOS, operating system of router, and run the IOS. When a router is running, flash is set to read only mode and the contents of the flash can be upgraded by flashing the chip.