man/man8/ldconfig.8: document system-wide tunables
DJ Delorie <[email protected]> Thu, 09 Jul 2026 14:53:09 -0400
| Newsgroups | org.kernel.vger.linux-man |
|---|---|
| Message-ID | <[email protected]> |
diff --git a/man/man8/ldconfig.8 b/man/man8/ldconfig.8 index ee024b8f6..8574eae24 100644 --- a/man/man8/ldconfig.8 +++ b/man/man8/ldconfig.8 @@ -17,6 +17,8 @@ .SH SYNOPSIS .IR conf ] .RB [ \-r\~\c .IR root ] +.RB [ \-t\~\c +.IR tunconf ] .IR directory \~.\|.\|. .YS .SY /sbin/ldconfig @@ -85,6 +87,11 @@ .SH DESCRIPTION .P Failure to follow this pattern may result in compatibility issues after an upgrade. +.P +If the file +.IR /etc/tunables.conf +exists, it contains one tunable per line. These tunables are stored +in the cache and applied to every process at its startup. .SH OPTIONS .TP .BI \-\-format= fmt @@ -157,6 +164,12 @@ .SH OPTIONS .I root as the root directory. .TP +.BI \-t\~ tunconf +Use +.I tunconf +instead of +.IR /etc/tunables.conf . +.TP .B \-\-verbose .TQ .B \-v @@ -177,9 +190,85 @@ .SH OPTIONS .B \-N is also specified, the cache is still rebuilt. +.SH INCLUDES +The files +.IR /etc/ld.so.conf +and +.IR /etc/tunables.conf +allow lines to start with the word +.I include +followed by a path wildcard, and will include any files matching that +wildcard. +.SH TUNABLES +Each line in the file +.I /etc/tunables.conf +specifies a tunable, which is a name and value +separated by an equals sign. +Each line may include zero or more words or symbols at the beginning: +.TP +.B overridable +.TQ +.B + +Allow the tunable to be overridden by the environment variable (this is the default). +.TP +.B nonoverridable +.TQ +.B \- +Do not allow the tunable to be overridden by the environment variable. +.TP +.B onlysecure +.TQ +.B @ +The tunable only applies to AT_SECURE (i.e. setuid, or elevated +capabilities) processes. +.TP +.B nonsecure +.TQ +.B $ +The tunable only applies to non-AT_SECURE processes (this is the default). +.TP +.B anysecure +.TQ +.B * +The tunable only applies to both AT_SECURE and non-AT_SECURE processes. +.P +The file may also contain +.I filters , +which limit the tunables following it, up to the end of the file (or +end of the included file, or start of a new included file) or a line +with only +.B [] +on it. The syntax is: +.RS +.P +[ +.I filter +: +.I pattern +] +.RE +.P +.TP +.B proc +The +.I proc +filter limits the following tunables to processes starting from the +file matching the pattern. The file may be fully qualified or just +the basename. +.P +Example config file: +.P +.RS +.nf +glibc.malloc.arenas_max=5 +onlysecure glibc.malloc.arenas_max=1 +-glibc.pthread.rseq=1 +[proc:/bin/bad.program] +-glibc.pthread.rseq=0 +.fi +.RE +.P .SH FILES -.\" FIXME Since glibc-2.3.4, "include" directives are supported in ld.so.conf -.\" .\" FIXME Since glibc-2.4, "hwcap" directives are supported in ld.so.conf .PD 0 .TP @@ -191,6 +280,11 @@ .SH FILES one per line, in which to search for libraries. .TP +.I /etc/tunables.conf +contains a list of tunables, +one per line, +to apply to all newly created processes. +.TP .I /etc/ld.so.cache contains an ordered list of libraries found in the directories specified in