Hey Kugutsumen,

Kugutsumen wrote:
> Ref: http://blogs.sun.com/timf/entry/zfs_bootable_datasets_happily_rumbling
> Ref: http://mediacast.sun.com/share/timf/zfs-actual-root-install.sh
> 
> This is my errata for Tim Foster's zfs root install script:

Thanks for the edits, much appreciated.  I'm up to my eyes at the
moment, but would definitely like to test out your suggested changes
across a few different machines to make sure they're sane before adding
them to the script - they look okay to me on 1st inspection.

I wrote the script based on the instructions at
http://opensolaris.org/os/community/zfs/boot/zfsboot-manual/ so I guess
we'd need to mention your changes there too.


I believe the ultimate aim for ZFS root is to have separate filesystems
as you suggest - eg.
http://blogs.sun.com/lalt/entry/zfs_boot_issue_of_the - but in the
meantime, if folks do need to have separate filesystems, it looks like
your addendums will sort that out.

Personally, I like the simplicity involved in having a single dataset
for root  - creating root clones with a single command is lovely, so
perhaps we just need a single command to do that in the face of
multiple filesystems! (which I'm sure is the eventual plan)

I do understand why folks carve things up though - so long as kernel
and userland filesystems are always cloned/upgraded at the same time,
what could possibly go wrong! ;-)

        cheers,
                        tim

> 1/ Correct mode for /tmp should be 1777.
> 
> 2/ The zfs boot install should allow you to have /usr on a separate zpool:
> 
>       a/ We need to create /zfsroot/usr/lib in the root partition and copy 
> /usr/lib/libdiskmgt.so* to it.
> 
>       b/ During boot up, solaris will mount an optimized libc on top of 
> /lib/libc.so.1,
>       and Tim's script fails to copy it correctly. Init will be killed in a 
> loop if the C library is absent.
>         In the part of the script which populates the devices and /dev 
> directories,
>         we must copy /zfs-root-tmp.$$/lib/libc.so.1 /zfsroot/lib.
> 
> Now you can have /usr, /opt, /var and /home on a separate raidz zpool.
> My zfs root takes only 500 megs and sits nicely on two 1 gig USB flash disks.
> 
>   zfs create tank/usr
>   zfs set mountpoint=legacy tank/usr
>   mkdir /mnt/usr
>   mount -F zfs tank/usr /mnt/usr
>   /usr/sfw/bin/gtar Ccp /usr . | /usr/sfw/bin/gtar Cxp /mnt/usr
>   echo >>/zfsroot/etc/vfstab tank/usr - /usr zfs - yes -
> 
> If you move /var to a separate partition, make sure you keep /var/run 
> directory in your zfs root.
> 
> Tested on b75a and  b75a xVm  should also work with b70, etc.
> 
> kugutsumen
> 
> You can find a patch for Tim's script here:
> http://www.kugutsumen.com/showthread.php?t=1740
>  
>  
> This message posted from opensolaris.org
> _______________________________________________
> zfs-discuss mailing list
> zfs-discuss@opensolaris.org
> http://mail.opensolaris.org/mailman/listinfo/zfs-discuss


-- 
Tim Foster, Sun Microsystems Inc, Solaris Engineering Ops
                                  http://blogs.sun.com/timf
_______________________________________________
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss

Reply via email to