Please review these changes for fixing bug 1530. bug: http://defect.opensolaris.org/bz/show_bug.cgi?id=1530 webrev: http://cr.opensolaris.org/~tmueller/ips-1530.1/
This change eliminates the traceback by checking to see if the owner and group for every file and directory action exists in the preinstall method of the actions. The fix takes into account having user and group actions in the same install set, so the user and group actions have to record what is going to happen in the imageplan. Also, the preinstall actions have to be executed in the same order as the install actions so that the user/group changes are recorded before the file/dir actions are checked.
There are two new exceptions that inherit from ActionExecutionError, UnknownUser and UnknownGroup.
The api version is advanced because the ImageInterface.prepare method can now through an ActionExecutionError exception. I advanced the API client version in the GUI code because it handles exceptions from the prepare method the same way as it handles exceptions from execute_plan. However, I noticed that it doesn't seem to handle ActionExecutionErrors directly, which is really a problem unrelated to this particular bug.
For a full image, not having a user or group is considered an error. pkg(1) now prints a message and returns 1. However, for a user image where the user is unable to change the ownership of a file anyway, not having the required user/group is ignored.
Thanks. Tom _______________________________________________ pkg-discuss mailing list [email protected] http://mail.opensolaris.org/mailman/listinfo/pkg-discuss
