Magellan Linux

Diff of /tags/grubby-8_40_20170706/grubby.8

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1332 by niro, Fri Jun 3 20:32:19 2011 UTC revision 3012 by niro, Tue Jun 27 14:32:57 2017 UTC
# Line 1  Line 1 
1  .TH GRUBBY 8 "Tue Jan 18 2005"  .TH GRUBBY 8 "Tue Jan 18 2005"
2    
3  .SH NAME  .SH NAME
4  grubby \- command line tool for configuring grub, lilo, and elilo  
5    grubby \- command line tool for configuring grub, lilo, elilo, yaboot and zipl
6    
7  .SH SYNOPSIS  .SH SYNOPSIS
8  \fBgrubby\fR [--add-kernel=\fIkernel-path\fR] [--args=\fIargs\fR]  
9         [--bad-image-okay] [--boot-filesystem=\fIbootfs\fR]  \fBgrubby\fR [--add-kernel=\fIkernel-path\fR] [--args=\fIargs\fR]
10         [--bootloader-probe] [--config-file \fIpath\fR]         [--bad-image-okay] [--boot-filesystem=\fIbootfs\fR]
11         [--copy-default] [--default-kernel]         [--bootloader-probe] [--config-file \fIpath\fR] [--copy-default]
12           [--debug] [--default-kernel] [--default-index] [--default-title]
13           [--devtree=\fIdevicetree.dtb\fR] [--set-index=\fIentry-index\fR]
14         [--grub] [--lilo] [--yaboot] [--silo] [--zipl]         [--grub] [--lilo] [--yaboot] [--silo] [--zipl]
15         [--info=\fIkernel-path\fR] [--initrd=\fIinitrd-path\fR]         [--info=\fIkernel-path\fR] [--initrd=\fIinitrd-path\fR]
16         [--make-default] [-o path] [--version]         [--make-default] [-o path] [--version]
17         [--remove-kernel=\fIkernel-path\fR] [--remove-args=\fIargs\fR]         [--remove-kernel=\fIkernel-path\fR] [--remove-args=\fIargs\fR]
18         [--set-default=\fIkernel-path\fR] [--title=entry-title]         [--set-default=\fIkernel-path\fR] [--set-default-index=\fIentry-index\fR]
19         [--add-multiboot=\fImultiboot-path\fR] [--mbargs=\fIargs\fR]         [--title=entry-title] [--add-multiboot=\fImultiboot-path\fR]
20         [--remove-multiboot=\fImultiboot-path\fR] [--remove-mbargs=\fIargs\fR]         [--mbargs=\fIargs\fR] [--remove-multiboot=\fImultiboot-path\fR]
21           [--remove-mbargs=\fIargs\fR]
22    
23  .SH DESCRIPTION  .SH DESCRIPTION
24    
25    .SS General Information
26    
27  \fBgrubby\fR is a command line tool for updating and displaying information  \fBgrubby\fR is a command line tool for updating and displaying information
28  about the configuration files for the \fBgrub\fR, \fBlilo\fR, \fBelilo\fR  about the configuration files for the \fBgrub\fR, \fBlilo\fR, \fBelilo\fR
29  (ia64), \fByaboot\fR (powerpc) and \fBzipl\fR (s390) boot loaders. It  (ia64), \fByaboot\fR (powerpc) and \fBzipl\fR (s390) boot loaders. It
30  is primarily designed to be used from scripts which install new  is primarily designed to be used from scripts which install new
31  kernels and need to find information about the current boot environment.  kernels and need to find information about the current boot environment.
32    
33  On Intel x86 platforms, \fBgrub\fR is the default bootloader and the  .SS Architecture Support
34  configuration file is in \fB/boot/grub/grub.conf\fR. On Intel ia64 platforms,  
35  \fBelilo\fR mode is used and the default location for the configuration file  On BIOS-based Intel x86 platforms, \fBgrub2\fR is the default bootloader and
36  is \fB/boot/grub/grub.conf\fR. On PowerPC platforms, \fByaboot\fR parsing  the configuration file is in \fB/boot/grub2/grub.cfg\fR.  On UEFI-based Intel
37  is used and the configuration file should be in \fB/etc/yaboot.conf\fR.  x86 platforms, \fBgrub2\fR is the default bootloader, and the configuration
38    file is in \fB/boot/efi/EFI/redhat/grub.cfg\fR.  On Intel ia64 platforms,
39    \fBelilo\fR mode is used and the default location for the configuration file
40    is \fB/boot/efi/EFI/redhat/elilo.conf\fR. On PowerPC platforms, systems based
41    on Power8 now support \fBgrub2\fR as a bootloader and store using a default
42    config stored in \fB/boot/grub2/grub.cfg\fR. The earlier Power7 systems use \fByaboot\fR
43    parsing and the configuration file should be in \fB/etc/yaboot.conf\fR.  On
44    s390 platforms the \fBzipl bootloader\fR will read from \fB/etc/zipl.conf\fR.
45    
46    .SS Special Arguments
47    
48  There are a number of ways to specify the kernel used for \fB-\-info\fR,  There are a number of ways to specify the kernel used for \fB-\-info\fR,
49  \fB-\-remove-kernel\fR, and \fB-\-update-kernel\fR. Specificying \fBDEFAULT\fR  \fB-\-remove-kernel\fR, and \fB-\-update-kernel\fR. Specificying \fBDEFAULT\fR
# Line 37  be specified by using \fBTITLE=\fItitle\ Line 54  be specified by using \fBTITLE=\fItitle\
54  with that title are used.  with that title are used.
55    
56  .SH OPTIONS  .SH OPTIONS
57    
58    .SS Basic Options
59    
60  .TP  .TP
61  \fB-\-add-kernel\fR=\fIkernel-path\fR  \fB-\-add-kernel\fR=\fIkernel-path\fR
62  Add a new boot entry for the kernel located at \fIkernel-path\fR.  Add a new boot entry for the kernel located at \fIkernel-path\fR.
63    
64  .TP  .TP
65    \fB-\-remove-kernel\fR=\fIkernel-path\fR
66    Removes all boot entries which match \fIkernel-path\fR. This may be used
67    along with -\-add-kernel, in which case the new kernel being added will
68    never be removed.
69    
70    .TP
71    \fB-\-update-kernel\fR=\fIkernel-path\fR
72    The entries for kernels matching \fRkernel-path\fR are updated. Currently
73    the only items that can be updated is the kernel argument list, which is
74    modified via the \fB-\-args\fR and \fB-\-remove-args\fR options.
75    
76    .TP
77  \fB-\-args\fR=\fIkernel-args\fR  \fB-\-args\fR=\fIkernel-args\fR
78  When a new kernel is added, this specifies the command line arguments  When a new kernel is added, this specifies the command line arguments
79  which should be passed to the kernel by default (note they are merged  which should be passed to the kernel by default (note they are merged
# Line 54  file has special handling for specifying Line 86  file has special handling for specifying
86  lilo.conf does).  lilo.conf does).
87    
88  .TP  .TP
89  \fB-\-bad-image-okay\fR  \fB-\-remove-args\fR=\fIkernel-args\fR
90  When \fBgrubby\fR is looking for a entry to use for something (such  The arguments specified by \fIkernel-args\fR are removed from the
91  as a template or a default boot entry) it uses sanity checks, such as  kernels specified by \fB-\-update-kernel\fR. The \fBroot\fR argument
92  ensuring that the kernel exists in the filesystem, to make sure  gets special handling for configuration files that support separate root
93  entries that obviously won't work aren't selected. This option overrides  filesystem configuration.
 that behavior, and is designed primarily for testing.  
   
 .TP  
 \fB-\-boot-filesystem\fR=\fIbootfs\fR  
 The \fBgrub\fR boot loader expects file paths listed in it's configuration  
 path to be relative to the top of the filesystem they are on, rather then  
 relative to the current root filesystem. By default \fBgrubby\fR searches  
 the list of currently mounted filesystems to determine this. If this option  
 is given \fBgrubby\fR acts as if the specified filesystem was the filesystem  
 containing the kernel (this option is designed primarily for testing).  
   
 .TP  
 \fB-\-bootloader-probe\fR  
 \fBgrubby\fR tries to determine if \fBgrub\fR or \fBlilo\fR is currently  
 installed. When one of those bootloaders is found the name of that bootloader  
 is displayed on stdout.  Both could be installed (on different devices), and  
 grubby will print out the names of both bootloaders, one per line. The probe  
 for \fBgrub\fR requires a commented out boot directive \fBgrub.conf\fR  
 identical to the standard directive in the lilo configuration file. If this  
 is not present \fBgrubby\fR will assume grub is not installed (note  
 that \fBanaconda\fR places this directive in \fBgrub.conf\fR files it creates).  
 This option is only available on ia32 platforms.  
   
   
 .TP  
 \fB-\-config-file\fR=\fIpath\fR  
 Use \fIpath\fR as the configuration file rather then the default.  
