SYSCONFTOOL(1)

πŸ“¦
version 0.22 Β· 3 versions
, in fedora 44, ubuntu resolute, ubuntu stonking

πŸ’– SYSCONFTOOL(1) πŸ’–

okay bestie, pull up a chair, we're talking about sysconftool and sysconftoolize β€” the manual page one, section 1, the install configuration files girlies πŸŽ€


✨ NAME ✨

sysconftool, sysconftoolize β€” install configuration files πŸ’…


🌸 SYNOPSIS 🌸

sysconftool [options] [filename.dist...]

sysconftoolize

πŸ¦‹ DESCRIPTION πŸ¦‹

So sysconftool is this development utility that literally just helps you install application configuration files. no cap. and the whole point? it lets an existing application get upgraded without losing the older version's configuration settings 😭🫢 like, your settings survive the glow-up.

here's the tea: a new version of an app often brings new configuration settings. sometimes obsolete ones get removed. sometimes existing settings now have extra options, or certain options just aren't valid anymore πŸ’€. because of all that, an application upgrade usually installs a fresh set of configuration files containing a default config that's known to work. but keeping the existing files? that's risky β€” the app might fail to function properly because the config is no longer valid. it's giving ticking time bomb πŸ™ˆ

so a typical application installation script just copies over configuration files with default settings, and existing configuration files get backed up or straight-up overwritten. not with sysconftool though. with sysconftool, an application installs a configuration file named filename.dist instead of filename. then the application's installation script runs sysconftool. sysconftool copies filename.dist to filename, but it also checks if filename from an older version of the application already exists. and if filename is an older sysconftool-installed configuration file, its configuration settings replace the defaults in filename.dist, which is then subsequently installed as filename. periodt πŸ’…

sysconftool is smart enough to:

  • Remove configuration settings that no longer exist.
  • Add new configuration settings.
  • Do not preserve an older configuration setting if there's a possibility that it is no longer valid in the new version of the application.

and it produces a short report when it runs β€” the report lists every configuration setting in $filename.dist and its disposition. the possible dispositions are:

  • new β€” this a new configuration setting that wasn't found in the existing $filename. ✨ fresh out the box ✨
  • unchanged β€” this setting's value was taken from the existing $filename, replacing the default value provided by $filename.dist. iconic, untouched, preserved πŸ‘‘
  • UPDATED β€” this setting has been previously set in $filename, but the setting's value may no longer be valid in the new version of the application, so its default value is taken from $filename.dist, and it may need to be manually adjusted. πŸ‘€ bestie you gotta look at this one

all this logic is based on some additional metadata that must be included in each configuration file, that sysconftool reads. for this to work, both the old and the new version of the application must be sysconftool-ized. iykyk 🧚

sysconftool operates in a fail-safe mode. if the old version did not use sysconftool, $filename is backed up to $filename.bak, and $filename is copied to $filename. this is what would essentially happen anyway without sysconftool. the local configuration needs to be reentered into $filename, so nothing is lost. however, the next upgrade will see sysconftool do its job. 🫢

πŸ’œ ADDING SYSCONFTOOL SUPPORT TO AN EXISTING APPLICATION πŸ’œ

sysconftool requires the application to use autoconf and automake. first step bestie: run the sysconftoolize script from the application's source directory. sysconftoolize creates a symbolic link to the sysconftool script from the current directory, and appends a default install-configure rule to Makefile.am. sysconftoolize with the --copy option copies the script, instead of creating a symbolic link. πŸŽ€

after running sysconftoolize the macro AC_PROG_SYSCONFTOOL must be manually added to configure.ac, and Makefile.am must be modified as follows.

Makefile.am must be modified to install configuration files as filename.dist instead of filename. the default install-configure rule assumes that sysconf_DATA lists all configuration files in sysconfdir, and runs sysconftool on them. this will usually have to be modified, according to the application's individual needs. finally, Makefile.am must be modified to distribute the sysconftool script in the application's source distribution. adding sysconftool to EXTRA_DIST is what's needed in most cases. πŸ“

finally, certain sysconftool magic incantations must be added to the application's configuration files, see sysconftool(7)[1] for more information. the last step involves updating the application's INSTALL instructions, so that the application can be properly installed. the following instructions must be added to INSTALL:

  1. Run "make install-configure" after "make install".
  2. If this is the first sysconftool-ized version, DO NOT simply copy over the old configuration files, and overwrite the new configuration files. Instead, manually edit each configuration file, and manually reset each configuration setting. This is because the new configuration files include the magic code for sysconftool, which would be lost when the configuration file is overwritten.
  3. If this is not the first sysconftool-ized version, the output of make install-configure must be reviewed in order to manually adjust or tweak what sysconftool did. Many large configuration files can result in lots of output, so the output of make install-configure should be saved into a file, and reviewed.
number 2 is serious bestie, do NOT just copy-paste over that file, the magic code gets lost πŸ’€ number 3 is just good manners fr fr 🌈

πŸ”₯ SEE ALSO πŸ”₯

sysconftoolcheck(1)[2], sysconftool(7)[1].


πŸ‘‘ AUTHORS πŸ‘‘

S. Varshavchik.


⭐ NOTES ⭐

  1. sysconftool(7) https://www.courier-mta.org/sysconftool/sysconftool.7.html
  2. sysconftoolcheck(1) https://www.courier-mta.org/sysconftool/sysconftoolcheck.1.html

and that's the whole thing, bestie πŸ’– this one's from the Courier Mail Server girlies, dated 01/11/2026, and it's page SYSCONFTOOL(1) β€” slay, go configure something πŸŒΈβœ¨πŸ¦‹

πŸ“¦ where this page comes from