[OpenIndiana-discuss] Split-root installations
Peter Tribble
peter.tribble at gmail.com
Tue Nov 26 22:51:33 UTC 2013
On Tue, Nov 26, 2013 at 10:19 PM, Jim Klimov <jimklimov at cos.ru> wrote:
>
> I wonder how (un)acceptable would it be to enhance the fs-root script
> instead - when it makes sure that /usr/bin is available (the /usr is
> mounted), it could invoke "svcadm restart" of the active instance of
> the network/physical service (if any) and perhaps iptun which depends
> on this. This would probably be proper after the script calls devfsadm
> to detect devices for newly mounted drivers (which may include more
> NICs than were available on rootfs).
>
Here, you're solving the wrong problem. Just put the drivers in the right
place from the start. I've never understood why drivers were scattered.
> In the end, I think this problem boils down to specific cases with
> opposite dependencies, since the "clean" way to do this is with SMF
> somehow:
>
> 1) / and /usr are local (ZFS, UFS, whatever) and don't depend on the
> network (NFS, iSCSI, whatever) - then "network/physical" should depend
> on "filesystem/root";
>
> 2) these filesystems (both or one) depend on networking to be active
> and provided by the OS (i.e. GRUB which TFTP/PXE-boots a miniroot over
> LAN is probably not the use-case) - then the filesystems' SMF services
> should depend on networking services.
> Although it can be argued that /etc/fs/nfs/mount depends on at least
> /usr/lib/libsmbios.so.1, so the miniroot which boots the server and
> mounts the NFS root would (by default) have some /usr of its own...
>
The miniroot for any live or network boot already has a chunk
of /usr. There's a real problem here in that there simply isn't a clean
separation of root vs usr any more. If you really want to have
a supportable separate /usr, then you're going to have to work
through the entire system architecture working out which file
goes where and why. And then what you discover is that you
thought you were splitting off /usr, but all you've really done
is created a couple of other things that really ought to be
in /usr but have to be split from it (namely /sbin and /lib) so
where you had one problem you now have three, plus a bunch
of extra stuff that has to be duplicated in the miniroot.
(As an aside, I would really like to go back to the days where /lib
was a symlink to /usr/lib, and things were much cleaner. But that
ship sailed, and I fear it's not coming back.)
Ultimately, these can be (and are) different "root" service instances
> which can have very different dependency graphs...
>
The live boot has a bunch of logic to run different services
depending on how it booted, not entirely dissimilar in approach
to what you've outlined above (but for different reasons). It's a
nightmare.
> What would the esteemed community experts suggest?
>
>
My worry here is that you're adding complexity to an already
complex system; instead, we need significant simplification.
--
-Peter Tribble
http://www.petertribble.co.uk/ - http://ptribble.blogspot.com/
More information about the OpenIndiana-discuss
mailing list