Changed all instances of EVMS2/LVM2 to EVMS/LVM, respectively. This will keep everyt...
[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, butt 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 initrd.
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 \fBinitrd\fR
42 .RS
43 Build only the initrd.
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\-\-debuglevel=\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\-\-debugfile=\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 initrd and kernel image is 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 (or
117 .I initrd\fR)
118 and
119 .I System.map\f.
120 The corresponding work products (i.e., the actual kernel and inirtamfs images, 
121 and System.map) are also managed accordingly.  NOTE:  Specifying --symlink 
122 does nothing unless --install is also specified.
123 .TP
124 \fB\-\-no\-initrdmodules\fR
125 Don't copy any modules to the initrd.
126 .TP
127 \fB\-\-oldconfig\fR
128 Implies \fB\-\-no\-clean\fR, and thus \fB\-\-no\-mrproper\fR, running a
129 "make oldconfig".
130 .TP
131 \fB\-\-callback=\fR<...>
132 Run the specified arguments in the current environment after the kernel and
133 modules have been compiled.
134 .PP
135 .BR Kernel \ Locations
136 .TP
137 \fB\-\-kerneldir=\fR<dir>
138 This specifies the location of the kernel sources; the default is
139 /usr/src/linux.
140 .TP
141 \fB\-\-kernel\-config=\fR<file>
142 This specifies a kernel configuration file to use for compilation; by
143 default .config in the kernel source tree is used.
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. \fB\-j\fRX is filtered during the
173 module compilation stage of 2.4 series kernels to avoid bottlenecks; the
174 2.6 build system does not have this issue and \fB\-j\fRX is not filtered for it.
175 .PP
176 .BR Initialization
177 .TP
178 \fB\-\-\fR[no\-]\fBgensplash=\fR<theme>
179 If the extra argument is specified, gensplash is forced using <theme>
180 rather than the default theme specified in your gensplash
181 configuration. If \fB\-\-no-gensplash\fR is specified, then
182 gensplash is disabled.
183 .TP
184 \fB\-\-gensplash-res=\fR<resolutions>
185 Optionally select gensplash resolutions to include.
186 .TP
187 \fB\-\-do\-keymap\-auto\fR
188 Force keymap selection at boot.
189 .TP
190 \fB\-\-dmraid\fR
191 Add DMRAID support.
192 .TP
193 \fB\-\-evms\fR
194 Add in EVMS support from static binaries if they exist on the system:
195 you should run "emerge evms" first.
196 .TP
197 \fB\-\-lvm\fR
198 .RS
199 Add in LVM support from static binaries if they exist on the system,
200 or compile static LVM binaries if static ones do not exist.
201 .RE
202 .TP
203 \fB\-\-luks\fR
204 .RS
205 Add in Luks support from static binaries if they exist on the 
206 system.
207 .RE
208 .TP
209 \fB\-\-no-udev\fR
210 Force devfs on 2.6 series kernels. Not recommended or supported.
211 .TP
212 \fB\-\-static\fR
213 This builds a monolithic kernel without any modules on any initial ramdisks.
214 .TP
215 \fB\-\-linuxrc=\fR<file>
216 Use <file> for the linuxrc instead of the genkernel linuxrc.
217 .PP
218 .BR Internals
219 .TP
220 \fB\-\-arch\-override=\fR<arch>
221 Force the architecture settings described by the <arch> profile
222 instead of autodetecting the running architecture.
223 .TP
224 \fB\-\-tempdir=\fR<dir>
225 Sets genkernel's temporary working directory to <dir>.
226 .PP
227 .BR Output \ Settings
228 .TP
229 \fB\-\-kernname=\fR<...>
230 Tag the kernel and initrd with a name, if not defined this option defaults to genkernel
231 .TP
232 \fB\-\-minkernpackage=\fR<tbz2>
233 File to output a .tar.bz2'd kernel and initrd: no modules outside of the
234 initrd will be included...
235 .TP
236 \fB\-\-modulespackage=\fR<tbz2>
237 File to output a .tar.bz2'd modules after the callbacks have run
238 .TP
239 \fB\-\-kerncache=\fR<tbz2>
240 File to output a .tar.bz2'd kernel, contents of /lib/modules/ and the kernel config.
241 \fBNOTE\fR: This is created before the callbacks are run.
242 .TP
243 \fB\-\-no\-kernel\-sources=\fR<tbz2>
244 This option is only valid if kerncache is defined
245 If there is a valid kerncache no checks will be made
246 against a kernel source tree.
247 .TP
248 \fB\-\-initramfs\-overlay=\fR<dir>
249 Directory structure to inject into the initramfs.
250 use a CPIO archive as a parameter.
251 .SH INITRD OPTIONS
252 The following options can be passed as kernel parameters from the
253 bootloader, which the initrd scripts would recognize.
254 .TP
255 \fBreal_root=\fR<...>
256 Specifies the device node of the root filesystem to mount.
257 .TP
258 \fBcrypt_root=\fR<...>
259 This specifies the device encrypted by Luks, which contains the root 
260 filesystem to mount.
261 .TP
262 \fBdodmraid=\fR<...>
263 Passes arguments to dmraid on bootup.
264 .TP
265 \fBreal_init=\fR<...>
266 Passes arguments to init on bootup.
267 .TP
268 \fBscandelay=\fR<...>
269 Pauses for 10 seconds before running devfsd if no argument is specified;
270 otherwise pauses for the number of specified seconds.
271 .TP 
272 \fBip=\fR<...>
273 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.
274 .TP 
275 \fBnfsroot=\fR<...>
276 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)
277 .TP
278 \fBdoevms\fR
279 Activate EVMS volumes on bootup
280 .TP
281 \fBdolvm\fR
282 Activate LVM volumes on bootup
283 .TP
284 \fBdoscsi\fR
285 Activate SCSI devices on bootup, necessary when SCSI support is compiled as modules and you're using SCSI or SATA devices.
286
287 .SH NETBOOTING
288 The initrd scripts have limited support for network booting.
289 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.
290
291 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.
292 .SH REPORTING BUGS
293 If you believe you have found a bug in the genkernel scripts, then please
294 file a bug on the Gentoo Linux Bugzilla: 
295 .I http://bugs.gentoo.org\fR,
296 assigning your bug to genkernel@gentoo.org. We cannot assist you
297 with kernel compilation failures unless they are caused by a genkernel
298 bug.
299 .PP
300 Kernel issues for Gentoo-supported kernels, including compilation
301 failures should go to
302 .I http://bugs.gentoo.org
303 and should be assigned to kernel@gentoo.org. Please check if an
304 existing bug documents the same issue before opening a new bug. Issues
305 for kernel sources not supported by Gentoo should go to their relevant
306 authors.
307 .SH AUTHORS
308 .nf
309 Tim Yamin <plasmaroo@gentoo.org>
310 Eric Edgar <rocket@gentoo.org>
311 NFS Support by Thomas Seiler <thseiler@gmail.com>
312 .fi
313 .SH SEE ALSO
314 \fB/etc/genkernel.conf\fR \- genkernel configuration file