This discussion is archived
5 Replies Latest reply: Mar 28, 2009 12:34 AM by 807567 RSS

pkgadd: ERROR: unable to open temporary contents file image

807738 Newbie
Currently Being Moderated
# smpatch analyze
139558-03 SunOS 5.10: libpicldevtree patch
139500-03 SunOS 5.10: openssl patch
138324-03 SunOS 5.10: uata driver patch
119117-49 Evolution 1.4.6 patch
125719-17 X11 6.8.0: Xorg server patch
119213-18 NSS_NSPR_JSS 3.11.10: NSPR 4.7.1 / NSS 3.11.10 / JSS 4.2.6

'smpatch update' fails on all of these with:

Installing patches from /var/spool/pkg/patchpro/...
Failed to install patch 139558-03.

Utility used to install the update failed with exit code 5.
Checking installed patches...Verifying sufficient filesystem capacity (dry run method)...Installing patch packages...Pkgadd failed. See /var/tmp/139558-03.log.23362 for detailsPatchadd is terminating.
Transition old-style patching.
Failed to install patch 139558-03

$ cat /var/tmp/139558-03.log.23362

This appears to be an attempt to install the same architecture and
version of a package which is already installed. This installation
will attempt to overwrite this package.

Dryrun complete.
No changes were made to the system.

This appears to be an attempt to install the same architecture and
version of a package which is already installed. This installation
will attempt to overwrite this package.

Dryrun complete.
No changes were made to the system.

This appears to be an attempt to install the same architecture and
version of a package which is already installed. This installation
will attempt to overwrite this package.

pkgadd: ERROR: unable to open temporary contents file image
(errno 11: Resource temporarily unavailable)

Installation of <FJSVpiclu> failed (internal error) - package
partially installed.

The patch log has the same "pkgadd: ERROR: unable to open temporary contents file image" error for each one of the failed installs.
  • 1. Re: pkgadd: ERROR: unable to open temporary contents file image
    807567 Newbie
    Currently Being Moderated
    This message means that your /tmp or /var/tmp has ran out of space. Try clearing some space in these directories and try patching again.
  • 2. Re: pkgadd: ERROR: unable to open temporary contents file image
    807738 Newbie
    Currently Being Moderated
    Well, it's not disk space, but rather virtual memory that's the issue. Clearing disk space and setting $TMPDIR to point somewhere else where there were wide open spaces won't do. Adding a GB of temporary swap (i.e., mkfile 1g foo; swap -a foo) did.

    Thanks

    P.S. Does this mean traditional rules of thumb about setting up swap space at install time are now out the window if you want to use smpatch and friends?
  • 3. Re: pkgadd: ERROR: unable to open temporary contents file image
    807567 Newbie
    Currently Being Moderated
    Thanks for the follow up on this. How much (or little) swap space did you have? Was the system under load at the time you were attempting to apply these patches?

    As for rules of thumb, there is no one-size-fits-all solution - it all depends on what the system is going to be used for. You might be better posing that question in a more general Solaris OS forum.
  • 4. Re: pkgadd: ERROR: unable to open temporary contents file image
    807738 Newbie
    Currently Being Moderated
    It's a Blade-1500, 1GB RAM, 1GB swap. Desktop machine. Web browser, Thunderbird, OpenOffice, and Adobe Reader open--not doing much of anything else. As noted, adding another GB of temporary swap allowed the patches to install.

    My comment really has to do with what are, after all, pretty hefty requirements that smpatch and friends seem to have, and would seem appropriate to this forum.

    Thanks.
  • 5. Re: pkgadd: ERROR: unable to open temporary contents file image
    807567 Newbie
    Currently Being Moderated
    Sorry, my suggestion was really about the rule of thumb.

    One of our test systems, which isn't used as a desktop has much less swap (around 640MB) and this allows it to patch quite happily. It is likely that the applications that you have open are using a lot of your RAM and swap. We typically see Firefox, Thunderbird and Acrobat reader using between 100-250MB, OpenOffice often weighs in at over 300MB - add that to the overhead of your desktop and you are already starting to eat into your swap space.

    I wouldn't say that smpatch is heavy at all, although updatemanager might well be heavier in use. You might want to verify how much swap space is being used before launching the next time - use `swap -s` or if you have it installed, `top`.

    From this I would say that you may well ought to be using at least 2GB of swap space on a system that is used as a desktop unless you are happy to add a temporary swap file or just close down some of those applications as required. Let us know what you find.