I just saw a bunch of goodness put back by Jerry - yippeee!!!


I am a bit confused by the way that /etc/release is handled:

+       if (update_res == Z_OK) {
+               /* Install the new /etc/release file. */
+               (void) snprintf(cmdbuf, sizeof (cmdbuf),
+                   "exec /usr/sbin/zlogin -S %s "
+                   "'/usr/bin/cat >/a/etc/release' </etc/release", zonename);
+               status = do_subproc(cmdbuf);
+               if (subproc_status("/etc/release", status, B_TRUE)
+                   != ZONE_SUBPROC_OK) {
+                       (void) fprintf(stderr, gettext("could not update "
+                           "zone\n"));
+                       update_res = Z_ERR;
+               }
+       }

Why take this approach rather than changing or overriding the
SUNW_PKG_ALL_ZONES attribute on SUNWsolnm? It seems as though the
approach taken will make it so that the package version doesn't match
up with the release and pkgchk will complain about /etc/release in
non-global zones that have been updated to a newer release.

Without knowing any of the back story and assuming that changing
SUNW_PKG_ALL_ZONES on an already installed package is really bad to
do, it seems as though this could be better handled with a hook here:

  1116                  } else if (strcmp(buf, SUNW_PKG_ALL_ZONES) == 0) {
  1117                          infop->zpi_all_zones = B_TRUE;

My thought is that if the package name is SUNWsolnm,
infop->zpi_all_zones should be B_TRUE.

Mike Gerdts
zones-discuss mailing list

Reply via email to