nixCraft Poll

Topics

Solaris > Add / Install new software packages

Posted by Vivek Gite [Last updated: February 1, 2005]

Package can be install from CDROM, Network i.e. NFS or downloading from Internet and then add it to system, or from existing location such as /var/spool/pkg directory if frequently required packages are copied to this location.

Solaris: Adding package from CDROM
1) Mount cdrom

2) To add or install GNU tar package from Solaris CD use command
# pkgadd -d /cdrom/cdrom0/Solaris_9/Product SUNWgtar

Where,
-d /cdrom/cdrom0/Solaris_9/Product: Specify package directory
SUNWgtar: Package name

Solaris: Adding packages to spool directory and then install them
1) Copy package to /var/spool/pkg directory first:
# pkgadd -d /cdrom/cdrom0/Solaris_9/Product -s /var/spool/pkg SUNWgtar
Transferring package instance

Where,
-d /cdrom/cdrom0/Solaris_9/Product: Specify package directory
-s /var/spool/pkg : Directory in which package will get stored
SUNWgtar: Package name

2) Install the packages copied to spool directory
# pkgadd SUNWgtar

Solaris: Install downloaded package
1) If your package is in .bz2 format then first uncompress it using bunzip2 command:
# bunzip2 Packagname.bz2

2) Install package:
# pkgadd –d Packagname

Note .bz2 extension will automatically removed by first command.

For example if your package name is SFWqt.bz2
# buzip2 SFWqt.bz2
# pkgadd –d SFWqt

Want to stay up to date with the latest Linux tips, news and announcements? Subscribe to our free e-mail newsletter or RSS feed to get all updates. You can Email this page to a friend.

You may also be interested in other helpful articles:

Discussion on This Article:

  1. Srki Says:

    Hi.

    # pkgadd –d SFWqt

    When is allowed not to use
    directory name with -d option?

    – package located in a current directory or
    there is some other exception ?

    How generally pkgadd interprets -d option with or without directory name -
    when only package name is listed?

    Thanks

  2. nixcraft Says:

    pkgadd –d SFWqt

    It means package is in current directory which was downloaded from ftp/http sites

Leave a Reply

We encourage your comments, and suggestions. But please stay on topic, be polite, and avoid spam. Thank you very much for stopping by our site!

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

*
To prove you're a person (not a spam script), type the security word shown in the picture. Click on the picture to hear an audio file of the word.
Click to hear an audio file of the anti-spam word

Copyright © 2004-2008 nixCraft. All rights reserved - TOS/Disclaimer - Privacy policy - Sitemap - Powered by Open source software.