Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 740550 - net-misc/chrony-3.5.1-r1: 'chown -R root:root /var/lib/chrony' required when switching USE=caps to USE=-caps
Summary: net-misc/chrony-3.5.1-r1: 'chown -R root:root /var/lib/chrony' required when ...
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Sam James
Depends on:
Reported: 2020-09-05 16:22 UTC by CaptainBlood
Modified: 2020-11-04 00:45 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Note You need to log in before you can comment on or make changes to this bug.
Description CaptainBlood 2020-09-05 16:22:01 UTC
When building prior to bug #740418 fix, e.g. USE=caps
I followed final advice:
if [[ -n ${REPLACING_VERSIONS} ]] && use caps && ! ${HAD_CAPS}; then
                ewarn "Please adjust permissions on ${EROOT}/var/{lib,log}/chrony to be owned by ntp:ntp"
                ewarn "e.g. chown -R ntp:ntp ${EROOT}/var/{lib,log}/chrony"
                ewarn "This is necessary for chrony to drop privileges"

-rebuilding USE=-caps didn't reset /var/lib/chrony ownership from net:net to root:root
-removing the package didn't help either, likely because out of build contents remained in the directory, e.g.: 
var/lib/chrony: -rw-r--r-- 1 net net 42 sept.  5 18:42 drift

So I removed once again, deleted the dir, i.e.:
rm var/lib/chrony -rf
Then reinstalled to finally have it set back to root:root, which seems to be to correct value:
So as of now, to put things back to order user switching from USE=caps to USE=-caps might have to do:
chown -R root:root /var/lib/chrony

Reproducible: Always