1GRUBBY(8)                   System Manager's Manual                  GRUBBY(8)
2
3
4

NAME

6       grubby  -  command  line tool for configuring grub, lilo, elilo, yaboot
7       and zipl
8
9

SYNOPSIS

11       grubby [--add-kernel=kernel-path] [--args=args]
12              [--bad-image-okay] [--boot-filesystem=bootfs]
13              [--bootloader-probe] [--config-file path] [--copy-default]
14              [--debug] [--default-kernel] [--default-index] [--default-title]
15              [--devtree=devicetree.dtb]
16              [--grub] [--lilo] [--yaboot] [--silo] [--zipl]
17              [--info=kernel-path] [--initrd=initrd-path]
18              [--make-default] [-o path] [--version]
19              [--remove-kernel=kernel-path] [--remove-args=args]
20              [--set-default=kernel-path] [--set-default-index=entry-index]
21              [--title=entry-title] [--add-multiboot=multiboot-path]
22              [--mbargs=args] [--remove-multiboot=multiboot-path]
23              [--remove-mbargs=args]
24
25

DESCRIPTION

27       grubby is a command line tool for updating and  displaying  information
28       about  the configuration files for the grub, lilo, elilo (ia64), yaboot
29       (powerpc) and zipl (s390) boot loaders. It is primarily designed to  be
30       used  from  scripts which install new kernels and need to find informa‐
31       tion about the current boot environment.
32
33       On BIOS-based Intel x86 platforms, grub2 is the default bootloader  and
34       the configuration file is in /boot/grub2/grub.cfg.  On UEFI-based Intel
35       x86 platforms, grub2 is the default bootloader, and  the  configuration
36       file  is  in  /boot/efi/EFI/redhat/grub.cfg.   On Intel ia64 platforms,
37       elilo mode is used and the default location for the configuration  file
38       is /boot/efi/EFI/redhat/elilo.conf. On PowerPC platforms, systems based
39       on Power8 now support grub2 as a bootloader and store using  a  default
40       config  stored  in /boot/grub2/grub.cfg. The earlier Power7 systems use
41       yaboot   parsing   and   the   configuration   file   should   be    in
42       /etc/yaboot.conf.  On s390 platforms the zipl bootloader will read from
43       /etc/zipl.conf.
44
45       There are a number of ways to  specify  the  kernel  used  for  --info,
46       --remove-kernel,  and  --update-kernel.  Specificying  DEFAULT  or  ALL
47       selects the default entry and all of the entries, respectively.   If  a
48       comma  separated  list of numbers is given, the boot entries indexed by
49       those numbers are selected. Finally, the title of a boot entry  may  be
50       specified  by  using TITLE=title as the argument; all entries with that
51       title are used.
52
53

OPTIONS

