Oracle Solaris 11 Cheat Sheet For The Image Packaging System

Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

Oracle Solaris 11 Cheat Sheet for the Image Packaging System

What is Image the Packaging System? Getting Information or Searching for Packages
• The Image Packaging System (IPS) is a new network-centric software packaging and delivery
system in Oracle Solaris 11. IPS allows efficient, observable, and controllable transitions between
known configurations of software content providing administrators with safe system upgrade List packages currently installed on a system:
environments and better control over planned system downtime schedules.
• The ZFS file system is integral to IPS, providing administrators the ability to perform updates on a pkg list
file system clones on live production systems.
• NOTE: While many IPS commands that query the system (list, info, contents, search, Show information about an installed package called wireshark:
history) can be performed by any user, commands that make changes to the system image must
be performed by adopting an appropriate administrative role. pkg info wireshark

Show information about an uninstalled package called xchat:


Understanding the Package FMRI
Each software package is uniquely described by an FMRI (Fault Managed Resource Indicator), for pkg info -r xchat
example:
pkg://solaris/diagnostic/[email protected],5.11-0.174:20110128T0635Z Show the contents of an installed package called wireshark:

pkg contents wireshark


FMRI Segment Description
solaris Publisher Show all PNG files of an installed package called wireshark:
diagnostic/wireshark Package name
pkg contents -o path -a path=\*.png wireshark
1.4.2 Component version
5.11 Build version Search all locally installed packages for the match gcc:
0.174 Branch version pkg search -l gcc
20110128T0635Z Package time stamp Search all packages in the configured repositories that contain dev header
gcrypt-module.h:

Installing Packages and Updating a System pkg search 'gcrypt-module.h'


Installing new packages on your system does not require a new boot environment (BE) to be created. Search for all packages in the configured repositories that have the
However, creating a ZFS snapshot and clone initially consumes no additional space and is an classification Web Services/Application and Web Servers:
instantaneous operation. So it should be considered as an administrative best practice.
pkg search -o pkg.name 'set:info.classification:*Application
and Web Servers'

Search for all packages installed locally that have a dependency on


Install a package called diagnostic/wireshark: library/libxml2:
pkg install diagnostic/wireshark
Uninstall a package called diagnostic/wireshark using a short form of the package pkg search –l -o pkg.name 'depend::library/libxml2'
name:
pkg uninstall wireshark
Update all possible packages to the newest version, including all Oracle Solaris zones:
pkg update
Do a dry run of an update of all possible packages to the newest version:
pkg update -nv
Update all system packages to the newest version and require a new BE:
pkg update --be-name fix-nfs-issue

1
Oracle Solaris 11 Cheat Sheet for the Image Packaging System

Managing Repositories and Publishers Miscellaneous Commands

Browse package command history (includes graphical Package Manager client):


List currently associated publishers:
pkg history
pkg publisher Purge package command history:
pkg purge-history
Add a publisher at a specified repository URI:
Verify the integrity of the current system image:

pkg set-publisher -p http://www.example.com/solaris11 pkg verify


Verify the integrity of installed package called wireshark:
Add a publisher: pkg verify wireshark
Fix any errors reported by pkg verify on an installed package called wireshark:
pkg set-publisher -g http://www.example.com/solaris11 siteapps
pkg fix wireshark
Remove a publisher: Freeze a package called wireshark to prevent any accidental future updates:
pkg freeze wireshark
pkg unset-publisher siteapps

Query a repository URI for publisher names and package counts:

pkgrepo -s http://pkg.oracle.com/solaris/release info


Change to the Oracle Solaris support repository with pre-downloaded certificates
and keys from the Oracle Solaris release repository:
pkg set-publisher -G http://pkg.oracle.com/solaris/release \
-g http://pkg.oracle.com/solaris/support -k /path/to/ssl_key \
-c /path/to/ssl_cert solaris

You might also like