Symptom:sometimes we need to install or upgrade a Men & Mice installation remotely and we don't have access to the remote machines GUI. Thanks to the good Unix base of MacOS X and the Apple Installer commandline tools, doing a remote installation (for example via SSH) is not rocket science.
Problem:Without access to the GUI, the Apple MacOS X GUI installer cannot be used.
Downloading the Components on the machine:we can download the latest Men & Mice Components (Men & Mice Central and DNS Server Controller) using "ftp" from the Men & Mice FTP Server (ftp://ftp.menandmice.com/pub/mmsuite). I will use the file "Men_and_Mice_Suite_Installers.dmg" (Version 126.96.36.199) in this tutorial, but the DMG Files from older or newer versions work the same way.
All the steps are done on the commandline.
Mounting the Disk Image (DMG)after downloading the Disk Image File (DMG) to the local harddrive of the target server machine, we mount the Disk Image File.
# sudo hdiutil attach Men_and_Mice_Suite_Installers.dmgThe output of this command should be similar to the one below:
Checksumming Driver Descriptor Map (DDM : 0)... Driver Descriptor Map (DDM : 0): verified CRC32 $9EC61778 Checksumming Apple (Apple_partition_map : 1)... Apple (Apple_partition_map : 1): verified CRC32 $A8FBC0AB Checksumming disk image (Apple_HFS : 2)... ............................................................................................................................................................ disk image (Apple_HFS : 2): verified CRC32 $CF8280A5 Checksumming (Apple_Free : 3)... (Apple_Free : 3): verified CRC32 $00000000 verified CRC32 $E3C392C5 /dev/disk2 Apple_partition_scheme /dev/disk2s1 Apple_partition_map /dev/disk2s2 Apple_HFS /Volumes/Men and Mice Suite InstallersWe can use the "mount" command to verify that the Disk Image is now mounted at "/Volumes/Men and Mice Suite Installers":
root# mount /dev/disk0s10 on / (local, journaled) devfs on /dev (local) fdesc on /dev (union) <volfs> on /.vol automount -nsl  on /Network (automounted) automount -fstab  on /automount/Servers (automounted) automount -static  on /automount/static (automounted) /dev/disk2s2 on /Volumes/Men and Mice Suite Installers (local, nodev, nosuid, read-only)
Installing Men & Mice Central
Now we install the Men & Mice Central Installer package from the mounted directory:
# sudo installer -pkg /Volumes//Volumes/Men\ and\ Mice\ Suite\ Installers/Men\ \&\ Mice\ Central.pkg -target "/"The "target" specifies the directory of the main harddrive to install the package on.
The output of this command is (I'm upgrading here from an older version of the Men & Mice Suite):
installer: Package name is Men & Mice Central installer: Upgrading volume mounted at /. installer: The upgrade was successful.We can verify that the Version 6.2.2 Men & Mice Central is now installed:
# sudo mmcentrald -v Men and Mice Central, version 6.2.2 [6.7:6.2:6.4] Build date: Dec 16 2010 Platform: Darwin 10.6.0 (i386)
Installing Men & Mice DNS Server ControllerNow we install the DNS Server Controller:
# sudo installer -pkg /Volumes/Men\ and\ Mice\ Suite\ Installers/Men\ \&\ Mice\ DNS\ Server\ Controller.pkg -target "/" installer: Package name is Men & Mice DNS Server Controller installer: Upgrading volume mounted at /. installer: The upgrade was successful.and we verify the version of the newly installed binary:
# sudo mmremoted -v Men and Mice DNS Server Controller for BIND, version 188.8.131.52 [34639/34297][6.2] Build date: Feb 14 2011 Platform: Darwin 8.11.0 (Power Macintosh)Now the Men & Mice Components are installed or upgraded. The only task left is some cleanup.
Unmounting the Installer Disk Image:We need to detach the mounted Disk Image. For this command it is important not to be inside the Disk Images Directories (best to change to the root "/" before issuing this command)
# cd / # hdiutil detach /Volumes/Men\ and\ Mice\ Suite\ Installers "disk2" unmounted. "disk2" ejected.And we are done. Happy remote installing!