sash − general description of the standalone shell [ -a ] [ -r ] [ file [ args ]] is the MIPS standalone shell. The standalone shell is a more richly configured version of the prom monitor. It provides most of the same commands as the prom monitor, but is configured with more device drivers and file system types. Sash exists so that the prom monitor is not dependent on the operating system and file system formats. when booted without arguments enters command mode. From command mode memory and environment variables may be displayed and altered, and other programs may be booted. If the -a flag is specified as the first argument, sash assumes that an "automatic" operating system boot is to be done. Sash examines the name by which it was booted and uses the same device, controller, and unit to look for an operating system to boot. Sash finds the correct operating system file to boot by examining the disk volume header on this device, the volume header specifies a root partition and an operating system filename. Once the appropriate operating system file is determined, sash boots the operating system passing the -a flag and any other arguments following the -a flag on to the operating system. The prom monitor command and cold start boot mode use this mechanism to load the operating system. If the -r flag is specified as the first argument, sash assumes that the next argument is a standalone program that is being booted by a remote debugger. Sash defines the environment variables "dbgmon" and "rdebug" and then boots the file specified by the argument after the -r flag passing any succeeding arguments. If the booted program was linked against the standalone library, the startup code provided will note the environment variables "dbgmon" and "rdebug" and load the debugging monitor co-resident with program and cause it to enter remote debugging mode. If any other argument is passed to sash when it is booted, sash interprets the argument as a file name of a program to be booted immediately. Any other arguments appearing on the command line to sash will be passed on to the booted program. Thus, if the prom monitor environment variable "bootfile" is set to refer to a "sash" and the command:
is given, the prom monitor will load the file indicated by the environment variable "bootfile" which will be sash, sash will then see that it is invoked with the argument "dkip()vmunix" and immediately boot that file. This is the mechanism by which two-level boots are accomplished. If the standalone shell is presented a command that is not a built-in command, the standalone shell will use the first word of the command as the name of a file and attempt to boot that file passing any other arguments on the command line onto the booted program. If the environment variable $path is not defined, the first word of the command must be a complete file name specification consisting of a device name, controller, unit, partition fields as necessary, and a file path. If the environment variable $path is defined, the standalone shell will attempt to boot the program file formed by prepending the contents of $path to the original file name. If $path is a list of space separated prefixes, the standalone shell will try each prefix from $path in turn until the file can be successfully booted or all prefixes have been tried. intro(1spp), prom(1spp), dbgmon(1spp)