Providing new installs of macOS, or upgrading to newer versions, can be a challenge in many Mac environments. Apple’s OS distribution model is focused around the Mac App Store (MAS), which may not be an option for a number of managed Mac environments. The MAS-distributed OS installer also does not include the option of adding additional third-party packages to the OS installation process; it only installs the software that Apple itself includes in the OS installer.
To address these needs, an open-source tool named createOSXinstallPkg is available. createOSXinstallPkg allows you to create an Apple installer package from an “Install macOS.app”. You can use this package for the following:
- Installing OS X or macOS onto an empty drive
- Upgrading existing OS X or macOS installations to a newer version of the operating system
The advantage of using this tool is that a number of system deployment tools for Macs can deploy the installers created by this tool, allowing OS installations or upgrades to be performed by the system management tool already in use by a particular IT shop. One great thing about using this tool is that createOSXinstallPkg will create an installer package that either installs a stock copy of either OS X or macOS, or you can add additional packages to the stock OS install.
When adding packages, there are a couple of guidelines to keep in mind:
- There is about 350 megabytes of free space available in the OS installer. This is sufficient space for configuration or bootstrapping packages, but it’s not a good idea to add Microsoft Office or similar large installers.
- The limitations of the OS install environment mean that there are a number of installers that won’t install correctly.
In particular, packages that use pre-installation or post-installation scripts may fail to run properly when those packages are run as part of the OS installation process. To help work around this limitation, I’ve developed a solution which I’ll be discussing later in the post. For more details, see below the jump.
To help the folks in my shop keep their Macs updated to the latest version of OS X, I’ve been providing a Self Service-driven OS upgrade option via Casper for the past couple of years. For a high-level overview, here’s how the process looks for El Capitan from my folks’ perspective.
1. Launch Casper’s Self Service application.
2. Locate the El Capitan Upgrade option
3. Click on the Install OS X button.
4. In the next window that pops up, they’re given important information about the OS upgrade and need to click again on the Install OS X button.
If their Mac does not have sufficient free space available available on their boot drive, they receive a warning message and the upgrade process stops at this point.
If their Mac’s boot drive has sufficient free space available, they receive a message that OS X 10.11.x is downloading and preparing for installation. Once all preparations are complete, their Mac will automatically reboot to begin the installation process.
5. Once the Mac reboots, the OS upgrade process runs. Once completed, the Mac reboots.
6. Following the reboot, an automated post-upgrade process runs. This process will update the Mac with all available Apple updates along with applying my shop’s preferred settings for the new version of OS X.
Note: This process may involve several reboots, depending on what Apple updates are needed. Once the post-upgrade process completes, the Mac will reboot again.
7. Following the reboot, the Mac will boot to the login window. At this point, the OS upgrade process has been completed and it is OK to log in and begin working again.
To see how I’ve set up this workflow using Casper and other tools, please see below the jump.
Upgrading a FileVault 2 encrypted Mac to 10.9 – Differences between CreateOSXInstallPkg and Apple’s Mavericks installation methods
I was recently wrong on the internet again, but as always making a mistake gave me a chance to learn from it. What I learned was the method Mac admins choose to use upgrading their Macs to Mavericks may have behavior that apply specifically to FileVault 2-encrypted Macs. See below the jump for details.
From time to time, Apple will release a custom build of Mac OS X to support a new Mac model. A current example is the Mid 2013 MacBook Airs, which were released after 10.8.4, but before 10.8.5. Since they have hardware that wasn’t accounted for in the standard 10.8.4 software, they’re running a custom build of 10.8.4.
Mac App Store 10.8.4 build number: OS X 10.8.4, build 12E55
Mid 2013 MacBook Air 10.8.4 build number: OS X 10.8.4, build 12E3067
While the Air’s custom build should run fine on older 10.8-compatible Macs, the Mid 2013 MacBook Airs aren’t able to run from the 10.8.4 build currently available from the Mac App Store.
In the event that you need to reinstall OS X on a Mac that needs a custom build, Apple’s solution is to use Recovery HD or Internet Recovery to download and install the correct version of OS X for that Mac. However, if your network connection is behind a proxy server, you may not be able to connect back to Apple while booted from Recovery HD, or be able to boot from Internet Recovery.
To help address this, you can use DeployStudio and OS install packages created by createOSXinstallPkg to help address situations where you can’t use Apple’s Recovery, but still need the ability to install custom builds of Mac OS X. See below the jump for the procedure.
When new software appears, Mac admins need test boxes that match their standard configuration in order to verify that the new software doesn’t adversely affect anything in their environment. In the past, this has usually meant that admins needed to either have an available test box, or go find one when they needed to test something.
The advent of good virtualization solutions meant it was easier to build test boxes without needing additional hardware, but getting the VM to match your standard could take some time and effort.
In VMWare Fusion 5.x, VMWare added NetBoot support for virtual machines running Mac OS X. This proved to be an enormous boon to Mac admins who used NetBoot to help set up their machines: They could now build VMs using the exact same processes that were used to build their users’ Macs. They could also leverage tools like createOSXinstallPkg to set up template VMs with either the latest available OS X installer from the Mac App Store or custom builds of OS X that ship with new hardware.
See below the jump for an example of how you can leverage VMWare’s NetBoot support, createOSXinstallPkg and DeployStudio to set up a new Mac VM with a factory-fresh install of OS X Mountain Lion.
As a follow-up to Greg Neagle’s unveiling of createOSXinstallPkg, a installer package-based tool for deploying Mac OS X 10.7.x and 10.8.x, I wanted to do a sequel to my earlier post on installing OS X using DeployStudio. Using packages created by createOSXinstallPkg, you can use DeployStudio to do an automatic clean install of Mac OS X 10.7.x or 10.8.x and correctly create the Recovery HD partition. See below the jump for the procedure.