94    
95  .TP  .TP
96  \fB-\-copy-default\fR  \fB-\-copy-default\fR
# Line 94  root device) as possible from the curren Line 99  root device) as possible from the curren
99  and initrd path will never be copied.  and initrd path will never be copied.
100    
101  .TP  .TP
102  \fB-\-default-kernel\fR  \fB-\-title\fR=\fIentry-title\fR
103  Display the full path to the current default kernel and exit.  When a new kernel entry is added \fIentry-title\fR is used as the title
104    (\fBlilo\fR label) for the entry. If \fIentry-title\fR is longer then maximum
105    length allowed by the bootloader (15 for lilo, unlimited for grub and elilo)
106    the title is shortened to a (unique) entry.
107    
108  .TP  .TP
109  \fB-\-elilo\fR  \fB-\-initrd\fR=\fIinitrd-path\fR
110  Use an \fBelilo\fR style configuration file.  Use \fIinitrd-path\fR as the path to an initial ram disk for a new kernel
111    being added.
112    
113  .TP  .TP
114  \fB-\-grub\fR  \fB-\-set-default\fR=\fIkernel-path\fR
115  Use a \fBgrub\fR style configuration file instead of \fBlilo\fR style. This  The first entry which boots the specified kernel is made the default
116  is the default on ia32 platforms.  boot entry.
117    
118  .TP  .TP
119  \fB-\-info\fR=\fIkernel-path\fR  \fB-\-set-default-index\fR=\fIentry-index\fR
120  Display information on all boot entries which match \fIkernel-path\fR. I  Makes the given entry number the default boot entry.
121    
122  .TP  .TP
123  \fB-\-initrd\fR=\fIinitrd-path\fR  \fB-\-make-default\fR
124  Use \fIinitrd-path\fR as the path to an initial ram disk for a new kernel  Make the new kernel entry being added the default entry.
 being added.  
