[OpenIndiana-discuss] Moving /var and/or /usr to own zfs filesystem

Jim Klimov jimklimov at cos.ru
Thu Sep 12 07:48:46 UTC 2013


On 2013-09-11 13:55, Ben Taylor wrote:
>> Testing is a separate and much more important point, I think: if you do
>> things the way nobody else does them, intentionally or otherwise, then
>> you're a test pilot.  Much luck, and make sure you've repacked your
>> parachute recently.
>>
>
> Well, at the time, I used your argument that it's in the man page and
> supported, and there was no announcement of removing /var from
> filesystem(5) for ZFS, among other things. Stubbornness pays off
> occasionally...

I can only comment from practice that with these setups there are two
types of problems I've seen:

1) Critical software (ksh as a symlink from /sbin/sh) becoming a file
in another dataset, due to which systems scripts like fs-mounter SMF
services, cannot run. This is fixable in a number of ways, from copying
the binary and a couple of libs into remaining rootfs, to replacing the
/sbin/sh with another shell (bash for example). After long discussions
on the list I guess the "supportable" way is to do something about the
delivery of packaged ksh into rootfs as a file (and its deps).

2) Non-empty mountpoints, i.e. rpool/ROOT/oi/usr containing a ./local
dir because at some time something misfired out of order and mounted
a /usr/local first, before getting the real /usr. These types of things
are bugs in various software (liveupgrade, beadm, OS fs-mounters) and
I believe over the years most have been weeded out. A workaround is
to set an immutable bit over such mountpoints to keep them empty.
Some software may whine; for example, this breaks things if used on
/var/tmp. But mostly this is quite workable.


The "bonuses" to split-root are in my case ability to compress (usr
with gzip-9 shrinked almost 3x for me on a number of installations),
which is less relevant now with support of bootable compressed datasets
(LZ4 at least), and micromanagement of quotas/reservations on (shared)
sub-directories (as datasets) of /var, as my bugtracker/wiki posts
detail.

Ability to mount stuff properly (via parent-child datasets of rootfs
or via /etc/vfstab) is buried in the SMF scripts and easily fixed on
a live system. I think my hopes to integrate got lost in the source
structure - where should my relevant updates be applied for the gate?
Since there was little interest at that time, I did not look deeper;
if there is interest now - I can revive my attempts and "mods" :)

//Jim



More information about the OpenIndiana-discuss mailing list