what creates 'not owned by any package files'

If I am not wrong there is an rpm package responsible for creating every file in the system. But then, what creates files like /etc/passwd and similar (shadow, group etc).
Running an rpm -qf /etc/passwd shows:
file /etc/passwd is not owned by any package

Are these created during the system install phase by /usr/bin/passwd file?

On 06/18/2015 12:24 AM, vijish wrote:[color=blue]

If I am not wrong there is an rpm package responsible for creating every
file in the system. But then, what creates files like /etc/passwd and
similar (shadow, group etc).
Running an rpm -qf /etc/passwd shows:
file /etc/passwd is not owned by any package

Are these created during the system install phase by /usr/bin/passwd
file?[/color]

When you query the RPM database to ask it if a particular file is part of
a package you are specifically asking which package has that file listed
as one it maintains either exactly (a binary, like an executable or a
library) or initially (a configuration file, which it may put down but
also treats specially during upgrade situations). You can get get a list
of files maintained by a package by asking the RPM database to list all
files in a package using 'rpm -ql ", and of course if you do
this for all packages you can see all files controlled by the package system.

There are many, many other files though. All of the files in your home
directory, for example, are almost certainly unmaintained by any single
package (unless you have some odd packages specific to you, and that would
be very, very odd). Also, more to your point, many files are created by
packages using the preinstall and postinstall scripts. You can see these
scripts for a given package using the following command:

rpm -q --scripts <package-name>

I believe aaa-base is the package that initially creates /etc/passwd and
/etc/group, and maybe others, in its preinstall script:

rpm -q --scripts aaa-base


Good luck.

If you find this post helpful and are logged into the web interface,
show your appreciation and click on the star below…