> Ok,since I have two 73 Gb hard drives,I am going to > reinstall from scratch and have a question about > partitioning.I come with a Mac OS X background and > whenever I install it I like to setup a small > partition for the OS and apps,and the rest for my > home folder.What would be the best way to do this > using two identical size hard drives?I want to make > sure that I will have plenty of space left for OS > patches and apps,while using zfs wherever possible to > optimize disk usage.
Before I proceed, it should be noted that, if you already have an installed system, consult http://blogs.sun.com/timf/date/20070329 on how to convert your installation to ZFS; otherwise, read below on guidelines to configuring a hybrid SVM + ZFS layout. 6GB should be plenty for the OS. Slice 0. swap is size of RAM + 64MB, or at least 1GB. Depending on the intended workload, it might be much more. Slice 1. Allocate 64MB (yes, megabytes!) on slice 7 for the metadb. This will come into play later. Give the rest to slice 6 (run `format`, select the 1st disk, choose "partition", choose "modify", then "all free hog", and specify s7 as the "free hog" slice). After you're done with formatting, write the SMI label out to disk with "label" (you'll be asked what type of label you want to write out), quit `format` altogether and do: (on sparc) prtvtoc /dev/rdsk/c0t0d0s2 | fmthard -s '-' /dev/rdsk/c0t1d0s2 (on i86pc) prtvtoc /dev/rdsk/c0d0s2 | fmthard -s '-' /dev/rdsk/c1d0s2 to replicate the layout from one disk to another. You'll have to modify the c#[t#]d#s2 to fit whatever is in your system. After that's done, you'll set up mirroring of the / FS using SVM (you'll mirror slices 0 and 1). Details are on http://docs.sun.com. metadevice names d0 for /, consisting of submirrors d1 and d2, d10 for swap, consisting of submirrors d11 and d12; see docs.sun.com for a step-by-step guide on how to do this. Search for "metainit" and "metadb". Don't forget to do `metaparam -p 0 d10` to turn syncronisation of swap submirrors OFF during boot, as well as do `dumpadm -d /dev/md/d10` to specify the new dump device (which will now be your swap metadevice). Finally, when you're done, create a mirrored zpool on slice 6 on both disks. On top of this zpool, you'll be able to instantiate /export/home for home directories (don't use /home, since that's reserved for the AutoMounter) and also to instantiate what will become /opt down the road. When you're done with that, mount the future "/opt" under /mnt and copy /opt to it: (sh, ksh:) ((cd /opt/ && find . -depth -print | cpio -pvdmu /mnt > /tmp/cpio.log) 2> /tmp/cpio.err) & (csh, tcsh:) ((cd /opt/ && find . -depth -print | cpio -pvdmu /mnt > tmp/cpio.log) >& /tmp/cpio.err) & You can `tail -f /tmp/cpio.log` to see the files as they are being copied over, or you can `tail -f /tmp/cpio.err` to see when the copy will be done, as well as any errors that might occur. After this, unmount /mnt, whack /opt and mount the new ZFS /opt FS under /opt. Don't forget to fix the /etc/vfstab, or you'll be in for an unwelcome surprise. This mish-mash of using SVM and ZFS isn't the best thing since sliced bread, but it's the safest thing to do right now, since installing directly on a ZFS / isn't possible yet. This message posted from opensolaris.org _______________________________________________ opensolaris-discuss mailing list [email protected]
