Tag: Package manager

Sparc Solaris 10 Jumpstart Flar DVD – Part 1

The Solaris Flash installation feature enables you to use a single reference installation of the Solaris OS on a system, which is called the master system. Then, you can replicate that installation on a number of systems, which are called clone systems. You can replicate clone systems with a Solaris Flash initial installation that overwrites all files on the system or with a Solaris Flash update that only includes the differences between two system images. A differential update changes only the files that are specified and is restricted to systems that contain software consistent with the old master image.

By combining Flash installation with Custom Jumpstart, and packaging all that on a re-mastered Solaris installation DVD, you can create very fast and efficient, standalone, and automated installation media.

I ran into several issues trying to create such a DVD when following the standard Google results so I thought I’d summarize my experiences. This is a work in progress- I might hit a brick wall at some point, but I hope not.

First, I built the prototype system. I’m running Solaris 10 11/06 with one non-global zone based entirely on a ZFS file system. This will make things challenging since Solaris Flash Archives are not completely compatible (or even supported) for these kinds of configurations and Jumpstart is not ZFS aware.

Creating the Flash Archive

  1. Make sure you have the right packages installed (SUNWinst, SUNWadmc, SUNWadmfw, SUNWbtool) Theoretically, you should install platform support for all possible hardware- I forget the name of the cluster- but if you will only be installing on the same hardware, this isn’t necessary. NOTE- If you try to install packages from inside single user mode with non-global zones it will give you issues.
  2. Put the prototype system into single user mode
  3. Create a text file, called for example ‘exclude’, with the directories not to include in the flash archive (man flarcreate)
  4. flarcreate -n system -X exclude -c system.flar
    Full Flash
    Checking integrity...
    Integrity OK.
    Running precreation scripts...
    Precreation scripts done.
    Determining the size of the archive...
    cpio: File size of "etc/mnttab" has decreased by 136
    2259925 blocks
    1 error(s)
    The archive will be approximately 764.41MB.
    Creating the archive...
    2259925 blocks
    Archive creation complete.
    Running postcreation scripts...
    Postcreation scripts done.

    Running pre-exit scripts...
    Pre-exit scripts done.
  5. Verify your archive: flar info -l system.flar

More to come…

CFEngine in mixed Solaris, Linux, environments

If you’ve ever tried to use CFEngine for package management, you know that it is basically useless.

  1. CFEngine only supports installing packages and not removing them (yet).
  2. It has some crazy limit defined at compilation time which limits the number of packages you can install. (see Google://cfengine “Too many arguments in embedded script”)
  3. It merges all your package work into one logical section even if you logically split up the sections and had them in a certain order etc.
  4. etc.

What comes out of all this is that you are better off using repository aware package management tools via the shellcommands actions (IMHO).

In the case of Solaris, the choice of champions seems to be pkg-get ala bolthole and blastwave.
In the case of Debian/Ubuntu, use apt-get.
This also means you no longer need to copy your package files using the cfengine copy actions since these tools will automatically retrieve them from your custom repository.

For those wanting to set up a pkg-get repository, the makecontents script should help you on your way.

showrev(1M) missing on Solaris 10

Today I realized I was missing the showrev command on a Solaris 10 machine I installed.
I found it in the SUNWadmc package but recieved the following error:

ld.so.1: showrev: fatal: libadmapm.so.2: open failed: No such file or directory

Then I found the following page:
showrev(1M) missing on Solaris 8
Adding the SUNWadmfw package as mentioned still left me with the following error:

ld.so.1: showrev: fatal: libadmutil.so.2: open failed: No such file or directory

It turns out I was missing the SUNWadmlib-sysid package.

SUMMARY

If you are missing showrev check if you have the following packages:
SUNWadmlib-sysid SUNWadmc SUNWadmfw

Good luck!