Remove allow_root mount opt, since it conflicts with allow_other
[genkernel.git] / genkernel.8
1 .TH GENKERNEL "8" "June 2006" "genkernel 3.3" "Gentoo Linux"
2 .SH NAME
3 genkernel \- the Gentoo Linux automatic kernel compiler.
4 .SH SYNOPSIS
5 \fBgenkernel\fR \fI[options...] action\fR
6 .SH INTRODUCTION
7 Genkernel is designed to allow users who are not previously used to
8 compiling a kernel to use a similar setup to that one that is used on
9 the Gentoo LiveCDs which auto-detects your hardware.
10 .PP
11 Some users may also be interested in using genkernel for hardware
12 which requires initialization and a working kernel before it can be
13 booted because genkernel also automatically compiles your kernel
14 modules, allowing hardware which needs to be loaded with module
15 parameters to be used.
16 .SH USAGE
17 All that is needed to run genkernel is just ``genkernel'' with an action
18 and any flags you might need:
19 .PP
20 # genkernel --menuconfig --no-clean --no-install all
21 .PP
22 This would produce a kernel, asking you what how to configure it
23 to your desire, leaving alone any existing compiled object files, but not
24 installing anything.
25 .SH ACTIONS
26 An action tells genkernel what you want it to do - the following
27 actions are supported:
28 .PP
29 .I \fBall\fR
30 .RS
31 Build all steps - the kernel, modules, and the ramdisk.
32 .RE
33 .I \fBbzImage\fR
34 .RS
35 Build only the kernel.
36 .RE
37 .I \fBkernel\fR
38 .RS
39 Build only the kernel and the modules.
40 .RE
41 .I \fBinitramfs\fR
42 .RS
43 Build only the ramdisk.
44 .RE
45 .SH OPTIONS
46 Genkernel supports the following options which alter its
47 behaviour. Certain options have ``\fB--no-\fR'' variants which
48 do the opposite thing. You can specify your options in any order.
49 .PP
50 .BR Debugging \ Options
51 .TP
52 \fB\-\-loglevel=\fR<0-5>
53 This controls the out verbosity level of genkernel output - if this is set
54 to 0, minimal debugging is done; if this is set to 5 as much output as
55 possible is given.
56 .TP
57 \fB\-\-logfile=\fR<outfile>
58 This outputs debugging data to the file <outfile>. By default this is
59 .I /var/log/genkernel.log\fR.
60 .TP
61 \fB\-\-\fR[no\-]\fBcolor\fR
62 Turns on, or off, output in color using escape sequences.
63 .PP
64 .BR Kernel \ Configuration
65 .TP
66 \fB\-\-\fR[no\-]\fBmenuconfig\fR
67 Runs, or does not run "make menuconfig" after running "make oldconfig".
68 .TP
69 \fB\-\-\fR[no\-]\fBsave\-config\fR
70 Saves, or does not save the kernel configuration to
71 .I /etc/kernels
72 if the kernel is successfully compiled.
73 .TP
74 \fB\-\-gconfig\fR
75 Run "make gconfig" after "make oldconfig".
76 .TP
77 \fB\-\-xconfig\fR
78 Run "make xconfig" after "make oldconfig".
79 .PP
80 .BR Kernel \ Compilation
81 .TP
82 \fB\-\-\fR[no\-]\fBclean\fR
83 Runs, or does not run, "make clean" before compilation - this erases any
84 compiled object files in the kernel source tree but does not have an impact
85 on the kernel configuration. Specifying \fB\-\-no\-clean\fR implies
86 \fB\-\-no\-mrproper\fR.
87 .TP
88 \fB\-\-\fR[no\-]\fBmrproper\fR
89 Runs, or does not run, "make mrproper" before compilation - this erases both
90 any compiled object files in the kernel source tree as well as the kernel
91 configuration.
92 .TP
93 \fB\-\-\fR[no\-]\fBinstall\fR
94 Installs, or does not install the kernel to
95 .I /boot
96 after building. The default is --install.  If MOUNTBOOT is set in
97 .I /etc/genkernel.conf
98 then
99 .I /boot
100 will be automatically mounted if it is
101 not already mounted before the ramdisk and kernel images are copied over.
102 .TP
103 \fB\-\-\fR[no\-]\fBsymlink\fR
104 Manages, or does not manage, symlinks in 
105 .I /boot
106 like the manual kernel "make install" process does. A
107 .I kernel
108 (or, depending on options, 
109 .I kernelz\fR)
110 symlink will link to the most recently built kernel image and a
111 .I kernel.old
112 (or
113 .I kernelz.old\fR)
114 symlink will link to the second most recently built image, if one exists.
115 Similar symlinks (both * and *.old) are managed for
116 .I initramfs\fR
117 and
118 .I System.map\f.
119 The corresponding work products (i.e., the actual kernel and initamfs images, 
120 and System.map) are also managed accordingly.  NOTE:  Specifying --symlink 
121 does nothing unless --install is also specified.
122 .TP
123 \fB\-\-no\-initrdmodules\fR
124 Don't copy any modules to the ramdisk.
125 .TP
126 \fB\-\-oldconfig\fR
127 Implies \fB\-\-no\-clean\fR, and thus \fB\-\-no\-mrproper\fR, running a
128 "make oldconfig".
129 .TP
130 \fB\-\-callback=\fR<...>
131 Run the specified arguments in the current environment after the kernel and
132 modules have been compiled.
133 .PP
134 .BR Kernel \ Locations
135 .TP
136 \fB\-\-kerneldir=\fR<dir>
137 This specifies the location of the kernel sources; the default is
138 /usr/src/linux.
139 .TP
140 \fB\-\-kernel\-config=\fR<file>
141 This specifies a kernel configuration file to use for compilation; by
142 default genkernel uses the config from the previous build of the same kernel
143 version or a default kernel config if there isn't a previous config.
144 .PP
145 .BR Low-Level \ Compilation \ Options
146 .TP
147 \fB\-\-kernel\-cc=\fR<compiler>
148 Compiler to use for the kernel compilation (e.g. distcc).
149 .TP
150 \fB\-\-kernel\-as=\fR<assembler>
151 Assembler to use for the kernel compilation.
152 .TP
153 \fB\-\-kernel\-ld=\fR<linker>
154 Linker to use for the kernel compilation.
155 .TP
156 \fB\-\-kernel\-make=\fR<makeprg>
157 GNU Make to use for the kernel compilation.
158 .TP
159 \fB\-\-utils\-cc=\fR<compiler>
160 Compiler to use for utilities.
161 .TP
162 \fB\-\-utils\-as=\fR<assembler>
163 Assembler to use for utilities.
164 .TP
165 \fB\-\-utils\-ld=\fR<linker>
166 Linker to use for utilities.
167 .TP
168 \fB\-\-utils\-make=\fR<makeprog>
169 GNU Make to use for utilities.
170 .TP
171 \fB\-\-makeopts=\fR<makeopts>
172 GNU Make options such as \fB\-j2\fR, etc.
173 .PP
174 .BR Initialization
175 .TP
176 \fB\-\-\fR[no\-]\fBsplash=\fR<theme>
177 If the extra argument is specified, splash is forced using <theme>
178 rather than the default theme specified in your splash
179 configuration. If \fB\-\-no-splash\fR is specified, then
180 splash is disabled.
181 .TP
182 \fB\-\-splash-res=\fR<resolutions>
183 Optionally select splash resolutions to include.
184 .TP
185 \fB\-\-do\-keymap\-auto\fR
186 Force keymap selection at boot.
187 .TP
188 \fB\-\-dmraid\fR
189 Add DMRAID support.
190 .TP
191 \fB\-\-evms\fR
192 Add in EVMS support from static binaries if they exist on the system:
193 you should run "emerge evms" first.
194 .TP
195 \fB\-\-lvm\fR
196 .RS
197 Add in LVM support from static binaries if they exist on the system,
198 or compile static LVM binaries if static ones do not exist.
199 .RE
200 .TP
201 \fB\-\-luks\fR
202 .RS
203 Add in Luks support from static binaries if they exist on the 
204 system.
205 .RE
206 .TP
207 \fB\-\-static\fR
208 This builds a monolithic kernel without any modules on any initial ramdisks.
209 .TP
210 \fB\-\-linuxrc=\fR<file>
211 Use <file> for the linuxrc instead of the genkernel linuxrc.
212 .PP
213 .BR Internals
214 .TP
215 \fB\-\-arch\-override=\fR<arch>
216 Force the architecture settings described by the <arch> profile
217 instead of autodetecting the running architecture.
218 .TP
219 \fB\-\-tempdir=\fR<dir>
220 Sets genkernel's temporary working directory to <dir>.
221 .PP
222 .BR Output \ Settings
223 .TP
224 \fB\-\-kernname=\fR<...>
225 Tag the kernel and initrd with a name, if not defined this option defaults to genkernel
226 .TP
227 \fB\-\-minkernpackage=\fR<tbz2>
228 File to output a .tar.bz2'd kernel and initrd: no modules outside of the
229 initrd will be included...
230 .TP
231 \fB\-\-modulespackage=\fR<tbz2>
232 File to output a .tar.bz2'd modules after the callbacks have run
233 .TP
234 \fB\-\-kerncache=\fR<tbz2>
235 File to output a .tar.bz2'd kernel, contents of /lib/modules/ and the kernel config.
236 \fBNOTE\fR: This is created before the callbacks are run.
237 .TP
238 \fB\-\-no\-kernel\-sources=\fR<tbz2>
239 This option is only valid if kerncache is defined
240 If there is a valid kerncache no checks will be made
241 against a kernel source tree.
242 .TP
243 \fB\-\-initramfs\-overlay=\fR<dir>
244 Directory structure to include in the initramfs,
245 only available on 2.6 kernels
246 .SH RAMDISK OPTIONS
247 The following options can be passed as kernel parameters from the
248 bootloader, which the ramdisk scripts would recognize.
249 .TP
250 \fBreal_root=\fR<...>
251 Specifies the device node of the root filesystem to mount.
252 .TP
253 \fBcrypt_root=\fR<...>
254 This specifies the device encrypted by Luks, which contains the root 
255 filesystem to mount.
256 .TP
257 \fBcrypt_swap=\fR<...>
258 This specifies the swap device encrypted by Luks.
259 .TP
260 \fBroot_key=\fR<...>
261 In case your root is encrypted with a key, you can use a device like a usb pen to store the key. 
262 This value should be the key path relative to the mount point.
263 .TP
264 \fBroot_keydev=\fR<...>
265 If necessary provide the name of the device that carries the root_key.
266 If unset while using root_key, it will automatically look for the device in every boot.
267 .TP
268 \fBswap_key=\fR<...>
269 Same as root_key for swap.
270 .TP
271 \fBswap_keydev=\fR<...>
272 Same as root_keydev for swap.
273 .TP
274 \fBcrypt_silent\fR
275 Set this to silent all the output related to the cryptographic software, and in case your encrypted device isn't open with the key, it opens a shell in the initrd quietly.
276 .TP
277 \fBdodmraid=\fR<...>
278 Passes arguments to dmraid on bootup.
279 .TP
280 \fBreal_init=\fR<...>
281 Passes arguments to init on bootup.
282 .TP
283 \fBscandelay=\fR<...>
284 Pauses for 10 seconds before running devfsd if no argument is specified;
285 otherwise pauses for the number of specified seconds.
286 .TP 
287 \fBip=\fR<...>
288 Normally used to tell the kernel that it should start a network interface. If present, the initrd will try to mount a livecd over NFS.
289 .TP 
290 \fBnfsroot=\fR<...>
291 If present, the initrd will try to mount a livecd from that location. Otherwise the location will be deduced from the DCHP request (option root\-path)
292 .TP
293 \fBdoevms\fR
294 Activate EVMS volumes on bootup
295 .TP
296 \fBdolvm\fR
297 Activate LVM volumes on bootup
298 .TP
299 \fBdoscsi\fR
300 Activate SCSI devices on bootup, necessary when SCSI support is compiled as modules and you're using SCSI or SATA devices.
301
302 .SH NETBOOTING
303 The initrd scripts have limited support for network booting.
304 This is activated if the ip=<...> kernel parameter was given. Please refer to the genkernel guide at http://www.gentoo.org/doc/en/genkernel.xml for more information.
305
306 The initrd scripts will extract any *.tar.gz files found in the \fB/add\fR directory of the livecd into the root filesystem during boot. This way it is easy to extend a netbooted LiveCD i.e. add custom tools, or other kernel modules.
307 .SH REPORTING BUGS
308 If you believe you have found a bug in the genkernel scripts, then please
309 file a bug on the Gentoo Linux Bugzilla: 
310 .I http://bugs.gentoo.org\fR,
311 assigning your bug to genkernel@gentoo.org. We cannot assist you
312 with kernel compilation failures unless they are caused by a genkernel
313 bug.
314 .PP
315 Kernel issues for Gentoo-supported kernels, including compilation
316 failures should go to
317 .I http://bugs.gentoo.org
318 and should be assigned to kernel@gentoo.org. Please check if an
319 existing bug documents the same issue before opening a new bug. Issues
320 for kernel sources not supported by Gentoo should go to their relevant
321 authors.
322 .SH AUTHORS
323 .nf
324 Tim Yamin <plasmaroo@gentoo.org>
325 Eric Edgar <rocket@gentoo.org>
326 NFS Support by Thomas Seiler <thseiler@gmail.com>
327 .fi
328 .SH SEE ALSO
329 \fB/etc/genkernel.conf\fR \- genkernel configuration file