Re: systemd tmp.mount vs. just /etc/fstab

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2/23/23 09:19, Jonathan Billings wrote:
On Feb 23, 2023, at 08:45, Robert Nichols <rnicholsNOSPAM@xxxxxxxxxxx> wrote:

If I want to use a tmpfs for /tmp, I can just enable the systemd tmp.mount unit and get the default size limit of 1/2 of memory. If I want to reduce that limit, I either have to fiddle with a systemd override or else put a line in /etc/fstab just as in the days before systemd, and the systemd unit will respect the size option there.

But, that line in /etc/fstab can do the job on its own, so what's the point of enabling the tmp.mount unit?

Putting a line in /etc/fstab is a functional equivalent of creating a tmp.mount that overrides the packaged one.

When you have a line in fstab, on boot the systemd fstab generator creates a tmp.mount file in /run/systemd/ that overrides the OS tmp.mount. Any x-systemd mount options get translated into proper systemd options.

Thanks for the explanation. Separately enabling tmp.mount would be superfluous, and I just discovered that systemctl doesn't even _let_ you do that if you have booted with an fstab /tmp on tmpfs:

   # systemctl enable tmp.mount
   Failed to enable unit: Unit /run/systemd/generator/tmp.mount is transient or generated.

--
Bob Nichols     "NOSPAM" is really part of my email address.
                Do NOT delete it.

_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx
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@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue



[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux