by Ras
9. April 2012 21:41
Solaris Package management, package installation or removal
To use installer from a share location
# installer- shell script that runs with text/GUI interfaces installer is located on Solaris DVD
installer script is on Software companion DVD
Add the below command to /etc/dfstab ,you can create an NFS share of the folder
# share -F nfs -o ro,anon=0 /export/home/SolarisCompanion
and then "exportfs -a" will export the shares
on the other machine mount remote servers NFS sharepoint for Solaris Companion DVD
# mount -F nfs linuxcbtsun2:/export/home/SolarisCompanion /mnt
Then run the ./installer from the path
# ./installer -nodisplay runs the installer without GUI
# prodreg -- shows the registered/installed packages on Solaris and provide some information and dependancy about them
### pkg
pkg|info|add|rm|chk
#pkginfo - dumps to STDOUT all installed packages - category, name, desc
#pkginfo -l [package_name] - return details info about the package
#pkginfo -x -return an extracted list of packages - abbreviation, name, arch, version
#pkginfo -q - queries for a package and returns exit status (if installed returns 0, if not installed returns non 0)
#pkginfo -i|-p - returns fully/partially installed packages
#pkgchk - Checks the integrity of a package e.g. with files and directories
#pkgchk -v [pkg_name] - Checkes/lists files included with the pkg_name
#pkgchk -v [pkg1],[pkg2]
#pkgchk -lp /opt/sfw/bin/bluefish - returns the package that 'bluefish' file belongs to
#pkgchk -ap /opt/sfw/bin/bluefish - audits the permissions on the file 'bluefish'
#pkgchk -fp /opt/sfw/bin/bluefish - restore permissions to values in database on the file
#pkgchk -cp - audits the content of the file based on sum information
#pkgchk -q - returns usable exit status
Common Solaris Package online repositories
1. www.sunfreeware.com
2. www.blastwave.org - www.blastwave.org/mirrors.php
3. www.sun.com
#pkgadd -d pkg_name - installs from the current diretory or spool directory (/var/spool/pkg)
#pkgadd -d pkg1|pkg2 -s /var/spool/pkg -will transfer the pkg1 and pkg2 to spool directory
#pkgadd - this will install programs in the spool directory, will ask about the available packages at spool dir
#pkgadd -d URL/pkgg_name
#pkgrm pkg_name - remove the package