From: Glenn on
Before I tried actually updating my recent OpenSolaris install,
I thought I'd cautiously put my toe in the water. I got back:

# pkg image-update -n
Creating Plan |Traceback (most recent call last):
File "/usr/bin/pkg", line 1440, in ?
ret = main_func()
File "/usr/bin/pkg", line 1404, in main_func
return image_update(img, pargs)
File "/usr/bin/pkg", line 366, in image_update
noexecute = noexecute)
File "/usr/lib/python2.4/vendor-packages/pkg/client/image.py", line
1282, in make_install_plan
ip.evaluate()
File "/usr/lib/python2.4/vendor-packages/pkg/client/imageplan.py",
line 344, in evaluate
self.evaluate_fmri(f)
File "/usr/lib/python2.4/vendor-packages/pkg/client/imageplan.py",
line 187, in evaluate_fmri
m = self.image.get_manifest(pfmri)
File "/usr/lib/python2.4/vendor-packages/pkg/client/image.py", line
516, in get_manifest
m = self._fetch_manifest(fmri)
File "/usr/lib/python2.4/vendor-packages/pkg/client/image.py", line
468, in _fetch_manifest
mcontent = retrieve.get_manifest(self, fmri)
File "/usr/lib/python2.4/vendor-packages/pkg/client/retrieve.py",
line 81, in get_manifest
raise NameError, "could not retrieve manifest '%s' from '%s'" % \
NameError: could not retrieve manifest 'SUNWgnome-l10nmessages-
fr(a)0.5.11%2C5.11-0.91%3A20080613T181516Z' from 'http://
pkg.opensolaris.org:80'

A repeated attempt gives a similar result:

NameError: could not retrieve manifest 'SUNWxorg-
doc(a)0.5.11%2C5.11-0.91%3A20080613T174834Z' from 'http://
pkg.opensolaris.org:80'

Is this sort of failure common for other people as well?
What state would my system have been left in had this occurred
during an actual update?

Secondarily, what's the command to update just a given single
package to its latest version? I don't see any option for this in
the pkg(1) man page.
From: Chris Ridd on
On 2008-06-21 17:18:02 +0100, Glenn <eponymousalias(a)yahoo.com> said:

> Secondarily, what's the command to update just a given single
> package to its latest version? I don't see any option for this in
> the pkg(1) man page.

I think you just have to just specify the FMRI you want to update, viz:

pkg install pkg:/SUNWipkg(a)0.5.11,5.11-0.90

Presumably you could append the full timestamp to the end if the same
version came out multiple times.

I don't know how you'd back out to a previous instance of a package
though. For instance, after updating SUNWipkg as suggested in David
Orman's message, pkg image-update now just gives a stack trace:

bash-3.2# pkg image-update -nv
Traceback (most recent call last):
File "/usr/bin/pkg", line 1458, in ?
ret = main_func()
File "/usr/bin/pkg", line 1422, in main_func
return image_update(img, pargs)
File "/usr/bin/pkg", line 365, in image_update
verbose = verbose, noexecute = noexecute)
File "/usr/lib/python2.4/vendor-packages/pkg/client/image.py", line
1280, in make_install_plan
self.load_optional_dependencies()
File "/usr/lib/python2.4/vendor-packages/pkg/client/image.py", line
1021, in load_optional_dependencies
self.update_optional_dependency(min_fmri)
File "/usr/lib/python2.4/vendor-packages/pkg/client/image.py", line
989, in update_optional_dependency
matcher = pkg.fmri.exact_name_match)[0]
File "/usr/lib/python2.4/vendor-packages/pkg/client/image.py", line
403, in get_matching_fmris
raise KeyError, "packages matching '%s' not found in catalog or image" \
KeyError: "packages matching 'pkg:/CPANauthen-sasl' not found in
catalog or image"

Curiously the package mentioned at the end is from my local repo, even
though my preferred authority is opensolaris.org.

Cheers,

Chris

