Determining CPU speed, memory, etc
Booting into Single-User Mode
ok boot -s
Booting into Single-User Mode from CD-ROM
ok boot cdrom -s
Checking Applied Patches
Display Disk Partitions/Slices
To list all of the disks in the system along with their sizes, use the
iostat command. The -n causes it to print the disk names as
cXtXdX instead of sdX (which does not seem to correspond with anything
# iostat -nE
This is actually kinda lousy if you need to know about multiple disks. You also have to convert sectors to bytes (by dividing by two) to see the actual size.
Make sure to use the rdsk device file and slice 0.
Mounting Loopback Filesystem Images
Particularly useful for ISO-9660 (CD) images. The
lofiadm tool is similar to
losetup utility in Linux–it connects a file (which is presumeably a
filesystem image) with a block device, so that it can be mounted, mkfs’d, etc.
# lofiadm -a foo.iso /dev/lofi/1 # mount -F hsfs -o ro /dev/lofi/1 /mnt
Or in one step:
# mount -F hsfs -o ro $(lofiadm -a foo.iso) /mnt
pkgadd -d <pkgfile>
This method is useful for installing into an NFS export, for easy installation on other systems.
Install the package into
pkgadd -s /var/spool/pkg -d <pkgfile>
Install the package from the listing and follow prompts:
pkgadd # Follow prompts
Generally, you cannot install a package over an existing package, because the
/var/sadm/install/admin/default has the parameter
to unique. If you make a copy of this file and change unique to ask, you
will be prompted to overwrite the installed package if you run