Example:
/etc/bind/db.local
file is created by apt packagebind9
( source: https://packages.debian.org/buster/amd64/bind9/filelist )but how to find a package which have created for example
/usr/share/dns/root.hints
?
I am looking for a universal solution to check any file path and the answer should be the package name (names if there is more then one) or reliable answer, that the file path was created by a user (i.e. not by apt install
).
bind
though... – Kusalananda Feb 23 '20 at 13:18dpkg-query -S FILE
? https://superuser.com/a/179354 – guest Feb 23 '20 at 13:34dpkg-query -S
(ordpkg -S
) will find files that are installed directly from the package archive, however there are sometimes additional files created by package installation scripts, which AFAIK it will not show. – steeldriver Feb 23 '20 at 13:46dpkg-query -S
seems to work very well. – mvorisek Feb 23 '20 at 13:49