[Solaris 11 Express] Configure IPS Repository Server

Setting up a local IPS Repository to be used by clients on a LAN is simpler than I thought with Solaris 11 Express and can be done using the following steps:

  1. Download Oracle Solaris Express 11 Express Repository Images
  2. Copy Repository data from ISO locally
  3. Configure the Solaris 11 IPS Repository Server
  4. Configure Client(s) to use the Repository Server

I will not go into much detail on how to download and mount the ISO image, but the image repository iso may be downloaded from the Oracle Website. The repository image may be split and should be concatenated before the ISO is configured with lofiadm and mounted with mount respectively.

Download Oracle Solaris Express 11 Express Repository Images

The images are downloaded from the Oracle website and can be prepared for mounting by doing:

$ unzip sol-11-exp-201011-repo-full-iso-a.zip
$ unzip sol-11-exp-201011-repo-full-iso-b.zip
$ cat sol-*[ab] > sol-11-exp-201011-repo-full.iso 

Copy Repository data from ISO locally

First create a location to store the repository data (i.e., /ips/sol11exp), then rsync the ISO contents. Provided the ISO has been mounted under /mnt/ copy the repo/ sub-folder under /ips/sol11exp/

# zfs create rpool/ips
# zfs set mountpoint=/ips rpool/ips
# mkdir /ips/sol11exp
# rsync -avz /mnt/repo /ips/sol11exp/

Configure the Solaris 11 IPS Repository Server

Once the full repository from ISO/DVD has been copied locally we need to configure the ‘pkg/server’ service which will listen on the default HTTP port (80) for client requests.

# svccfg -s application/pkg/server setprop pkg/inst_root=/ips/sol11exp/repo
# svccfg -s application/pkg/server setprop pkg/readonly=true

Refresh and start pkg.depotd

# svcs -a | grep pkg/server
disabled        9:40:28 svc:/application/pkg/server:default

# svcadm refresh application/pkg/server
# svcadm enable application/pkg/server

# svcs -a | grep pkg/server
online          7:05:34 svc:/application/pkg/server:default

Configure Client(s) to use the Repository Server

Add our new publisher, using the ORIGIN, http://blackice.goldcoast.com, and make it Preferred

# pkg set-publisher -P -g http://blackice.goldcoast.com solaris

Our list of publishers should now like:

# pkg publisher
PUBLISHER                             TYPE     STATUS   URI
solaris                  (preferred)  origin   online   http://blackice.goldcoast.com/
solaris                  (preferred)  origin   online   http://pkg.oracle.com/solaris/release/

# pkg publisher solaris

            Publisher: solaris
           Origin URI: http://blackice.goldcoast.com/
              SSL Key: None
             SSL Cert: None
           Origin URI: http://pkg.oracle.com/solaris/release/
              SSL Key: None
             SSL Cert: None
          Client UUID: 3h734564-80i4-11e0-bfb6-102219147c44
      Catalog Updated: November 12, 2010 07:24:25 PM
              Enabled: Yes

Oh, and rebuild the index!

# pkg rebuild-index

PHASE                                          ITEMS
Indexing Packages                             73/496

Note: With this current version of Solaris 11 Express the local repository is not not searchable. For example you cannot, yet, perform on the local repository just added. :

# pkg search zsh
pkg: Some repositories failed to respond appropriately:
http protocol error: code: 503 reason: Service Unavailable
URL: 'http://blackice.goldcoast.com/search/1/False_2_None_None_%3A%3A%3Azsh'.

The remote Oracle repository is searchable.

This entry was posted in *Nix. Bookmark the permalink.

10 Responses to [Solaris 11 Express] Configure IPS Repository Server

  1. Dave Walker says:

    Works a treat. Thanks a bunch for posting :-).

  2. Pingback: EpiJunkie » pkg.oracle.com is down; I need some packages, what do I do now?

  3. EpiJunkie says:


    Thanks for the blog entry, it got me started so I could reinstall o151a on my NAS. pkg.oracle.com has been down all weekend.

    Also you’ll be able to search your local repository by issuing this command:
    # pkgrepo -s /ips/sol11exp/repo refresh


  4. Emil says:

    Tried, and it fails:
    pkg.file_layout.file_manager.NeedToModifyReadOnlyFileManager: The FileManager cannot create /ips/sol11exp/repo/file because it is configured read-only.
    Apparently, it needs “Writable root” property to be set.
    Are you soure, that “svccfg -s application/pkg/server setprop pkg/readonly=true” is really required?
    Thanks in advance for comments and tips on hos to get this working.

  5. valverjose says:

    Great … it works with sol-11-1111-repo-full.iso …. too

    but need to do this in client side , if the client didn’t have internet connection :

    # pkg publisher
    # pkg unset-publisher solaris
    # pkg set-publisher -P -g http://solreposvr solaris
    # pkg rebuild-index

    Thanks for sharing …

  6. abbaspour says:

    Thanks. This is useful. But is missing one step. In order to tell pkg to use only local IPS repository need this step:
    # pkg set-publisher -G ‘*’ -g http:// solaris

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s