55       --add-kernel=kernel-path
56              Add a new boot entry for the kernel located at kernel-path.
57
58
59       --args=kernel-args
60              When a new kernel is added,  this  specifies  the  command  line
61              arguments  which should be passed to the kernel by default (note
62              they are merged with the arguments from the template if  --copy-
63              default  is used).  When --update-kernel is used, this specifies
64              new arguments to add to the argument list. Multiple, space sepa‐
65              rated  arguments  may be used. If an argument already exists the
66              new value replaces the old values.  The  root=  kernel  argument
67              gets special handling if the configuration file has special han‐
68              dling for specifying the root filesystem (like lilo.conf does).
69
70
71       --bad-image-okay
72              When grubby is looking for a entry to use for something (such as
73              a  template or a default boot entry) it uses sanity checks, such
74              as ensuring that the kernel exists in the  filesystem,  to  make
75              sure  entries  that  obviously  won't work aren't selected. This
76              option overrides that behavior, and is  designed  primarily  for
77              testing.
78
79
80       --boot-filesystem=bootfs
81              The  grub boot loader expects file paths listed in it's configu‐
82              ration path to be relative to the top of the filesystem they are
83              on,  rather  then  relative  to  the current root filesystem. By
84              default grubby searches the list of currently  mounted  filesys‐
85              tems  to  determine this. If this option is given grubby acts as
86              if the specified filesystem was the  filesystem  containing  the
87              kernel (this option is designed primarily for testing).
88
89
90       --bootloader-probe
91              grubby   tries  to  determine  if  grub  or  lilo  is  currently
92              installed. When one of those bootloaders is found  the  name  of
93              that bootloader is displayed on stdout.  Both could be installed
94              (on different devices), and grubby will print out the  names  of
95              both  bootloaders,  one  per line. The probe for grub requires a
96              commented out boot directive grub.conf identical to the standard
97              directive in the lilo configuration file. If this is not present
98              grubby will assume grub is not  installed  (note  that  anaconda
99              places  this  directive  in  grub.conf  files it creates).  This
100              option is only available on ia32 platforms.
101
102
103
104       --config-file=path
105              Use path as the configuration file rather then the default.
106
107
108       --copy-default
109              grubby will copy as much information (such as  kernel  arguments
110              and  root  device)  as possible from the current default kernel.
111              The kernel path and initrd path will never be copied.
112
113
114       --debug
115              Display extra debugging information for failures.
116
117
118       --default-kernel
119              Display the full path to the current default kernel and exit.
120
121
122       --default-index
123              Display the numeric index of the current default boot entry  and
124              exit.
125
126
127       --default-title
128              Display the title of the current default boot entry and exit.
129
130
131       --devtree=path
132              Use  path  for  device  tree  path  in  place of the path of any
133              devicetree directive found in the template stanza.
134
135
136       --elilo
137              Use an elilo style configuration file.
138
139
140       --grub Use a grub style configuration file instead of lilo style.  This
141              is the default on ia32 platforms.
142
143
144       --info=kernel-path
145              Display information on all boot entries which match kernel-path.
146              I
147
148
149       --initrd=initrd-path
150              Use initrd-path as the path to an initial ram  disk  for  a  new
151              kernel being added.
152
153
154       --lilo Use a lilo style configuration file.
155
156
157       --make-default
158              Make the new kernel entry being added the default entry.
159
160
161       --remove-args=kernel-args
162              The arguments specified by kernel-args are removed from the ker‐
163              nels specified by --update-kernel. The root argument  gets  spe‐
164              cial handling for configuration files that support separate root
165              filesystem configuration.
166
167
168       --remove-kernel=kernel-path
169              Removes all boot entries which match kernel-path.  This  may  be
170              used along with --add-kernel, in which case the new kernel being
171              added will never be removed.
172
173
174       --set-default=kernel-path
175              The first entry which boots the specified  kernel  is  made  the
176              default boot entry.
177
178
179       --set-default-index=entry-index
180              Makes the given entry number the default boot entry.
181
182
183       --title=entry-title
184              When  a  new  kernel  entry  is added entry-title is used as the
185              title (lilo label) for the entry. If entry-title is longer  then
186              maximum length allowed by the bootloader (15 for lilo, unlimited
187              for grub and elilo) the title is shortened to a (unique) entry.
188
189
190       --update-kernel=kernel-path
191              The entries for kernels matching kernel-path are  updated.  Cur‐
192              rently the only items that can be updated is the kernel argument
193              list,  which  is  modified  via  the  --args  and  --remove-args
194              options.
195
196
197       --version
198              Display  the  version  of grubby being run and then exit immedi‐
199              ately.
200
201
202       --yaboot
203              Use an yaboot style configuration file.
204
205
206       --zipl Use an zipl style configuration file.
207
208

MULTIBOOT OPTIONS

210       The Multiboot Specification provides a genreic interface for boot load‐
211       ers and operating systems.  It is supported by the GRUB bootloader.
212
213
214       --add-multiboot=multiboot-path
215              Add  a new boot entry for the multiboot kernel located at multi‐
216              boot-path.  Note that  this  is  generally  accompanied  with  a
217              --add-kernel option.
218
219
220       --remove-multiboot=multiboot-path
221              Removes all boot entries which match multiboot-path.
222
223
224       --mbargs=multiboot-args
225              When a new multiboot kernel is added, this specifies the command
226              line arguments which should be passed to that kernel by  default
227              When  --update-kernel  is  used, this specifies new arguments to
228              add to the argument list. Multiple,  space  separated  arguments
229              may  be  used.  If  an  argument  already  exists  the new value
230              replaces the old values.
231
232
233       --remove-mbargs=multiboot-args
234              The arguments specified by multiboot-args are removed  from  the
235              kernels specified by --update-kernel.
236
237
238

BUGS

240       The  command  line  syntax is more than a little baroque. This probably
241       won't be fixed as grubby is only  intended  to  be  called  from  shell
242       scripts which can get it right.
243
244

SEE ALSO

246       grub(8), lilo(8), yaboot(8), mkinitrd(8)
247
248

AUTHORS

250       Erik Troan
251       Jeremy Katz
252       Peter Jones
253
254
255
256                                Tue Jan 18 2005                      GRUBBY(8)
Impressum