|Skip Navigation Links|
|Exit Print View|
|Adding and Updating Oracle Solaris 11 Software Packages Oracle Solaris 11 Information Library|
Use the pkg update command with no pkg-fmri specified, or with an asterisk character (*) as the pkg-fmri, to update all installed packages that have updates available to the newest version allowed by the constraints imposed on the system by installed packages and publisher configuration. If non-global zones are configured in the current image, these zones are also updated. See About Packages and Zones in Oracle Solaris Administration: Oracle Solaris Zones, Oracle Solaris 10 Zones, and Resource Management.
/usr/bin/pkg update [-fnvq] [-g path_or_uri ...] [--accept] [--licenses] [--no-index] [--no-refresh] [--no-be-activate] [--no-backup-be | --require-backup-be] [--backup-be-name name] [--deny-new-be | --require-new-be] [--be-name name] [--reject pkg_fmri_pattern ...] [pkg_fmri_pattern ...]
Use the pkg list -u command to display the list of packages that have updates available. The pkg update operation often results in a new BE being automatically created. Use pkg update -nv to review what changes would be made to the current image or in a new BE. Use the --be-name option to force a new BE to be created or to give the new BE a meaningful name.
Tip - Explicitly specifying a new BE is the safest way to install or update. See Boot Environment Policy Image Properties for information about when BEs are created.
By default, each package is updated from the publisher that provided the currently installed version. You can control the publisher that provides packages by specifying publisher stickiness and search order. See Adding, Modifying, or Removing Package Publishers.
When you specify the -f option when updating all installed packages, the client up-to-date check is not executed.
Use the -g option to temporarily add the specified package repository or package archive to the list of sources in the image from which to retrieve package data. After update, any packages provided by publishers not found in the image are added to the image configuration without an origin.
Use the --accept option to indicate that you agree to and accept the terms of the licenses of the packages that are updated. If you do not provide this option, and any package licenses require acceptance, the update operation fails. Use the --licenses option to display all of the licenses for the packages that are updated as part of this operation.
When you specify the -no-refresh option, the repositories for the image's publishers are not contacted to retrieve the newest list of available packages and other metadata.
When you specify the --no-index option, the search indices are not updated after the operation has completed successfully. Specifying this option might save some time if you are installing a large number of packages. When the update operation finishes, you can use pkg refresh to update the list of available packages and publisher metadata for each publisher specified. If no publishers are specified, the refresh is performed for all publishers. If a new BE was created, do this publisher refresh in the new BE.