5 ms·
This is why having swap even when you have plenty of memory for normal usage is good. Swap on an SSD isn't even that slow.
by buckle8017 1y ago
This is why having swap even when you have plenty of memory for normal usage is good.
Swap on an SSD isn't even that slow.
- pkulak 1y agoYou know what, your comment actually reminds me that this happened when I also had a bug in my configuration that was causing me to not actually use swap. I assume running out of tmpfs uses swap like anything else? I might give tmpfs another try.
- AdieuToLogic 1y ago> I assume running out of tmpfs uses swap like anything else? This is not the case. RAM-based file system capacities are unrelated to process memory usage, of which "swap space" is for the latter.
- pkulak 1y agoInteresting, thank you. I stand by my original point, downvotes be damned.
- AdieuToLogic 1y ago> Interesting, thank you. Glad to help out. Here[0] is more information regarding Linux swap space as it relates to processes and the VMM subsystem. > I stand by my original point, downvotes be damned. :-D 0 - https://phoenixnap.com/kb/swap-space https://phoenixnap.com/kb/swap-space
- AdieuToLogic 1y agoI was wrong in my unconditional assertion that `tmpfs` does not use swap. It can, depending on conditions described here[0]. What I was thinking about is `ramfs`, which does not use/support swap and has other limitations not present in `tmpfs`. Sorry for confusing the topic. 0 - https://www.kernel.org/doc/html/latest/filesystems/tmpfs.html https://www.kernel.org/doc/html/latest/filesystems/tmpfs.htm...
- tatref 1y agoThat's why on some configurations (RHEL 7 I think), journald will happily fill up your ram via /run/
- AdieuToLogic 1y ago> That's why on some configurations (RHEL 7 I think), journald will happily fill up your ram via /run/ I do not run systemd-based distros, so cannot relate.
- pkulak 1y agobtw
- buckle8017 1y agotmpfs will swap.
- AdieuToLogic 1y ago> tmpfs will swap. We are both wrong to a degree, but you are more correct than I was. According to the docs[0]: tmpfs ... is able to swap unneeded pages out to swap space, if swap was enabled for the tmpfs mount. So `tmpfs` does not unconditionally use swap, but can use it if possible. What I was thinking about is `ramfs`, which doesn't support swap, but that is not the topic of the question to which I replied. 0 - https://www.kernel.org/doc/html/latest/filesystems/tmpfs.html https://www.kernel.org/doc/html/latest/filesystems/tmpfs.htm...
- buckle8017 1y agoYou have to explicitly disable swap. Honestly had no idea that was an option because I've never seen it disabled anywhere before.
- AdieuToLogic 1y ago> You have to explicitly disable swap. > Honestly had no idea that was an option because I've never seen it disabled anywhere before. Disabling swap is common with embedded systems, such as network gateways, routers, and other devices having no intrinsic mass storage devices.
- buckle8017 1y agoNo like there's a tmpfs mount flag to not allow swapping.
- buckle8017 1y agoSibling is wrong tmpfs will swap. Maybe some other ram disk things won't.
- deleted 1y ago[deleted]