On Thu, Mar 24, 2022 at 6:36 AM Brad Bell <bradb...@seanet.com> wrote:
>
> I am doing algorithmic differentiation with very large tapes and my jobs 
> sometimes run out of memory.

So the workload is producing a substantial amount of anonymous pages.
It's kinda hard to tell what to do to optimize without a decent amount
of knowledge about the workload's behavior. So you'd have to just
change some things and see if the performance improves. I tentatively
expect that you'd be better off disabling zram-generator, setting up a
swap partition or file, and optionally enabling zswap (which is a
different thing than zram). On the plus side, this frees up quite a
lot of memory (roughly half), but on the negative side it might
increase swap thrashing - it really depends on the workload. But zswap
has the benefit of using Least Recently Used (LRU) to evict pages from
the in-memory compressed cache pool to the conventional swap file.
That way it's the stale pages going to disk and the active ones being
compressed in memory.

Also, for what it's worth, on Btrfs I use /var/swap/swapfile1
/var/swap/swapfile2 ... and so on. Where "varswap" is a subvolume
located on the top-level of the file system (next to install time
default subvolumes "root" and "home") and has chattr +C set on it.
That way should I take snapshots of root (or even var in some custom
configurations) I'm not snapshotting the swapfiles. Snapshotting the
swap files ends up making them subject to COW again, and that's
incompatible with using them as swapfiles. The entry in fstab looks
like this:

UUID=$uuid /var/swap       btrfs   noatime,subvol=varswap 0 0

man 5 btrfs has a SWAPFILE SUPPORT section that's fairly detailed steps.

--
Chris Murphy
_______________________________________________
users mailing list -- users@lists.fedoraproject.org
To unsubscribe send an email to users-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/users@lists.fedoraproject.org
Do not reply to spam on the list, report it: 
https://pagure.io/fedora-infrastructure

Reply via email to