Hi Steve,
On 10/18/12 08:24 AM, Steve Christensen wrote:
I have had some questions on my IPS packages. The installation of
several packages - in /usr/local directories - goes fine. But when a
user does an uninstall on just one of the packages, the entire
/usr/local directory gets removed, not just the files in the packages.
How do I prevent this?
Apparently, the /usr/local directory existed before the install of any
of my packages.
pkg(5) removes a directory once it has no more references to that
directory in the packaging system.
So the easiest way to prevent removal of the dir, is to leave an IPS
package on the system that still delivers /usr/local, so when your other
packages are removed, IPS still has a reference to that directory.
[ if a directory previously existed and wasn't packaged, but a package
gets installed that now references that directory, then IPS assumes
ownership of the directory ]
The pkg(5) man page covers this somewhat:
---
Directories are reference counted in IPS. When the last
package that either explicitly or implicitly references a
directory no longer does so, that directory is removed. If
that directory contains unpackaged file system objects,
those items are moved into $IMAGE_META/lost+found. See the
"Files" section for more information about $IMAGE_META.
---
cheers,
tim
_______________________________________________
pkg-discuss mailing list
[email protected]
http://mail.opensolaris.org/mailman/listinfo/pkg-discuss