125    
126  .TP  .TP
127  \fB-\-lilo\fR  \fB-\-set-index\fR=\fIentry-index\fR
128  Use a \fBlilo\fR style configuration file.  Set the position at which to add a new entry created with \fB-\-add-kernel\fR.
129    
130  .TP  .TP
131  \fB-\-make-default\fR  \fB-\-debug\fR
132  Make the new kernel entry being added the default entry.  Display extra debugging information for failures.
133    
134    .SS Display Options
135    
136  .TP  .TP
137  \fB-\-remove-args\fR=\fIkernel-args\fR  \fB-\-default-kernel\fR
138  The arguments specified by \fIkernel-args\fR are removed from the  Display the full path to the current default kernel and exit.
 kernels specified by \fB-\-update-kernel\fR. The \fBroot\fR argument  
 gets special handling for configuration files that support separate root  
 filesystem configuration.  
139    
140  .TP  .TP
141  \fB-\-remove-kernel\fR=\fIkernel-path\fR  \fB-\-default-index\fR
142  Removes all boot entries which match \fIkernel-path\fR. This may be used  Display the numeric index of the current default boot entry and exit.
 along with -\-add-kernel, in which case the new kernel being added will  
 never be removed.  
143    
144  .TP  .TP
145  \fB-\-set-default\fR=\fIkernel-path\fR  \fB-\-default-title\fR
146  The first entry which boots the specified kernel is made the default  Display the title of the current default boot entry and exit.
 boot entry.  
147    
148  .TP  .TP
149  \fB-\-title\fR=\fIentry-title\fR  \fB-\-info\fR=\fIkernel-path\fR
150  When a new kernel entry is added \fIentry-title\fR is used as the title  Display information on all boot entries which match \fIkernel-path\fR. I
 (\fBlilo\fR label) for the entry. If \fIentry-title\fR is longer then maximum  
 length allowed by the bootloader (15 for lilo, unlimited for grub and elilo)  
 the title is shortened to a (unique) entry.  
