Solaris find out a package which a file belongs to

by on October 20, 2006 · 1 comment· last updated at October 20, 2006

Q. How do I find out a package which a file belongs to...? I am using Solaris UNIX ver 10.0

A. Use pkgchk command which check package installation accuracy under Solaris UNIX.

pkgchk checks the accuracy of installed files or, by using the -l option, displays information about package files. pkgchk checks the integrity of directory structures and files. Discrepancies are written to standard error along with a detailed explanation of the problem.

You can find out a package which a file belongs to with following command:
pkgchk -l -p /path/to/file
pkgchk -l -p /usr/bin/ls

Where,

  • -l: List information on the selected files that make up a package
  • -p path: Only check the accuracy of the path name or path names listed. path can be one or more path names separated by commas (or by white space, if the list is quoted).

Above command displays package installation information for /usr/bin/ls command. Following command displays package installation information for sendmail:
# pkgchk -l -p /usr/lib/sendmail



You should follow me on twitter here or grab rss feed to keep track of new changes.

Featured Articles:

{ 1 comment… read it below or add one }

1 Toxic July 21, 2009 at 7:59 am

Thank You.

Reply

Leave a Comment

You can use these HTML tags and attributes for your code and commands: <strong> <em> <ol> <li> <u> <ul> <kbd> <blockquote> <pre> <a href="" title="">

Tagged as:

Previous Faq:

Next Faq: