I used this command to find a swap partition on my system:
$ swapon --show --verbose
NAME TYPE SIZE USED PRIO
/dev/zram0 partition 8G 178.9M 100
$
Does this mean that my system is currently using 178.9M of the swap partition (has swapped 178.9M of RAM)?
Shouldn’t ‘df’ show swap partitions? I don’t see anything that indicates that there is a swap partition (it’s certainly possible that I’m not understanding the output).
Is there anything in the /etc/fstab file that indicates/specifies a swap partition? Or, does the kernel create one automatically based on some internal algorithm such as using some percentage of detected RAM?
OK, many thanks, @glb I guess the kernel sets up the zram internally.
Now… the next task to do today. On each of those two external hard drives, I defined a 128GiB partition to use as swap. One such partition is enough, but the second drive is going to be for backup in case the first one fails.
I’ll work on this today… doing some reading on mkswap, swapon, swapoff, etc… and some internet pages that look promising so I can learn ‘the right way’ to do it.
This disagreement is not necessary.
It is 100% up to the user how to configure swap and everything seen online must be taken as either suggestions or anecdotal.
Nothing is ‘set in stone’ as to how swap should be configured. Every use case is different and swap should be adjusted accordingly.
I apologize if I sounded ‘argumentative’ or disagreeable. I was just trying to share my thoughts via discussion.
I agreed 100%…! Each case is different. There are many considerations. And there are many parameters in an OS environment to help one tune one’s platform for the performance profile that is most optimal or amenable to the intended use.
No problem
Each is entitled to their own opinion.
The only thing I was trying to do was de-escalate the conflicts in the opinions voiced. Each seemed firmly set and it felt there was potential for more disagreement.
We try to assist as much as possible and not be overbearing when voicing suggestions nor have hard feelings anywhere.
I’m not sure if you were referring to anything I wrote. Upon reviewing all of my comments, I don’t see anything that sounds dogmatic, argumentative, aggressive, or critical. But let me know if I had an offensive tone anywhere. It certainly wasn’t my intention.
I have to state my position or what I believe is correct or factual (call it opinion if you like) in order to precipitate a discussion (not an argument). That being said, if I state something that is wrong, then I’d like to know what is wrong with it so I can learn.
As you didn’t provide any example of your usage we had to guess. If you use 192GB of space once in a lifetime, you could survive even with 8GB of ram and else swap on hd.
I estimated what would happen on a run I did for several weeks on a configuration swapping out 128GB on nvme (not a sata ssd). The access is slower at least an order of magnitude wrt ram, considering what was doing the necessary runtime would be at least of 1 year. Certainly not worth saving the price for further 64GB.