Solaris Package Management

Source: Internet
Author: User
Tags file size

1.pkginfo Display Package Information

Command format: pkginfo-d[Device|pathname]-l pkg_name


These three domains are:


Package type, available for application,graphics or system.


Package name, such as sun products, the machine SUNW head.


A brief description of the SOFTWARE PRODUCT.


# pkginfo-d/cdrom/solaris_2_2/s0/solaris_2.2 |more

Use the PKGINFO-L command to display detailed information about the package, including the size of the package (by the hard disk block size


# pkginfo-d/cdrom/solaris_2_2/s0/solaris_2.2-l Sunwaudio

The last line of output above indicates the size of the package. Use this information and df-k command to determine if you have sufficient

Enough hard disk space to install this package.

2. Pkgadd Add Package

Use the Pkgadd command to increase the package and send a message to root when the package is successfully installed.

Command format:

pkgadd-d [Device | pathname] Pkg_name


# pkgadd-d/cdrom/solaris_2_2/s0/solaris_2.2 Sunwaudio

Installation of 3.PKGCHK checksum package

The PKGCHK command verifies that the package's properties and pathname contents are compared to the values in the system record file.

Command format:

Pkgchk [-P path1 [path2 ...]]

This command checks the entire package or a special pathname by specifying the-p option, and no output means

There was no problem being checked out.

Because the/etc/group file size has been changed, the checksum of the file content is incorrect.

Review package information

The pkgadd command updates the file/var/sadm/install/contents, which is all installed packages in the system

Record file.

There is no easy way to determine that a package has a particular file (or command).

For installed packages, find the path to this package from the/var/sadm/install/contents record file


4.PKGRM Delete Package

Command format: PKGRM pkgname1 pkgname2 ...

After the PKGRM command is invoked, you are alerted to the dependency package information and provide tips for discarding this action.

When the package is successfully deleted, send a message to root.

The PKGRM command uses file/var/sadm/install/contents to determine the address of the package, and when the package

Update this file after it has been deleted.

If this package is shared by two or more packages, then all packages that depend on this package must be removed to

Before removing this package.

5.spooling Package

A package can be copied from the installation CD-ROM and stored in the system, but this package is not installed.

For example, a server can copy and store a package, and a system without a CD-ROM device can

To install the package by hooking it up.

Packages can also be remotely installed using Software Manager, temporarily.


The following two Pkgadd commands explain how to spool a package into the/var/spool/pkg directory or to a point where you

The-S-spool option of the Pkgadd command will automatically copy the package to the/VAR/SPOOL/PKG directory by default.

You can specify a directory as the parameter of the-s option.


If the server shares the/export/pkgs directory, the client system can hook up the directory/export/pkgs and install


# mkdir/export/pkgs

# Mount Venus:/export/pkgs/export/pkgs

# pkgadd-d/export/pkgs Sunwaudio

Remove spooled Package

The-s option can be used on the server to remove a package from the spooling directory.

# pkgrm-s/export/pkgs Sunwaudio

Files and directories related to package management


Directory containing system record files and administrative files


Installs the recommended directory for packages named Pkgname that are not provided with the operating system.



The recommended directory for execution files named Pkgname that are not provided with the operating system.



The recommended directory for a record file named Pkgname that is not provided with the operating system.


A package image of the entire system.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.