From: Thommy M. on
Glenn wrote:
> Before I tried actually updating my recent OpenSolaris install,
> I thought I'd cautiously put my toe in the water. I got back:
>
> # pkg image-update -n
> Creating Plan |Traceback (most recent call last):
> File "/usr/bin/pkg", line 1440, in ?
> ret = main_func()
> File "/usr/bin/pkg", line 1404, in main_func
> return image_update(img, pargs)
> File "/usr/bin/pkg", line 366, in image_update
> noexecute = noexecute)
> File "/usr/lib/python2.4/vendor-packages/pkg/client/image.py", line
> 1282, in make_install_plan
> ip.evaluate()
> File "/usr/lib/python2.4/vendor-packages/pkg/client/imageplan.py",
> line 344, in evaluate
> self.evaluate_fmri(f)
> File "/usr/lib/python2.4/vendor-packages/pkg/client/imageplan.py",
> line 187, in evaluate_fmri
> m = self.image.get_manifest(pfmri)
> File "/usr/lib/python2.4/vendor-packages/pkg/client/image.py", line
> 516, in get_manifest
> m = self._fetch_manifest(fmri)
> File "/usr/lib/python2.4/vendor-packages/pkg/client/image.py", line
> 468, in _fetch_manifest
> mcontent = retrieve.get_manifest(self, fmri)
> File "/usr/lib/python2.4/vendor-packages/pkg/client/retrieve.py",
> line 81, in get_manifest
> raise NameError, "could not retrieve manifest '%s' from '%s'" % \
> NameError: could not retrieve manifest 'SUNWgnome-l10nmessages-
> fr(a)0.5.11%2C5.11-0.91%3A20080613T181516Z' from 'http://
> pkg.opensolaris.org:80'
>
> A repeated attempt gives a similar result:
>
> NameError: could not retrieve manifest 'SUNWxorg-
> doc(a)0.5.11%2C5.11-0.91%3A20080613T174834Z' from 'http://
> pkg.opensolaris.org:80'
>
> Is this sort of failure common for other people as well?
> What state would my system have been left in had this occurred
> during an actual update?
>
> Secondarily, what's the command to update just a given single
> package to its latest version? I don't see any option for this in
> the pkg(1) man page.


There's a lot of discussion on this going on in the OpenSolaris forums
like gmane.os.solaris.opensolaris.indiana available as nntp feed from
news.gmane.org


I think it would be beneficial if discussions on OpenSolaris 2008.05
could be held there and keeping comp.unix.solaris for more Solaris/SunOS
production related stuff. But that's just my opinion at the moment
seeing how things are getting mixed up between the different distributions.



On the topic though, I've had the same problem and there are some
updates to run to get things running smoothly. Here's one way to do it...

$ pfexec pkg refresh
$ pfexec pkg install pkg:/SUNWipkg(a)0.5.11,5.11-0.86
$ pfexec pkg refresh
$ pfexec pkg image-update
$ pfexec mount -F zfs rpool/ROOT/opensolaris-1 /mnt
$ pfexec /mnt/boot/solaris/bin/update_grub -R /mnt
$ pfexec init 6
From: Glenn on
> > Secondarily, what's the command to update just a given single
> > package to its latest version? I don't see any option for this in
> > the pkg(1) man page.
>
> I think you just have to just specify the FMRI you want to update, viz:
>
> pkg install pkg:/SUNWi...(a)0.5.11,5.11-0.90
>
> Presumably you could append the full timestamp to the end if the same
> version came out multiple times.

If that's so, then the pkg(1) man page needs to be modified.
The "pkg install" entry doesn't mention anything about updating
an already-installed package, thereby leaving the impression
that it's only applicable if the package is not installed.

From: Glenn on
On Jun 21, 11:12 am, Glenn <eponymousalias(a)yahoo.com> wrote:
> > > Secondarily, what's the command to update just a given single
> > > package to its latest version? I don't see any option for this in
> > > the pkg(1) man page.
>
> > I think you just have to just specify the FMRI you want to update, viz:
>
> > pkg install pkg:/SUNWi...(a)0.5.11,5.11-0.90
>
> > Presumably you could append the full timestamp to the end if the same
> > version came out multiple times.
>
> If that's so, then the pkg(1) man page needs to be modified.
> The "pkg install" entry doesn't mention anything about updating
> an already-installed package, thereby leaving the impression
> that it's only applicable if the package is not installed.

That impression is further solidified by the following:

# pkg list SUNWpkgcmds
NAME (AUTHORITY) VERSION
STATE UFIX
SUNWpkgcmds 0.5.11-0.86
installed u---
# pkg install SUNWpkgcmds
Nothing to install in this image (is this package already installed?)

If "pkg install" is intended also for package updates,
I would expect this last message to say something like
"SUNWpkgcmds is up to date" rather than suggesting
that "pkg install" was inappropriately attempted.