Often, we need to know which command is packed in which rpm package. Here is a tip that will help you get to know the package name. Let us look at an example in which we need to know the name of the package that contains the ssh command.
$which ssh
/usr/bin/ssh
$rpm -qf /usr/bin/ssh
openssh-clients-5.5p1-21.fc14.2.i686
In the above commands, we get the location of ssh by running which and and then the rpm package name containing ssh is outputted by the second command.
This can be achieved in a single command by combing the both commands in one, as follows:
$rpm -qf `which ssh`
openssh-clients-5.5p1-21.fc14.2.i686
Note: Please be aware that the above tip may not output as desired for command aliases.
No comments:
Post a Comment