You are not logged in.
According to https://wiki.archlinux.org/title/NVIDIA … er_suspend and https://download.nvidia.com/XFree86/Lin … ement.html, if /tmp (size is half of RAM) is not sufficient to store video memory (total VRAM of all cards + 5% margin), then
NVreg_TemporaryFilePath may be used to use a different path (on an HDD/SSD this time for bigger size). I'm wondering if anyone has any recommendations for what directory to use? https://man.archlinux.org/man/file-hierarchy.7 doesn't show anything relevant to this and the section is very essential because without it, Wayland wouldn't work on GDM.
If anyone knows what to use for that path, then please edit the ArchWiki section to provide the path since the current description is very vague.
Last edited by Cont9999 (2022-08-28 00:48:04)
Offline
/var/tmp/
The place for larger and persistent temporary files. In contrast to /tmp/, this directory is usually mounted from a persistent physical file system and can thus accept larger files. (Use /tmp/ for small ephemeral files.) This directory is generally not flushed at boot-up, but time-based cleanup of files that have not been accessed for a certain time is applied.
Mods are just community members who have the occasionally necessary option to move threads around and edit posts. -- Trilby
Offline
file-hierarchy(7) wrote:/var/tmp/
The place for larger and persistent temporary files. In contrast to /tmp/, this directory is usually mounted from a persistent physical file system and can thus accept larger files. (Use /tmp/ for small ephemeral files.) This directory is generally not flushed at boot-up, but time-based cleanup of files that have not been accessed for a certain time is applied.
Would having video memory in a directory that doesn't get flushed at boot-up cause issues? Imagine you lose power when your PC is suspended for example, what would happen then? Also, /tmp is for "small temporary files." How would using a directory that's meant for larger and persistent files be a valid alternative for that?
Last edited by Cont9999 (2022-08-22 20:35:00)
Offline
If you lose power when the PC is suspended, you lose all saved data because it is in memory. With hibernate, the data of the "current" boot is stored to disk. /var/tmp would only be flushed on the "next" boot.
The "small temporary files" distinction is arbitrary unless you put /var on a separate partition of minimal size.
Mods are just community members who have the occasionally necessary option to move threads around and edit posts. -- Trilby
Offline
If you lose power when the PC is suspended, you lose all saved data because it is in memory. With hibernate, the data of the "current" boot is stored to disk. /var/tmp would only be flushed on the "next" boot.
The "small temporary files" distinction is arbitrary unless you put /var on a separate partition of minimal size.
Understood, thank you.
This was already added to the Wiki.
If you don't mind, I have a question. I got /var separated (12G size, as recommended in partitioning article). And I have a graphics card with 4GB VRAM.
Do you think it's gonna be sufficient? I don't think the partitioning article had flushing VRAM to a path under /var on hibernate or suspend in mind when it was made, thus maybe we should update the partitioning article to include a note for people who will set NVreg_TemporaryFilePath to /var/tmp, to let them know that they increase the size of their /var partition by the amount of VRAM they have, or something similar?
Last edited by Cont9999 (2022-08-25 18:06:07)
Offline
I already updated the Wiki, but if anyone can provide confirmation if this is the preferred thing to do, please reply to this thread.
I thought of 3 options here: Example 10 GiB /var and 8GiB video memory.
1- Keep /var the same size, but encourage better cache hygiene for more empty space to always keep at least the size of the video memory free. (/var stays 10 GiB)
2- Increase /var by the size of the video memory to /var and excuse the 5% margin requested by NVIDIA, since adding the margin as well would make the size number a bit unusual. (/var becomes 18 GiB)
3- Increase /var by the size of the video memory to /var, along with the 5% margin. (/var becomes 18.4 GiB)
I added the second option, but I'm still waiting for confirmation by people who are more experienced with this, and know what to actually do. If what I added to the Wiki for everyone was wrong, let me know and I'll update it as soon as I see the reply.
Last edited by Cont9999 (2022-08-27 00:09:32)
Offline
I wonder why you fixate this much on /var . You can pass any directory and any location as long as the free space of the partition/filesystem as a whole is sufficient to support storing the video memory of the card during suspend. I just made one called /nvidia-tmp for example. And most people should be able to logically infer the meaning of "the directory you pass there needs to be on a partition with ample free space for storing VRAM + 5% margin"
Last edited by V1del (2022-08-26 10:36:29)
Offline
I wonder why you fixate this much on /var . You can pass any directory and any location as long as the free space of the partition/filesystem as a whole is sufficient to support storing the video memory of the card during suspend. I just made one called /nvidia-tmp for example. And most people should be able to logically infer the meaning of "the directory you pass there needs to be on a partition with ample free space for storing VRAM + 5% margin"
It seems like the only non-tmpfs path that would make sense. Creating an entire directory under / seems less ideal than just using the existing ones.
And I'm trying to find the correct way of doing it because there are many people who separate /var, so adding more instructions to the Wiki to make it clearer instead of people having to link points together wouldn't hurt.
Offline
I'm marking this as solved. While what I need help with now is kinda related to the main topic, it's not entirely on topic. I'll post a new topic for it.
Offline