Aug 252009
 

If you have a file and need to know the package that installed the file on the system then the following procedure using “pkgchk” should help.


Let’s look at the “which” utility in Solaris and find which package installed the file.

The file path for which is /usr/bin/which

# which which
/usr/bin/which

To find the package which installed it use the “pkgchk” command with the “-l” “and -p” options and the full file path of the file as follows,

# pkgchk -l -p /usr/bin/which
Pathname: /usr/bin/which
Type: regular file
Expected mode: 0555
Expected owner: root
Expected group: bin
Expected file size (bytes): 1288
Expected sum(1) of contents: 25204
Expected last modification: Jan 21 23:32:39 2005
Referenced by the following packages:
SUNWcsu

You can see that the which utility is installed by the package “SUNWcsu”.

 Leave a Reply

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

(required)

(required)