5 Replies Latest reply: Jan 7, 2010 11:03 AM by 807567 RSS

    Live Upgrade and Patch installation

    807567
      I am running Solaris 10 10/08 (update 6) with a ZFS
      root file system.

      I created a new boot environment (BE) and then tried
      to apply a .jar form patch from /var/sadm/spool using
      the luupgrade command:

      /usr/sbin/luupgrade -t -n zfsbe_test \
      -s /var/sadm/spool 138627-05.jar

      with this result:

      Validating the contents of the media </var/sadm/spool>.
      ERROR: The media </var/sadm/spool> does not contain any software
      patches that can be installed.

      BTW, I tried it both with and without the .jar on the patch,
      wit the same result.

      If the luupgrade command will not accept .jar form
      patches -- downloaded with "smpatch download"
      what good is it? Or if .jar patches are not currently
      supported then how do I extract the patch from
      the jar file?

      Thanks...

      -- Bob
        • 1. Re: Live Upgrade and Patch installation
          807738
          Since you used smpatch to download the patches, why not use it to apply them, too? (-b option to apply to an ABE--see the man page)
          • 2. Re: Live Upgrade and Patch installation
            807567
            Good idea, save for the fact that "smpatch add" fails with this error:

            Ckecking the currently running boot enviornment ...
            Currently running boot enviornment name is [zfsbe02].
            Checking the destination boot environment [zfsbe03] ...
            Copying the cuurently running BE into inactive BE [zfsbe03] ...
            This grogess will take you a long time, please wait a moment.)
            ERROR: File systems on ABE <zfsbe03> have insufficient space for repopulation from boot environment <zfsbe02>. It is recommended to delete this BE and create a fresh BE.
            /usr/sbin/lumake: lumake into zfsbe03 failed

            The add does a lumake under the covers -- which doesn't make sense,
            and despite the fact there's sufficient space in the BE, it fails. Or am
            I missing something?

            I opened a SunSolve case and this is a known problem and there's
            a RFE (bugid 6267332) to allow it to use .jar files.

            Thanks for the suggestion though...

            -- Bob

            Edited by: rkbunca on Feb 25, 2009 1:39 PM
            • 3. Re: Live Upgrade and Patch installation
              807738
              You can, BTW, apply patches that are distributed in jar files in the old 'patchadd' way. Just un-jar them:

              # jar xfv 123456.01.jar

              # patchadd -R /path/to/BE/you/mounted 123456-01

              I have found some patch sets packaged this way have incorrect permissions on the pre- and/or post-patch scripts; patchadd will tell you this.
              • 4. Re: Live Upgrade and Patch installation
                807567
                You can, BTW, apply patches that are distributed in jar files in the old 'patchadd' way. Just un-jar them:

                # jar xfv 123456.01.jar

                # patchadd -R /path/to/BE/you/mounted 123456-01
                That is an option, but I was trying to find a way to use a single
                command, say smpatch, to do it all. The two step process
                you recommend would work, I guess, but like I said, it just
                adds a level of complexity that the the purported benefits
                of a ZFS root and Live Upgrade were supposed to
                eliminate. Thanks for the suggestion though.
                I have found some patch sets packaged this way
                have incorrect permissions on the pre- and/or
                post-patch scripts; patchadd will tell you this.
                Interesting. I was having a problem just getting the jar
                command to extract the patch. I'd use the "jar tv"
                with one of the patches and it would just sit there.
                It was only when I moved the .jar file to /var/tmp
                that the extract or list options would work. Very weird.
                • 5. Re: Live Upgrade and Patch installation
                  807567
                  Dear Bob,

                  did you find a solution to the inital problem: "ERROR: The media </var/sadm/spool> does not contain any software patches that can be installed." ?

                  I had the same trouble with "smpatch download" Signed Patches and found that unpacking prior to 'luupgrade -t' solved it:

                  # cd /var/sadm/spool
                  # ls *.jar | xargs -n 1 -exec unzip -n

                  Then patching with this command worked for me:

                  # luupgrade -t -n ABE -s /var/sadm/spool `cat patch_order`

                  Greetings
                  Martin