config file installation/removal
Gerrit Kuehn
gerrit.kuehn at aei.mpg.de
Thu Feb 18 18:57:04 UTC 2021
On Tue, 16 Feb 2021 12:22:38 +0100
Gerrit Kuehn <gerrit.kuehn at aei.mpg.de> wrote:
Hello,
I think I finally found the trigger for this:
It happens on systems where I had moved /usr/local/etc to /etc/local and
put a link in /usr/local instead:
lrwxr-xr-x 1 root wheel 10 Aug 31 2018 etc@ -> /etc/local
Moving the directory back to /usr/local/etc makes pkg behave as before.
I've been using this for many years on many systems, but something in
file handling must have changed in the pkg/ports recently causing this
strange behaviour with sample files installation/removal.
Any ideas why this changed? Is this a bug or a feature?
cu
Gerrit
> Hello,
>
> I have a question concerning the handling of config files by pkg. Is
> the following the intended behaviour?
>
>
> ---
> root at crest:~ # pkg delete rsync
> Checking integrity... done (0 conflicting)
> Deinstallation has been requested for the following 1 packages (of 0
> packages in the universe):
>
> Installed packages to be REMOVED:
> rsync: 3.2.3
>
> Number of packages to be removed: 1
>
> Proceed with deinstalling packages? [y/N]: y
> [1/1] Deinstalling rsync-3.2.3...
> [1/1] Deleting files for rsync-3.2.3: 100%
> You may need to manually remove /usr/local/etc/rsync/rsyncd.conf if it
> is no longer needed.
> ---
>
> Note that there is no rsyncd.conf file to remove at this point, but
> never mind. So let's re-install rsync:
>
> ---
> root at crest:~ # pkg install rsync
> [...]
> Proceed with this action? [y/N]: y
> [1/1] Fetching rsync-3.2.3.txz: 100% 355 KiB 363.1kB/s 00:01
> Checking integrity... done (0 conflicting)
> [1/1] Installing rsync-3.2.3...
> [1/1] Extracting rsync-3.2.3: 100%
> root at crest:~ # ll /usr/local/etc/rsync/
> total 4
> -rw-r--r-- 1 root wheel 772 Feb 4 11:31 rsyncd.conf.sample
> ---
>
>
>
> So my basic issue is that apparently any config files (rsync is just
> serving as an example here) don't get removed, even if they are
> identical to their .sample files, and (worse!) no default configs get
> installed anymore, I get just the .sample files. Is this intended? I'm
> pretty sure this used to be different in the past. It is also
> described differently in the handbook:
> https://docs.freebsd.org/en_US.ISO8859-1/books/porters-handbook/plist-keywords.html#plist-keywords-sample
>
> ---
> Then, on installation, if the actual file is not found, copy the
> sample file to the actual file. And finally, on deinstallation,
> remove the actual file if it has not been modified.
> ---
>
>
> This is what I expected and was used to until recently. However, I see
> the behaviour described in the rsync example above instead on several
> systems now after (binary) updating to 12.2 (but it may have crept in
> earlier). Any thoughts/ideas?
>
>
> cu
> Gerrit
> _______________________________________________
> freebsd-pkg at freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-pkg
> To unsubscribe, send any mail to "freebsd-pkg-unsubscribe at freebsd.org"
More information about the freebsd-pkg
mailing list