Creating ZFS file systems during the jumpstart process

I use jumpstart at home to update the hosts in my lab as new Nevada builds and Solaris updates are released. As part of the unattended installation / upgrade process, I create a couple of ZFS file systems on each system. Since jumpstart doesn’t have built-in support for creating ZFS file system, I had to add the zpool and zfs commands to my finish script. After a bit of tinkering around, here is what I came up with:

# Locate the first local device on the system
DISK1=`echo quit | /usr/sbin/format 2>/dev/null | /usr/bin/awk '$0 ~ /0./ { print $2 }'`

# Create a ZFS pool using the disk device above
/usr/sbin/zpool create -f -R /a p0 ${DISK1}

# Create ZFS file systems
/usr/sbin/zfs create p0/home
/usr/sbin/zfs set mountpoint=/home p0/home
.....

This appears to work pretty well, and my boxes are now built and operational once the jumpstart process completes. Niiiiiiiice!

4 Comments

Bert  on February 25th, 2008

Unintended installation process? I think you mean “unattended installation process…”

:)

Otherwise, great blog. Do you have any experience with the Jumpstart Enterprise Toolkit? I’m struggling through setting up custom packages and copying files over.

matty  on February 25th, 2008

Hi Bert,

Hahaha — that was an unintended typo. :) I have used JASS before, though I don’t use it as the primary driver for system configuration. What issues are you bumping into?

- Ryan

mattsn0w  on March 11th, 2008

Bert,
in your JET templace there is a line
`base_config_profile_add_packages=”"`

I frequently use JET to re-image thumpers so I’ve only install the HD tool. here is what my line looks like:
base_config_profile_add_packages=”SUNWhd”

Then I have the follow dir shared through NFS:
/export/home/install/pkgs

in this dir I have a file named `SUNWhd.pkg`.

I did try a custom built package when installing s10u4 on an HP DL580 G5 but it wouldn’t install. HP doesn’t provide a valid .pkg package that the solaris installer will use for their SAS controllers(or any HP disk controller).

good luck.

DDR  on January 27th, 2010

was this install on an x86 system or sparc? thanks,

Leave a Comment