I am trying to write a script where I can tell whether the package is a pre-installed or it was installed by user.
And also can we have way to get to know that following are the dependencies of the package 'X'
on the rpm
level you cannot really know. Depending on the package manager you use there might be some information stored there.
Note that this only works if the user ran the installation commands with sudo
. If he became root, you'll never know who did it.
yum history
gives you a list of transactions and which user launched the command.
dnf history
gives you a list of transactions, but doesn't list the user by default. You can however run:
dnf history info <ID>
and then you will see the user who launched the command
there is no way to know this afaik.
Collected from the Internet
Please contact [email protected] to delete if infringement.
Comments