C Advanced linuxrc
Options #
linuxrc
is a small program that runs after the kernel has
loaded, but before AutoYaST or other stages. It prepares the system for
installation. It allows the user to load modules, start an installed system
or a rescue system, and to guide the operation of YaST.
linuxrc
Settings Are Not Identical
Some linuxrc
settings coincidentally have the same names
as settings used by AutoYaST in its autoyast.xml
file. This
does not mean that they take the same parameters or
function in the same way. For example, AutoYaST takes a self_update
setting. If this value is set to 1
, another setting,
self_update_url
will be read and followed. Although linuxrc
also has a self_update
setting, linuxrc
's
setting takes values of either 0
or a URL.
Do not pass AutoYaST parameters to linuxrc
, as this will
almost certainly not give the desired results.
If linuxrc
is installed on a machine, information about it
can be found in the directory /usr/share/doc/packages/linuxrc/
.
Alternatively, its documentation can be found online at:
https://en.opensuse.org/SDB:Linuxrc.
linuxrc
on an Installed System
If you run linuxrc
on an installed system, it will work
slightly differently so as not to destroy your installation. As a
consequence, you cannot test all features this way.
To keep the linuxrc
binary file as small as possible, all
its libraries and other supplemental files are linked directly into the main
program binary file. This means that there is no need for any shared
libraries in the initial RAM disk, initrd
.
C.1 Passing Parameters to linuxrc
#
Unless linuxrc
is in manual mode, it will look for an
info
file in these locations: first
/info
on the flash disk (for example, a USB stick) and if that does not exist,
for /info
in the initrd
. After
that, it parses the kernel command line for parameters. You may change the
info
file linuxrc
reads by setting the
info
command line parameter. If you do not want
linuxrc
to read the kernel command line (for example,
because you need to specify a kernel parameter that linuxrc
recognizes as well), use linuxrc=nocmdline
.
linuxrc
will always look for and parse a file called
/linuxrc.config
. Use this file to change default values
if you need to. In general, it is better to use the info
file instead. Note that /linuxrc.config
is read before
any info
file, even in manual mode.
C.2 info
File Format #
Lines starting with #
are comments. Valid entries are
of the form:
key: value
Note that value
extends to the end of the line and
therefore may contain spaces. The matching of key
is on a
case-insensitive basis.
You can use the same key-value pairs on the kernel command line using
the syntax key=value
. Lines that do not have the form
described above will be ignored.
The table below lists important keys and example values. For a complete
list of linuxrc
parameters, refer to https://en.opensuse.org/SDB:Linuxrc.
linuxrc
Keywords #
Keyword: Example Value |
Description |
---|---|
|
If 0, never ask for swap; if the argument is a positive number
|
|
Location of the auto installation file; activates auto installation mode. See AutoYaST Control File Locations for details. |
|
10 seconds timeout for BOOTP requests. |
|
Sleep 5 seconds between network activation and starting bootp. |
|
Set the menu color scheme. |
|
Run command. |
|
Use the |
|
Load the installation system into RAM disk. |
|
Set up and start the network. See Section C.3, “Advanced Network Setup” for more information. |
|
Load MODULE. |
|
Install from the repository specified with URL. For the syntax of URL refer to https://en.opensuse.org/SDB:Linuxrc#url_descr. |
|
Virtual console keyboard map to load. |
|
Language preselected for the installation. |
|
Enable remote logging via syslog via UDP port 514 |
|
Enable remote logging via syslog via TCP port 514 |
|
Load installation system into RAM disk if free memory is above 50000 KB. |
|
Ask for swap if free memory drops below 10000 KB. |
|
Run YaST in text mode if free memory is below 20000 KB. |
|
Ask for swap before starting YaST if free memory is below 10000 KB. |
|
Defines a HTTP proxy server. For the full paramter syntax refer to https://en.opensuse.org/SDB:Linuxrc#p_proxy. |
|
Load the rescue system; the URL variant specifies the location of the rescue image explicitly. |
|
Location of the rescue system image. |
|
Location of the installation system image. |
|
Start YaST in text mode. |
|
Wait four seconds after loading the USB modules. |
|
Overrides the confirm parameter in a control file and requests confirmation of installation proposal. |
C.3 Advanced Network Setup #
Even if parameters like hostip
, nameserver
,
and gateway
are passed to linuxrc
, the
network is only started when it is needed (for example, when installing via
SSH or VNC). Because autoyast
is not a linuxrc
parameter (this parameter is ignored by linuxrc
and is
only passed to YaST), the network will not be started
automatically when specifying a remote location for the AutoYaST profile.
Therefore, the network needs to be started explicitly. This used to be done
with the linuxrc
parameter netsetup
.
Starting with SUSE Linux Enterprise Server 12, the parameter ifcfg
is
available. It offers more configuration options, for example configuring
more than one interface. ifcfg
directly controls the
content of the /etc/sysconfig/network/ifcfg-*
files.
- DHCP Network Configuration
The general syntax to configure DHCP is
ifcfg=INTERFACE=DHCP*,OPTION1=VALUE1,OPTION2=VALUE2
where INTERFACE is the interface name, for example
eth0
, oreth*
for all interfaces. DHCP* can either bedhcp
(IPv4 and IPv6),dhcp4
, ordhcp6
.To set up DHCP for
eth0
use:ifcfg=eth0=dhcp
To set up DHCP on all interfaces use:
ifcfg=eth*=dhcp
- Static Network Configuration
The general syntax to configure a static network is
ifcfg=INTERFACE=IP_LIST,GATEWAY_LIST,NAMESERVER_LIST,DOMAINSEARCH_LIST,\ OPTION1=value1,...
where INTERFACE is the interface name, for example
eth0
. If usingeth*
, the first device available will be used. The other parameters need to be replaced with the respective values in the given order. Example:ifcfg=eth0=192.168.2.100/24,192.168.5.1,192.168.1.116,example.com
When specifying multiple addresses for a parameter, use spaces to separate them and quote the complete string. The following example uses two name servers and a search list containing two domains.
ifcfg="eth0=192.168.2.100/24,192.168.5.1,192.168.1.116 192.168.1.117,example.com example.net"
For more information refer to https://en.opensuse.org/SDB:Linuxrc#Network_Configuration.