
- Administrators can suggest whether we required Oracle repository or Local repository depends on environment requirements.
- Oracle Solaris 11 installations will come up with default publisher http://pkg.oracle.com/solaris/release which supplies all packages from the oracle release repository.
- Administrators can install new software packages, search the content of package or mirror the contents of that repository locally.
- Oracle Solaris 11 having many IPS pkg command which query the system with using option "list, info, content, search, history can be performed by users.
Basics of Packages FMRI:
below output you can understand the brief about the structure of package FMRI (Fault Managed Resources Identifier).
Listing installed Packages in that server
below output you can understand the brief about the structure of package FMRI (Fault Managed Resources Identifier).
Listing installed Packages in that server
root@unixrock:~# pkg list |moreListing the Version information of particular pkg
NAME (PUBLISHER) VERSION IFO
archiver/gnu-tar 1.26-0.175.1.0.0.24.0 i--
audio/audio-utilities 0.5.11-0.175.1.0.0.24.2 i--
codec/flac 1.2.1-0.175.0.0.0.0.0 i--
codec/libtheora 1.1.1-0.175.1.0.0.15.0 i--
codec/ogg-vorbis 2.30.0-0.175.1.0.0.12.0 i--
codec/speex 1.2-0.175.1.0.0.15.0 i--
communication/im/pidgin 2.10.5-0.175.1.0.0.24.0 i--
compress/bzip2 1.0.6-0.175.1.0.0.24.0 i--
compress/gzip 1.4-0.175.1.0.0.24.0 i--
compress/p7zip 9.20.1-0.175.1.0.0.24.0 i--
compress/unzip 6.0-0.175.1.0.0.24.0 i--
compress/xz 5.0.1-0.175.1.0.0.24.0 i--
compress/zip 3.0-0.175.1.0.0.24.0 i--
---------Few lines are confiscated----------------------------------------------
x11/xfontsel 1.0.4-0.175.1.0.0.24.1317 i--
x11/xfs 1.1.2-0.175.1.0.0.24.1317 i--
x11/xfs/xfs-utilities 7.7-0.175.1.0.0.24.1317 i--
x11/xkill 1.0.3-0.175.1.0.0.24.1317 i--
x11/xlock 0.5.11-0.175.1.0.0.24.1317 i--
x11/xmag 1.0.4-0.175.1.0.0.24.1317 i--
x11/xvidtune 1.0.2-0.175.1.0.0.24.1317 i--
root@unixrock:~#
root@unixrock:~# pkg list diagnostic/tcpdumpChecking detailed information about the particular pkg
NAME (PUBLISHER) VERSION IFO
diagnostic/tcpdump 4.1.1-0.175.1.0.0.24.0 i--
root@unixrock:~#
root@unixrock:~# pkg info diagnostic/tcpdumpChecking contents of particular pkg which shows the complete installation path.
Name: diagnostic/tcpdump
Summary: network traffic sniffer
Description: A tool for network monitoring and data acquisition
Category: Applications/Internet
State: Installed
Publisher: solaris
Version: 4.1.1
Build Release: 5.11
Branch: 0.175.1.0.0.24.0
Packaging Date: September 4, 2012 05:17:58 PM
Size: 1.24 MB
FMRI: pkg://solaris/diagnostic/tcpdump@4.1.1,5.11-0.175.1.0.0.24.0:20120904T171758Z
root@unixrock:~#
root@unixrock:~# pkg contents diagnostic/tcpdumpChecking the package history for the recent updates and changes.
PATH
usr
usr/sbin
usr/sbin/tcpdump
usr/share
usr/share/man
usr/share/man/man1
usr/share/man/man1/tcpdump.1
root@unixrock:~#
root@unixrock:~# pkg historyChecking the all package Integrity
START OPERATION CLIENT OUTCOME
2012-09-20T01:18:22 set-property transfer module Succeeded
2012-09-20T01:18:22 add-publisher transfer module Succeeded
2012-09-20T01:18:22 refresh-publishers transfer module Succeeded
2012-09-20T01:18:22 image-create transfer module Succeeded
2012-09-20T01:18:30 rebuild-image-catalogs transfer module Succeeded
2012-09-20T01:18:36 set-property transfer module Succeeded
2012-09-20T01:18:37 install transfer module Succeeded
2012-09-20T02:00:12 update-publisher transfer module Succeeded
2012-09-20T02:00:12 refresh-publishers transfer module Succeeded
2014-09-31T23:37:48 refresh-publishers pkg Failed
2014-09-31T23:37:48 update pkg Failed
2014-08-11T21:34:42 refresh-publishers pkg Succeeded
root@unixrock:~# pkg verifyChecking the particular package Integrity
pkg://solaris/desktop/administration/nwam-manager 55/847 /
root@unixrock:~# pkg verify diagnostic/tcpdumpSearching particular packages with details
root@unixrock:~#
root@unixrock:~# pkg search -l diagnostic/tcpdumprebuild the repo index whenever search performance is degraded
INDEX ACTION VALUE PACKAGE
group depend diagnostic/tcpdump pkg:/group/system/solaris-desktop@0.5.11-0.175.1.0.0.24.3
incorporate depend pkg:/diagnostic/tcpdump@4.1.1-0.175.1.0.0.24.0 pkg:/consolidation/userland/userland-incorporation@0.5.11-0.175.1.0.0.24.0
pkg.fmri set solaris/diagnostic/tcpdump pkg:/diagnostic/tcpdump@4.1.1-0.175.1.0.0.24.0
root@unixrock:~#
root@unixrock:~# pkg rebuild-indexInstalling the particular package
PHASE ITEMS
Building new search index 847/847
root@unixrock:~#
root@unixrock:~# pkg install diagnostic/tcpdumpChecking the dependency packages
Packages to install: 1
Create boot environment: No
Create backup boot environment: No
DOWNLOAD PKGS FILES XFER (MB) SPEED
Completed 1/1 6/6 0.4/0.4 0B/s
PHASE ITEMS
Installing new actions 20/20
Updating package state database Done
Updating image state Done
Creating fast lookup database Done
Reading search index Done
Updating search index 1/1
root@unixrock:~#
root@unixrock:~# pkg contents -r -o fmri,type -t depend diagnostic/tcpdumpUninstalling the package
FMRI TYPE
pkg:/system/library/libpcap@1.1.1-0.175.1.0.0.23.0 require
pkg:/system/library@0.5.11-0.175.1.0.0.23.0 require
root@unixrock:~#
root@unixrock:~# pkg uninstall diagnostic/tcpdumpSolaris 11 IPS will update your system to latest packages with single command "pkg update". Even though we can execute the command with "-nv" option for a dry run to get an idea about the work which needs to be completed.
Packages to remove: 1
Create boot environment: No
Create backup boot environment: No
PHASE ITEMS
Removing old actions 14/14
Updating package state database Done
Updating package cache 1/1
Updating image state Done
Creating fast lookup database Done
Reading search index Done
Updating search index 1/1
root@unixrock:~#
root@unixrock:~# pkg update -nvTrying to update the particular packages from repo
No updates available for this image.
root@unixrock:~#
root@unixrock:~# pkg update diagnostic/tcpdumpList the publisher with local repository
No updates available for this image.
root@unixrock:~#
root@unixrock:~# pkg publisherListing the local repository packages
PUBLISHER TYPE STATUS P LOCATION
solaris origin online F file:///unixrepo/repo/repo/
root@unixrock:~#
root@unixrock:~#
root@unixrock:~# pkgrepo -s /unixrepo/repo/repo/ list|moreChecking the local repository packages status and updated dates
PUBLISHER NAME O VERSION
solaris BRCMbnx r 0.5.11,5.11-0.133:20101027T183107Z
solaris BRCMbnxe r 0.5.11,5.11-0.133:20101027T183108Z
solaris CPQary3 r 0.5.11,5.11-0.133:20101027T183108Z
solaris FSWfontconfig-devel-docs o 0.5.11,5.11-0.130:20101027T183140Z
solaris FSWxorg-client-docs r 0.5.11,5.11-0.130:20101027T183141Z
solaris FSWxorg-client-programs r 0.5.11,5.11-0.130:20101027T183142Z
solaris FSWxorg-clientlibs r 0.5.11,5.11-0.130:20101027T183142Z
solaris FSWxorg-data r 0.5.11,5.11-0.130:20101027T183143Z
root@unixrock:~# pkgrepo info -s /unixrepo/repo/repoChecking the oracle repo packages status and updated dates.
PUBLISHER PACKAGES STATUS UPDATED
solaris 4299 online 2014-08-14T17:34:29.002068Z
root@unixrock:~#
root@unixrock:~# pkgrepo info -s http://pkg.oracle.com/solaris/release/Refreshing the local repository whenever its required
PUBLISHER PACKAGES STATUS UPDATED
solaris 4870 online 2014-08-04T15:04:42.642929Z
root@unixrock:~#
root@unixrock:~# pkgrepo refresh -s /unixrepo/repo/repoDisplay All Repository Properties
Initiating repository refresh.
root@unixrock:~# pkgrepo get -s /unixrepo/repo/repoUpdating the local repository from Oracal Portal
SECTION PROPERTY VALUE
publisher prefix solaris
repository description This\ repository\ serves\ a\ copy\ of\ the\ Oracle\ Solaris\ 11\ Build\ 175b\ Package\ Repository.
repository name Oracle\ Solaris\ 11\ Build\ 175b\ Package\ Repository
repository version 4
root@unixrock:~#
root@unixrock:~# pkgrecv -s http://pkg.oracle.com/solaris/release -d /unixrepo/repo/repo solarisReceiving single package on the local repository from Oracal Portal
Processing packages for publisher solaris ...
Retrieving and evaluating 4870 package(s)...
PROCESS ITEMS GET (MB) SEND (MB)
SUNWamt 0/2016 0/7768 0/25461
root@unixrock:~# pkgrecv -s http://pkg.oracle.com/solaris/release/ -d /unixrepo/repo/repo pkg://solaris/diagnostic/tcpdump@4.1.1,5.11-0.175.1.0.0.24.0:20120904T171758ZUpdating local respository with using latest SRU ( Solaris Repository Update images)
Processing packages for publisher solaris ...
Retrieving and evaluating 1 package(s)...
PROCESS ITEMS GET (MB) SEND (MB)
Completed 1/1 0.8/0.8 2.2/2.2
root@unixrock:~#
root@unixrock:/# lofiadm -a /var/tmp/sol-11_1_s11_sru11.4b.-x86.isoRemoving the package from local repository
/dev/lofi/1
root@unixrock:/# mount -F hsfs /dev/lofi/1 /mnt/repo
root@unixrock:/#
root@unixrock:/# df -h /mnt/repo
Filesystem Size Used Available Capacity Mounted on
/dev/lofi/1 357M 357M 0K 100% /mnt/repo
root@unixrock:/#
root@unixrock:/# pkg publisher
PUBLISHER TYPE STATUS P LOCATION
solaris origin online F file:///unixrepo/repo/repo/
root@unixrock:/#
root@unixrock:/# pkgrecv -s /mnt/repo/repo -d /unixrepo/repo/repo/ "*"
Processing packages for publisher solaris ...
Retrieving and evaluating 4292 package(s)...
PROCESS ITEMS GET (MB) SEND (MB)
Completed 1/1 0.0/0.0 0.0/0.0
root@unixrock:/#
root@unixrock:/# pkgrepo rebuild -s /unixrepo/repo/repo/
Initiating repository rebuild.
root@unixrock:/#
root@unixrock:/# svcprop -p pkg/inst_root svc:/application/pkg/server:default
/unixrepo/repo/repo
root@unixrock:/# svcadm restart svc:/application/pkg/server
root@unixrock:/#
root@unixrock:~# pkgrepo remove -p solaris -s /unixrepo/repo/repo/ pkg://solaris/diagnostic/tcpdump@4.1.1,5.11-0.175.1.0.0.24.0:20120904T171758ZVerifying the package and found ERROR status
Removing packages for publisher solaris ...
PHASE ITEMS
Deleting search index Done
Updating catalog Done
Analyzing removed packages 1/1
Analyzing repository packages 4619/4619
Removing package manifests 1/1
root@unixrock:~#
root@unixrock:~# pkg verify -v gzipFixing the package issue.
PACKAGE STATUS
pkg://solaris/compress/gzip ERROR
file: usr/bin/gzip
Mode: 01600 should be 0555
Unexpected Exception: Request error: class file/memory mismatch
root@unixrock:~#
root@unixrock:~#
root@unixrock:~# pkg fix gzipCool !!!! Thanks for reading this post. Please leave your valuable comments and queries, I will get back to you as much I can.
Verifying: pkg://solaris/compress/gzip ERROR
file: usr/bin/gzip
Mode: 01600 should be 0555
Unexpected Exception: Request error: class file/memory mismatch
Created ZFS snapshot: 2014-08-15-17:56:18
Repairing: pkg://solaris/compress/gzip
Creating Plan (Evaluating mediators): -
DOWNLOAD PKGS FILES XFER (MB) SPEED
Completed 1/1 1/1 0.1/0.1 0B/s
PHASE ITEMS
Updating modified actions 1/1
Updating image state Done
Creating fast lookup database Done
root@unixrock:~#
root@unixrock:~# pkg verify -v gzip
PACKAGE STATUS
pkg://solaris/compress/gzip OK
root@unixrock:~#