151    
152  .TP  .TP
153  \fB-\-update-kernel\fR=\fIkernel-path\fR  \fB-\-bootloader-probe\fR
154  The entries for kernels matching \fRkernel-path\fR are updated. Currently  \fBgrubby\fR tries to determine if \fBgrub\fR or \fBlilo\fR is currently
155  the only items that can be updated is the kernel argument list, which is  installed. When one of those bootloaders is found the name of that bootloader
156  modified via the \fB-\-args\fR and \fB-\-remove-args\fR options.  is displayed on stdout.  Both could be installed (on different devices), and
157    grubby will print out the names of both bootloaders, one per line. The probe
158    for \fBgrub\fR requires a commented out boot directive \fBgrub.conf\fR
159    identical to the standard directive in the lilo configuration file. If this
160    is not present \fBgrubby\fR will assume grub is not installed (note
161    that \fBanaconda\fR places this directive in \fBgrub.conf\fR files it creates).
162    This option is only available on ia32 platforms.
163    
164  .TP  .TP
165  \fB-\-version\fR  \fB-\-version\fR
166  Display the version of \fBgrubby\fR being run and then exit immediately.  Display the version of \fBgrubby\fR being run and then exit immediately.
167    
168    .SS Output Format Options
169    
170    .TP
171    \fB-\-elilo\fR
172    Use an \fBelilo\fR style configuration file.
173    
174    .TP
175    \fB-\-grub\fR
176    Use a \fBgrub\fR style configuration file instead of \fBlilo\fR style. This
177    is the default on ia32 platforms.
178    
179    .TP
180    \fB-\-lilo\fR
181    Use a \fBlilo\fR style configuration file.
182    
183  .TP  .TP
184  \fB-\-yaboot\fR  \fB-\-yaboot\fR
185  Use an \fByaboot\fR style configuration file.  Use an \fByaboot\fR style configuration file.
# Line 166  Use an \fByaboot\fR style configuration Line 188  Use an \fByaboot\fR style configuration
188  \fB-\-zipl\fR  \fB-\-zipl\fR
189  Use an \fBzipl\fR style configuration file.  Use an \fBzipl\fR style configuration file.
190    
191  .SH MULTIBOOT OPTIONS  .SS Override Options
192    
193    .TP
194    \fB-\-bad-image-okay\fR
195    When \fBgrubby\fR is looking for a entry to use for something (such
196    as a template or a default boot entry) it uses sanity checks, such as
197    ensuring that the kernel exists in the filesystem, to make sure
198    entries that obviously won't work aren't selected. This option overrides
199    that behavior, and is designed primarily for testing.
200    
201    .TP
202    \fB-\-boot-filesystem\fR=\fIbootfs\fR
203    The \fBgrub\fR boot loader expects file paths listed in it's configuration
204    path to be relative to the top of the filesystem they are on, rather then
205    relative to the current root filesystem. By default \fBgrubby\fR searches
206    the list of currently mounted filesystems to determine this. If this option
207    is given \fBgrubby\fR acts as if the specified filesystem was the filesystem
208    containing the kernel (this option is designed primarily for testing).
209    
210    .TP
211    \fB-\-config-file\fR=\fIpath\fR
212    Use \fIpath\fR as the configuration file rather then the default.
213    
214    \fB-\-devtree\fR=\fIpath\fR
215    Use \fIpath\fR for device tree path in place of the path of any devicetree
216    directive found in the template stanza.
217    
218    .SS Multiboot Options
219    
220  The Multiboot Specification provides a genreic interface for boot  The Multiboot Specification provides a genreic interface for boot
221  loaders and operating systems.  It is supported by the GRUB bootloader.  loaders and operating systems.  It is supported by the GRUB bootloader.
222    
# Line 178  Add a new boot entry for the multiboot k Line 228  Add a new boot entry for the multiboot k
228    
229  .TP  .TP
230  \fB-\-remove-multiboot\fR=\fImultiboot-path\fR  \fB-\-remove-multiboot\fR=\fImultiboot-path\fR
231  Removes all boot entries which match \fImultiboot-path\fR.  Removes all boot entries which match \fImultiboot-path\fR.
232    
233  .TP  .TP
234  \fB-\-mbargs\fR=\fImultiboot-args\fR  \fB-\-mbargs\fR=\fImultiboot-args\fR
235  When a new multiboot kernel is added, this specifies the command line  When a new multiboot kernel is added, this specifies the command line
236  arguments which should be passed to that kernel by default  arguments which should be passed to that kernel by default
237  When \fB-\-update-kernel\fR is used, this specifies new arguments to add  When \fB-\-update-kernel\fR is used, this specifies new arguments to add
238  to the argument list. Multiple, space separated arguments may be used. If  to the argument list. Multiple, space separated arguments may be used. If
239  an argument already exists the new value replaces the old values.  an argument already exists the new value replaces the old values.
240    
241  .TP  .TP
242  \fB-\-remove-mbargs\fR=\fImultiboot-args\fR  \fB-\-remove-mbargs\fR=\fImultiboot-args\fR
243  The arguments specified by \fImultiboot-args\fR are removed from the  The arguments specified by \fImultiboot-args\fR are removed from the
244  kernels specified by \fB-\-update-kernel\fR.  kernels specified by \fB-\-update-kernel\fR.
   
245    
246  .SH "BUGS"  .SH "BUGS"
247    
248  The command line syntax is more than a little baroque. This probably  The command line syntax is more than a little baroque. This probably
249  won't be fixed as \fBgrubby\fR is only intended to be called from shell  won't be fixed as \fBgrubby\fR is only intended to be called from shell
250  scripts which can get it right.  scripts which can get it right.
251    
252  .SH "SEE ALSO"  .SH "SEE ALSO"
253    
254  .BR grub (8),  .BR grub (8),
255  .BR lilo (8),  .BR lilo (8),
256  .BR yaboot (8),  .BR yaboot (8),
257  .BR mkinitrd (8)  .BR mkinitrd (8)
258    
259  .SH AUTHORS  .SH AUTHORS
260    
261  .nf  .nf
262  Erik Troan  Erik Troan
263  Jeremy Katz  Jeremy Katz

Legend:
Removed from v.1332  
changed lines
  Added in v.3012