Clarification on RAM and ROM Differences in Linux Environments

BenTom07

New Member
Joined
Dec 7, 2022
Messages
6
Reaction score
0
Credits
93
Hi, I've been immersing myself in the world of Linux, and there's one aspect that I'm keen on understanding better - the differences between RAM and ROM. As I navigate through my Linux setup, a few questions have cropped up. Can someone help me comprehend the distinctions between RAM and ROM in a Linux environment?

Now, let me provide some context to what I've been exploring:
Bash:
$ free -h
              total        used        free      shared  buff/cache   available
Mem:           8.0G        3.2G        1.8G        900M        3.0G        4.0G
Swap:          2.0G        1.2G        800M

In Linux, I understand that RAM (Random Access Memory) plays a crucial role in application execution, but how does ROM (Read-Only Memory) differ in terms of functionality and use within the Linux system?

Question 1: RAM Utilization and Performance Impact With 8.0GB of RAM and 3.2GB in use, I'm curious about how the utilization of RAM affects Linux system performance. Are there Linux-specific strategies for optimizing RAM usage, particularly when running resource-intensive tasks or applications?

Question 2: Insights into Swap Space The 'Swap' entry has caught my attention, and I gather it's linked to virtual memory. Could someone elaborate on how Linux utilizes swap space and whether adjusting swap settings could positively impact the overall responsiveness of a Linux system?

Question 3: Understanding the Role of ROM in Linux.
Moving on to Read-Only Memory (ROM), I'd want to understand its purpose in Linux systems. How does ROM vary from RAM in functioning, and how is it used in Linux? Is there any specific circumstance in which a better grasp of ROM becomes crucial for enhancing Linux system performance?

Question 4: The relationship between file systems and ROM.
I've looked at Linux file systems like those mentioned here, but I'm not sure how they relate to ROM. Could someone explain how file systems relate to ROM, as well as give some insight on the function of persistent storage in Linux's Read-Only Memory?

Your insights and guidance on these questions would be immensely appreciated. I'm eager to enhance my understanding of these concepts to make the most out of my Linux experience. Thanks a bunch for your expertise!
 


Irrespective of operating system, Ram and Rom will work the same

Ram - Random access memory is a volatile storage for short term use [ and before you ask volatile means it will lose any temporary stored information once powered down]

Rom - read only memory stores information for longer term even after powering down
 
Irrespective of operating system, Ram and Rom will work the same

Ram - Random access memory is a volatile storage for short term use [ and before you ask volatile means it will lose any temporary stored information once powered down]

Rom - read only memory stores information for longer term even after powering down
This is correct. unfortunately people making phones and tablets misuse the terms. They refer ROM as the onboard storage which is not ROM it is solid state storage. You will see they say 64G ROM and 256G SSD and 8G RAM, the ROM is onboard storage and it is mislabeled by people that never took a computer science class ever. I think this is why you are asking the questions. However BrickWizard is 100% correct and use his answer. Linux people understand CS(Computer Science) and will not mislabel things. If you want to make it more clear think of a CDROM (Compact Disc Read Only Memory) you can read the CD but can't change the contents(not going into rewriteable). Hopefully I am not clouding the subject but rather putting the correct labels on things.
 
1. The linux kernel uses RAM pretty optimally. It's really only when there's a problem like an application that has a memory leak which uses up RAM that one really needs to attend to the matter. Then there are many tools to investigate the leak such as the programs: top, htop, vmstat, ps etc., which will help diagnose the issue.

2. In relation to configuring swap into a system, it's a contentious issue in modern times because computers can now have so much RAM, a swap space seems redundant. Swap space is used as virtual memory, so if one has enough RAM, the reasoning goes: why waste space on a drive with a space for swap? However, there are reasons to use a swap partition or file. This article explains:

3. ROM is "read only memory" as @APTI explains in post #3 and @Brickwizard in post #2.

4. The link in post #1 didn't get me anywhere helpful.
In relation to filesystems, the term has multiple meanings. Your query appears to use it in relation to the different forms of data storage formats for files. These include the filesystems ext2, ext3, ext4, btrfs, xfs, zfs, ntfs, fat, fat12, fat32, udf and the like. These filesystems all have their own features and are used by users to take advantage of those features. For example, if one needs a filesystem that can alter the partitions more efficiently over time, such as on a server, then one might choose btrfs or zfs. If the partitioning is likely to remain static, ext4 is sufficient and is a most common selection for linux installations.

In relation to ROM media like CDs or DVDs for example, a simpler filesystem is used like udf, since the files on the media are not going to change and so they don't benefit from the "journals" that are built into filesystems like ext4. Journals are structures within the filesystem that keep information about the file including changes in relation to each and every file like a little log for each one. This enhances the manipulation of files, moving, altering, deleting, recovering files etc.
 

Members online


Latest posts

Top