Content-type: text/html
Manpage of SILO.CONF
SILO.CONF
Section: File Formats (5)
Updated: 20 September 1999
Index
Return to Main Contents
NAME
silo.conf - File format used by SILO.
SYNOPSIS
/etc/silo.conf
DESCRIPTION
The silo.conf file is a configuration file for SILO
which is read during booting.
silo.conf provides instructions for SILO. This includes
which kernels or other operating systems to load and what options pass to
them. Unlike LILO bootloader on the Intel platform, SILO reads
and parses the configuration file at boot time. This means any
changes can be made to the configuration file and if the system is shut down
properly or the config file makes it to the disk, SILO will use it on
next bootup.
SILO is able to boot kernels even without this configuration file or
if this file is crippled or contains syntax errors, but the user has to
enter full PROM names and full path of the images to load and all options
required for them manually.
FILE FORMAT
The file consists of comments and variable assignments.
- Comments
-
Start with a # character, and continue to
the end of the line.
- Flag variables
-
Consist of a single keyword and are followed by whitespace
or the end of the file.
- String variables
-
Consist of the variable name, optional architecture scope,
optional whitespace, a = character, optional whitespace, the value
and required whitespace, or the end of the file.
- Architecture scope
-
Allowed only for variable names image and other. Must directly
follow variable name without any whitespace. Consists of the [ character,
a subset of case-insensitive tokens sun4, sun4c, sun4d,
sun4e, sun4m, sun4u, separated by , characters
(no whitespace allowed in between) and ends with the ] character.
- File names
-
Some string variables are expecting file names. A file name format in SILO
is:
[<devicename>][<part>]<absolute_pathname>
or
[<devicename>][<part>][[<m>-<n>]]
The first form refers to a file or directory on some supported filesystem
(currently ext2, ufs, romfs or iso9660), the latter
refers to a range of 512B blocks on a device. For a device block range,
either <devicename>, or <part>, or [<m>-<n>] must be given. If the last part
is not given, it defaults to [1-16] (ie. 7680 bytes from offset 512 in the
device - normal SPARC bootblock location).
Optional <devicename> is the PROM name of the device the file or range
is located on. See below for its syntax. For v2 and P1275 PROMs the device
name must be immediately followed by the ; character. The default is
the boot device SILO was booted from.
Optional <part> is the 1 based partition number on the device. First
partition is 1 (e.g. on /dev/sda in Linux is this /dev/sda1).
The default is the default partition (the value of the partition
variable in the config file).
<absolute_pathname> must start with a / character and is the
pathname from the root of the filesystem on that device (unless it is the
root filesystem this is different to the pathname you will see in Linux).
<m> is the first block number (in blocksize 512 bytes) of the range to
be loaded and <n> is the last block number plus one.
SILO will transparently uncompress files when loading them if they are
gzipped, unless the file is an initial ramdisk.
- Device names
-
Depend on the PROM version of the machine used during bootup. For older
PROMs (v0), the device name syntax is:
<xx>(<m>,<n>,<o>)
where:
<xx> is one of sd, st, xd, xy, fd, le, ie,
<m> is controller number as decimal number,
<n> is device id as decimal number,
and <o> is zero based partition number.
Example:
sd(0,3,0)
fd(0,0,0)
For newer PROMs (v2) and all PROMs in the 64bit SPARC machines the syntax
is:
<fully_qualified_prom_device_name>[:<part_letter>]
where the fully qualified PROM device name starts with a / character
for the root of the PROM device tree and contains all the nodes from the
root in the tree up to the disk device node. If some node contains more than
one child node with the same name and the path has to go through such node,
a @ character followed by hexadecimal address pair is desirable to
resolve the ambiguity. Optional partition number is a : character
followed by a letter a (for first partition) through h (for
last, 8th, partition). v2 PROM device names might look like:
/sbus@3,0/SUNW,fas@3,8800000/sd@0,0
/iommu/sbus/espdma@5,8400000/esp@5,8800000/sd@6,0:d
/pci@1f,0/pci@1,1/ide@3/disk@2,0
/pci@1f,4000/ide/ata@0,0/cmdk@0,0
v2 PROM device names if specified as part of the file name (see above)
should be followed by the ; character to separate the device name from
the optional Linux partition number (note that there can be two partition
numbers specified, the latter takes precedence) and from the required
pathname.
Variable names are case insensitive, values of string variables are case
sensitive.
Blanks and equal signs may only be part of a variable name or a value if
they are escaped by a backslash or if the value is embedded in double
quotes. An equal sign may not be the only character in a name or value.
An escaped tab is converted to an escaped blank. An escaped newline is
removed from the input stream. An escaped backslash (i.e. two
backslashes) is converted to a backslash. Inside quoted strings, only
double quotes, backslashes and newlines can be escaped.
Example:
# Simple silo.conf
timeout=50
partition=5
root=/dev/sda5
read-only
image=/boot/vmlinux
label=linux
image=/boot/vmlinux.old
label=old
GLOBAL OPTIONS
/etc/silo.conf begins with a possibly empty global options section.
This section contains all variable assignments up to the first image
or other setting.
The following global options are recognized:
- default=name
-
Uses the specified image as the default boot image. If `default' is omitted,
the image appearing first in the configuration file is used.
- message=message_filename
-
Specifies a file containing a message that is displayed before the boot
prompt.
- password=password
-
Protect booting by a password. The password is given in cleartext in the
configuration file. Because of that the configuration file should be only
readable by the super user and the password should differ if possible from
other passwords on the system.
- restricted
-
A password is only required to boot the image specified in
/etc/silo.conf if parameters are specified on the command line
or if the image is not specified in the configuration file at all (ie.
arbitrary file load).
- timeout=tsecs
-
Sets a timeout (in tenths of a second) for keyboard input. If no key is
pressed for the specified time, the first image is automatically booted.
In addition to these global options, per-image options
append, device, fill-reboot-cmd, image,
initrd-prompt, initrd-size, initrd,
other, partition, pause-after, pause-message,
ramdisk, read-only, read-write and root can be
specified in the global section. They are used as defaults if they aren't
specified in the configuration sections of the respective kernel images
and will be used also for the arbitrary images specified on the input line
and not mentioned in the configuration file (unless overridden by input line
options).
PER-IMAGE SECTIONS
A per-image section starts with either a line
image=filename
(for booting from files) or
other=partition_name
(for booting from device ranges).
The image or other tokens can be directly followed by
architecture scope (see above). In that case, the image declaration will be
only available if the architecture of the booting machine is listed in the
scope. If it is not listed, the whole image or other line and
the following related section will be treated as not present in the config
file.
Example:
image[sun4c,sun4d,sun4m]=/boot/vmlinux32.gz
will declare image with the specified filename only on sun4c, sun4d or
sun4m.
SILO will transparently decompress gzipped images.
partition_name in the other setting is a normal filename whose
syntax is described above, but without the pathname part. So it is either a
single partition number (starting with 1), or a device name (for v2 and
P1275 PROMs followed by ; character) followed by such partition
number. Examples:
other=1
bootblock=/boot/old.b
# Example with device for v0 PROM:
other=sd(0,2,0)3
# Example with device for v2 or P1275 PROM:
other=/iommu/sbus/espdma/esp/sd@3,0;3
The filename above can also include two special tokens: cat and
ls. Both have to be followed by whitespace and some filename (directory
name in the ls case). ls can have options between the ls
token and the directory name. cat causes the filename to be loaded and
printed to the screen instead of being executed, ls causes a directory
listing to be generated to the screen. ls uses syntax:
ls [-[l][t][r]] <dirname>
Option l generates long listing instead of listing only filenames,
option t sorts by mtime instead of name and r reverses the
sorting. As both cat and ls require white space between the
token and the filename, you should probably surround it into double quotes
as in:
image="cat /etc/passwd"
image="ls /lib/modules/"
image="ls -lt /lib/"
From the image or other line on until next image or
other line are variable assignments and flags for this image's
section. The following options and flags are recognized:
- label=name
-
The boot loader uses the main file name (without its path) of each image
specification to identify that image. A different name can be used by
setting the variable `label'.
- alias=name
-
A second name for the same entry can be used by specifying an alias.
- partition=part_no
-
Specifies the default partition number (a digit between 1 and 8, sda1 is
part_no 1) to be used if some filename does not specify a partition number
explicitely.
- device=device_name
-
Specifies the default device name to be used if some filename does not
specify a partition number explicitely. This defaults to the device
SILO has been booted from if you don't specify device in either
the global section or per-image section of the config file.
- append=string
-
Appends the options specified to the parameter line
passed to the kernel. This is typically used to
specify parameters of hardware that can't be
entirely auto-detected or for which probing may be
dangerous. Example:
append = "video=sbusfb:off"
- literal=string
-
Like `append', but removes all other options (e.g. setting of the root
device). Because vital options can be removed unintentionally with
`literal', this option cannot be set in the global options section.
- ramdisk=size
-
This specifies the size of the optional RAM disk. A value of zero indicates
that no RAM disk should be created. If this variable is omitted, the RAM
disk size configured into the boot image is used.
- read-only
-
This specifies that the root file system should be mounted read-only.
Typically, the system startup procedure re-mounts the root file system
read-write later (e.g. after fsck'ing it).
- read-write
-
This specifies that the root file system should be mounted read-write.
- root=root-device
-
This specifies the device that should be mounted as root.
- proll=filename
-
This should be only used for JavaStation flash installs. It specifies a file
that will be loaded at boot time and executed in order to emulate old Sun v2
PROM on top of IEEE P1275 PROM called PROLL.
- initrd=filename
-
Specifies the file that will be loaded at boot time as the initial RAM disk.
Example:
initrd=/images/initrd.img
SILO will not decompress the initial ramdisk, the Linux kernel will do that.
If the initial ramdisk does not fit on one media (usually floppy), you can
split it into several pieces and separate the filenames in the list by
| characters. In this case, you have to provide a non-zero
initrd-size and, if the images reside on different medias,
initrd-prompt as well.
Example (on the first floppy is initrd1.img, on the second initrd2.img
always in the root directory and the sum of both image sizes is 1700000
bytes):
initrd=/initrd1.img|/initrd2.img
initrd-size=1700000
initrd-prompt
- initrd-size=size
-
When more than one initial ramdisk part is specified in the initrd
setting, this option is required to be the sum of sizes of all the images
mentioned on that line, in bytes. It is required so that SILO can reserve
space for the image, eventhough size of some parts has not been determined
yet.
- initrd-prompt
-
If more than one initial ramdisk part is specified, wait for user pressing a
key between loading the different images, so that the user can exchange
media. This flag is needed if some initrd parts reside on the same device,
but different removable media. On the other side, if you e.g. load one part
from a floppy and the second part from a hard disk, such option is not
needed (the question is who'd write something like that into silo.conf).
- bootblock=filename
-
For the other image section, if booting from some partition is desired
but the bootblock on that partition has been saved off to some file and the
bootblock in that partition contains something else (e.g. SILO bootblock),
this option specifies the name of the file where the bootblock has been
saved to. SILO loads the image from that file, pretends as if it had
loaded it from the specified partition and executes it. This is e.g. useful
if you have Solaris installed on the first partition of the disk and want to
install SILO into the master boot record (ie. bootblock of the first
partition). Then you should first save the Solaris bootblock into some file,
e.g. by issuing:
dd if=/dev/sda of=/boot/old.b bs=512 count=15 skip=1
then install SILO and put this snippet into silo.conf:
other=1
bootblock=/boot/old.b
Note that this does not work correctly on UltraSPARC boxes at the moment.
- fill-reboot-cmd
-
This flag should be used only with Linux kernels. If specified for an image,
it causes the file /proc/sys/kernel/reboot-cmd to be initialized by
the device SILO has been booted from, image name of the kernel beeing loaded
and all arguments to it specified either in the configuration file, or on
the input line. This means that if the user does not modify that file and
reboots the system, it should load the same kernel as last time and pass it
the same arguments.
- pause-after
-
If this flag is specified, SILO will stop after loading the kernel (and
initial ramdisks if specified) and ask the user to press a key before
continuing.
- pause-message=string
-
If pause-after is specified, this variable specifies the string to
print to the user when asking him to press a key. The default is:
Press ENTER to continue.
- single-key
-
Enables booting the image by hitting a single key when the cursor is at the
first character in the input line, without the need to press <ENTER>
afterwards. single-key requires that either the image's label or its
alias (or both) is a single character. If you need to specify parameters for
such an image, or if you want to boot some other image which happens to
start with the same letter, then you need to start the input line with at
least one space which will be removed before processing but will disable
this single-key feature.
- solaris
-
This flag tells SILO that the image to be loaded is a Solaris kernel. This
has been implemented so that users don't have to save the old Solaris
bootblock or in case it has been lost. SILO then tries to use the Solaris
ufsboot second stage loader to load specified kernel image. The usual kernel
name is /kernel/unix (SILO automatically prepends the
/platform/<platform> path before it if needed). SILO recognizes the
special pathname /kernel/unix (with any device and/or partition) though
and assumes the solaris flag for it by default. Note that this method
of loading Solaris might not work for you, as it is quite error prone due to
different versions of Solaris and different PROMs.
The recommended solution for sharing Solaris and Linux on the same disk is
to install SILO into the Linux's own partition bootblock (as opposed to the
master bootblock) and add PROM aliases to boot from the devices. E.g. if
Solaris is installed on Linux device sda1 and Linux on sda4, silo.conf
could look like this:
partition=4
timeout=50
image=/boot/vmlinux
label=linux
root=/dev/sda4
other=1
label=solaris
one would invoke SILO as:
/sbin/silo -t
and in PROM (this depends on the PROM version, lets assume P1275)
one would do either:
setenv boot-device /sbus/espdma/esp/sd@0,0:d
(so that by default it boots from the 4th (ie. Linux) partition) or:
nvalias linux /sbus/espdma/esp/sd@0,0:d
nvalias solaris /sbus/espdma/esp/sd@0,0:a
so that one could already in PROM boot either with boot linux or with
boot solaris. For the former, there would still be possibility to type
solaris on the SILO prompt to boot Solaris.
AUTHOR
SILO has been written by Jakub Jelinek <jakub@redhat.com> and
the SparcLinux team (see documentation on the list of contributors).
AVAILABILITY
The latest version of the sources may be obtained by ftp from
ftp://ultra.linux.cz/pub/silo/
SEE ALSO
silo(8)
Index
- NAME
-
- SYNOPSIS
-
- DESCRIPTION
-
- FILE FORMAT
-
- GLOBAL OPTIONS
-
- PER-IMAGE SECTIONS
-
- AUTHOR
-
- AVAILABILITY
-
- SEE ALSO
-
This document was created by
man2html,
using the manual pages.
Time: 13:55:17 GMT, December 02, 2000