Install(1)
NAME
Install − install a kernel from an OS/Net workspace
SYNOPSIS
Install [ −w workspace ] [ −s source dir ]
[ −k kernel arch ] [ −G glom name ]
[ −n | −t|T target ] [ −u|m|a ] [ −v|V|q ] [ −c|p ]
[ −l library file ] [ −L ] [ −D library dir ]
[ −d temp dir ] [ −x|X ] [ −h ] [ module ... ]
or
Install −R [ options ]
DESCRIPTION
Install is a utility to install a SunOS 5.x kernel. Install gathers kernel binaries from the specified workspace for the specified kernel architecture (e.g. sun4m) into a tar file suitable for extraction in /. With no options, Install assumes the current workspace ($CODEMGR_WS), infers the karch from the current working directory (e.g. if you’re in usr/src/uts/sun4m, it assumes that you want a sun4m kernel), and places the resulting kernel tar file in /tmp/Install.username/Install.karch.tar.
OPTIONS
-w workspace Install the kernel built in the specified workspace. The workspace must contain already-built kernel binaries — Install will not automatically invoke make(1). If -w is not specified, Install uses the current workspace (as indicated by $CODEMGR_WS). If there is no current workspace, Install checks to see if you are in an appropriate source directory, e.g. uts/sun4m; if so, Install takes files from there. Otherwise, Install looks for files under $SRC/uts.
-s source dir Where to get files [default: $SRC/uts].
-k kernel arch The type of kernel to install. This option is required unless you invoke Install from a karch directory, e.g. $SRC/uts/sun4z, in which case Install assumes you want a sun4z kernel.
-G glomname Gloms all kernel binaries together into one directory, /platform/karch/glomname. You can then boot this kernel with "boot glomname/unix" (no leading slash). This is useful for development work because the glommed kernel doesn’t overwrite the normal kernel, and it allows you to install multiple test kernels on the same system.
-n No target; just create the tar file in /tmp/Install.username/Install.karch.tar [default].
-t target Extract the kernel tar file on target (machine:/dir). /dir is typically /.
-T target Copy the kernel tar file to target (machine:/dir). /dir is typically /tmp. This creates the file /dir/Install.tar on machine. To finish the install, log on to machine as root, and type “cd /; tar xvf /dir/Install.tar”.
-u Install unix only.
-m Install modules only.
-a Install unix and all modules [default].
-v Verbose mode [default].
-V REALLY verbose mode. Useful mainly for debugging.
-q Quiet mode. Only fatal messages are printed.
-c Clean up. After a successful install, delete the files created in /tmp/Install.username. This is the default behavior if a target is specified with -t or -T.
-p Preserve temp files. This is the default behavior when no target is specified (-n).
-L Add a kernel to your library. This allows you to build a personal collection of installable kernels from various workspaces and for various architectures. When you type “Install -w /ws/ws_name -k karch -L”, Install creates a tar file called ws_name.arch.tar in your library directory (~/LibInstall by default).
-l library file Installs the kernel contained in library file. You may omit the “.tar” suffix. For example, “Install -l my_ws.sun4m -t machine:/” installs a kernel you previously built with -L (from sun4m files in my_ws) on machine:/. This is equivalent to typing “rsh machine ’(cd /; tar xvf -)’ <~/LibInstall/my_ws.sun4m.tar”, but it’s easier to remember.
-D lib directory Specifies the library directory [default: $HOME/LibInstall].
-d temp directory Specifies where Install should create its temp files [default: /tmp/Install.username]. This is useful if you have limited space in /tmp (Install needs about 4MB). The suffix "Install.username" is always appended.
-x Include various auxiliary files along with the kernel: /etc/driver_aliases, /etc/minor_perm, /etc/name_to_sysnum, /etc/name_to_major.
-X The opposite of -x: do not include auxiliary files [default].
-h Help. Prints a brief summary of Install’s options.
-R Recover from a failed Install. This is not required, it’s just faster than restarting. A typical scenario is for Install to run smoothly right up to the very end, but then die with "Permission denied" when it tries to rsh/rcp to the target machine. At this point, you log on to the target machine, diddle the permissions, log off, and type “Install -R”. Install will only have to retry the rsh/rcp, rather than rebuild the tar file from scratch.
If you are in a directory like $SRC/uts/sun4z when you invoke Install, it will infer that you want to install a sun4z kernel from the current workspace.
If you supply a list of modules, it overrides any of the -uma options. You only need to specify the basename of the module(s), e.g. “Install ufs nfs le”. “Install unix” is equivalent to “Install -u”, and “Install modules” is equivalent to “Install -m”.
You can customize Install by creating a .Installrc file in your home directory. .Installrc should consist of a list of command-line-style options, e.g:
-w /ws/foo
-t labmachine:/mnt -pv
Install processes default options first, then .Installrc options, then command-line options. In the case of conflicting options (e.g. -uma), the last one wins.
ENVIRONMENT
You can set the following variables in your environment:
INSTALL_RC [default: $HOME/.Installrc]
file containing default options for Install
INSTALL_STATE [default: $HOME/.Install.state]
where Install keeps its state information
INSTALL_DIR [default: /tmp/Install.username]
where Install does its work. This can be overridden on the command line with −d.
INSTALL_LIB [default: $HOME/LibInstall]
where Install gets/puts library files. This can be overridden on the command line with −D.
INSTALL_CP [default: cp -p]
the command to copy files locally
INSTALL_RCP [default: rcp -p]
the command to copy files remotely
EXAMPLES
Install -w /ws/blort -k i86pc -t machine:/
installs the i86pc kernel built in workspace /ws/blort on machine:/
Install -w /ws/blort -k i86pc -T machine:/tmp
rsh machine -l root "cd /; tar xvf /tmp/Install.tar"
is an equivalent way to do the previous example
cd $SRC/uts/sun4u
Install
makes a tar file containing a sun4u kernel, and places it in /tmp/Install.username/Install.sun4u.tar.
Install -k sun4m -w /ws/xyz -t mpbox:/ ufs
installs a new sun4m ufs module from workspace /ws/xyz on mpbox:/
FILES
$HOME/.Installrc, $HOME/.Install.state
SEE ALSO
BUGS
tar(1) and rsh(1) do not have particularly useful exit codes. To compensate, Install feeds stderr through grep -v and throws away error messages which it considers harmless. If there’s anything left, Install assumes it is fatal. It’s a hack, but it works.
Please report any bugs to bonwick@Eng.
SunOS WorkShop_4.2 — Last change: 1 May 1996