Remove -T option
[grml-live.git] / docs / grml-live.txt
1 grml-live(8)
2 ============
3
4 Name
5 ----
6
7 grml-live - build framework based on FAI for generating a Grml and Debian based
8 Linux Live system (CD/ISO)
9
10 Synopsis
11 --------
12
13 grml-live [-a <architecture>] [-c <classe[s]>] [-C <configfile>] [
14 -e <extract_iso_name>] [-g <grml_name>] [-i <iso_name>] [
15 -o <output_directory>] [-r <release_name>] [-s <suite>] [
16 -t <template_directory>] [-v <version_number>] [-U <username>] [
17 -AbBFnNqQuVz]
18
19 Description
20 -----------
21
22 grml-live provides the build system for creating a Grml and Debian based Linux
23 Live-CD. The build system is based on
24 link:http://fai-project.org/[FAI] (Fully Automatic
25 Installation). grml-live uses the "fai dirinstall" feature to generate a chroot
26 system based on the class concept of FAI (see later sections for further
27 details) and provides the framework to be able to generate a full-featured ISO.
28 It does not use all the FAI features by default though and you don't have to
29 know FAI to be able to use it.
30
31 The use of FAI gives you the flexibility to choose the packages you would like
32 to include on your very own Linux Live-CD without having to deal with all the
33 details of a build process.
34
35 CAUTION: grml-live does **not** use /etc/fai for configuration but instead
36 provides and uses ${GRML_FAI_CONFIG} which is pointing to /etc/grml/fai by default
37 (unless overridden using the ''-D'' option). This ensures that it does not clash
38 with default FAI configuration and packages, so you can use grml-live and FAI
39 completely independent at the same time!
40
41 [NOTE]
42
43 Please notice that you should have a fast network connection as all the Debian
44 packages will be downloaded and installed via network. If you want to use a
45 local mirror (strongly recommended if you plan to use grml-live more than once)
46 checkout mkdebmirror (see /usr/share/doc/grml-live/examples/mkdebmirror),
47 debmirror(1), reprepro(1) (see /usr/share/doc/grml-live/examples/reprepro/ for a
48 sample configuration), apt-cacher(1) and approx(8). To avoid downloading the
49 base system again and again check out <<create-a-base-tgz,the base tar.gz
50 feature>>.
51
52 Options
53 -------
54
55   -A::
56
57 Clean up output directories before attempting the build. Packs the chroot
58 into a tar archive, and removes chroot and ISO build directories before exiting.
59
60   -a **ARCHITECTURE**::
61
62 Use the specified architecture instead of the currently running one.  This
63 allows building a 32bit system on a 64bit host (though you can't build a 64bit
64 system on a 32bit system/kernel of course). Please notice that real
65 crosscompiling (like building a ppc system on x86) isn't possible due to the
66 nature and the need of working in a chroot. Currently supported values: i386
67 and amd64.
68
69   -b::
70
71 Build the ISO without updating the chroot via FAI. This option is useful for
72 example when working on stable releases: if you have a working base
73 system/chroot and do not want to execute any further updates (via "-u" option)
74 but intend to only build the ISO.
75
76   -B::
77
78 Build the ISO without touching the chroot at all. This option is useful if
79 you modified anything that FAI or grml-live might adjust via Grml's FAI
80 scripts.  It's like the '-b' option but even more advanced. Use only if you
81 really know that you do not want to update the chroot.
82
83   -c **CLASSES**::
84
85 Specify the CLASSES to be used for building the ISO via FAI.  By default only
86 the classes GRMLBASE, GRML_FULL and I386/AMD64 (depending on system
87 architecture) are assumed, resulting in a base system of about 350MB
88 total ISO size. If using a non-I386 system (like AMD64) you should specify the
89 appropriate architecture as well. Additionally you can specify a class providing
90 a grml-kernel (see <<classes,the 'CLASSES' section in this document>> for
91 details about available classes).  So instead of GRML_FULL you can also use
92 GRML_SMALL and GRML_FULL.
93
94 [IMPORTANT]
95 All class names should be written in uppercase letters. Do not use a dash, use
96 an underscore. So do not use "amd64" but "AMD64", do not use "FOO BAR" but
97 "FOO_BAR".
98
99
100   -C **CONFIGURATION_FILE**::
101
102 The specified file is used as configuration file for grml-live. By default
103 /etc/grml/grml-live.conf is used as default configuration. If a file named
104 /etc/grml/grml-live.local exists it is used as well (sourced after reading
105 /etc/grml/grml-live.conf meant as main file for local configuration). As a last
106 option the specified configuration file is sourced so it is possible to override
107 settings of /etc/grml/grml-live.conf as well as of /etc/grml/grml-live.local.
108 Please notice that all configuration files have to be adjusted during execution
109 of grml-live, so please make sure you use /etc/grml/grml-live.conf as a base for
110 your own configuration file (usually /etc/grml/grml-live.local). Please also
111 notice that the configuration file specified via this option is **not** (yet)
112 supported inside the scripts/hooks/classes at ${GRML_FAI_CONFIG}/config. Instead use
113 /etc/grml/grml-live.local for configuration stuff used inside
114 ${GRML_FAI_CONFIG}/config.
115
116   -d **DATE**::
117
118 Use specified date as build date information on the ISO instead of the default.
119 The default is the date when grml-live is being executed (retrieved via
120 executing 'date +%Y-%m-%d'). The information is stored inside the file
121 /GRML/grml-version on the ISO, /etc/grml_version in the squashfs file and in all
122 the bootsplash related files. This option is useful if you want to provide an
123 ISO with release information for a specific date but have to build it in
124 advance. Usage example: '-d 2009-10-30'
125
126   -D **CONFIGURATION_DIRECTORY**::
127
128 The specified directory is used as configuration directory for grml-live and its
129 FAI. By default /etc/grml/fai is used as default configuration directory.  If
130 you want to have different configuration scripts, package definitions, etc. with
131 without messing with the global configuration under /etc/grml/fai provided by
132 grml-live this option provides you the option to use your own configuration
133 directory. This directory is what's being referred to as ${GRML_FAI_CONFIG}
134 throughout this documentation.
135
136   -e **EXTRACT_ISO_NAME**::
137
138 The squashfs inside the specified ISO will be extracted and used as the chroot.
139 This option is useful for remastering, in combination with -A and -b or -u.
140
141   -F::
142
143 Force execution and do not prompt for acknowledgment of configuration.
144
145   -g **GRML_NAME**::
146
147 Set the grml flavour name. Common usage examples: grml, grml-small, grml64.
148 Please do NOT use blanks and any special characters like '/', ';' inside
149 GRML_NAME, otherwise you might notice problems while booting.
150
151   -h::
152
153 Display short usage information and exit.
154
155   -i **ISO_NAME**::
156
157 Specify name of ISO which will be available inside $OUTPUT_DIRECTORY/grml_isos
158 by default.
159
160   -I **CHROOT_INSTALL**::
161
162 Specify name of source directory which provides files that should become part of
163 the chroot/ISO. Not enabled by default. Note: the files are installed under '/'
164 in the chroot so you have to create the rootfs structure on your own.
165
166   -n::
167
168 Skip creation of the ISO file. This option is useful if you want to build/update
169 the chroot and/or recreate the squashfs file without building an ISO file.
170
171   -N::
172
173 Bootstrap the chroot without building bootloader, squashfs, or finalizing the
174 ISO. Use this option if installation of some packages fails, you want to run
175 custom commands or similar.
176 The main use of this option is to save time by skipping stages which aren't
177 necessary for bootstrapping the chroot and which would get executed more than
178 once when iterating through the initial bootstrapping.
179 Alternatively, use this option as a test run of grml-live. Once you are
180 satisfied with the state of your grml_chroot, use grml-live **-u** to build the
181 remaining stages and finalize the ISO.
182
183   -o **OUTPUT_DIRECTORY**::
184
185 Main output directory of the build process of FAI.  Some directories are created
186 inside this target directory, being: grml_cd (where the files for creating the
187 ISO are located, including the compressed squashfs file), grml_chroot (the
188 chroot system) and grml_isos (where the resulting ISO is stored).
189
190   -q::
191
192 Build the ISO without (re-)creating the squashfs compressed file using mksquashfs.
193 This option is useful if you just want to update parts outside the chroot in the ISO.
194 Consider combining this option with the build-only option '-b'.
195
196   -Q::
197
198 Build the ISO without generating a netboot package.
199
200   -r **RELEASENAME**::
201
202 Specify name of the release.
203
204   -s **SUITE**::
205
206 Specify the Debian suite you want to use for your live-system.  Defaults to
207 "squeeze" (being current Debian/stable). Supported values are: etch, lenny,
208 squeeze, sid. Debian "squeeze" requires a recent base.tgz
209 (${GRML_FAI_CONFIG}/config/basefiles/$CLASSNAME.tar.gz) or a recent version of
210 debootstrap.
211
212   -t **TEMPLATE_DIRECTORY**::
213
214 Specify place of the templates used for building the ISO. By default
215 (and if not manually specified) this is /usr/share/grml-live/templates/.
216
217   -u::
218
219 Update existing chroot instead of rebuilding it from scratch. This option is
220 based on the softupdate feature of FAI.
221
222   -U **USERNAME**::
223
224 Sets ownership of all build output files to specified username before exiting.
225
226   -v **VERSION_NUMBER**::
227
228 Specify version number of the release.
229
230   -V::
231
232 Increase verbosity in the build process.
233
234   -z::
235
236 Use ZLIB instead of LZMA/XZ compression in mksquashfs part of the build process.
237
238 [[usage-examples]]
239 Usage examples
240 --------------
241
242 To get a Debian-stable and Grml-based Live-CD using /grml/grml-live
243 as build and output directory just run:
244
245   # grml-live
246
247 To get a 64bit Debian-testing and grml-small based Live-CD using /srv/grml-live
248 as build and output directory use the following command line on your amd64
249 system:
250
251   # grml-live -s testing -c GRMLBASE,GRML_SMALL,AMD64 -o /srv/grml-live
252
253 [NOTE]
254
255 If you have enough free space inside /dev/shm (being a tmpfs, usually you should
256 have >=1GB of RAM) just run "mount -o remount,suid,dev,rw /dev/shm" and use
257 /dev/shm as build and output directory - resulting in very fast build process.
258 But please be aware of the fact that rebooting your system will result in an
259 empty /dev/shm, so please use another directory for $CHROOT_OUTPUT,
260 $BUILD_OUTPUT and $ISO_OUTPUT if you plan to create more persistent output. :)
261
262 [[main-features]]
263 Main features of grml-live
264 --------------------------
265
266 * create a Grml-/Debian-based Linux Live-CD with one single command
267
268 * class based concept, providing a maximum of flexibility
269
270 * supports integration of own hooks, scripts and configuration
271
272 * supports use and integration of own Software and/or Kernels via simple use of
273 Debian repositories
274
275 * native support of FAI features
276
277 [[class-concept]]
278 The class concept
279 -----------------
280
281 grml-live uses FAI and its class based concept for adjusting configuration and
282 setup according to your needs. This gives you flexibility and strength without
283 losing the simplicity in the build process.
284
285 The main and base class provided by grml-live is named GRMLBASE. It's strongly
286 recommended to **always** use the class GRMLBASE when building an ISO using
287 grml-live, as well as the architecture dependent class which provides the kernel
288 (being 'I386' for x86_32 and 'AMD64' for x86_64) and a GRML_* class (like
289 GRML_SMALL, GRML_MEDIUM or GRML_FULL). The following files and directories are
290 relevant for class GRMLBASE by default:
291
292   ${GRML_FAI_CONFIG}/config/scripts/GRMLBASE/
293   ${GRML_FAI_CONFIG}/config/debconf/GRMLBASE
294   ${GRML_FAI_CONFIG}/config/class/GRMLBASE.var
295   ${GRML_FAI_CONFIG}/config/hooks/instsoft.GRMLBASE
296   ${GRML_FAI_CONFIG}/config/package_config/GRMLBASE
297
298 Take a look at the next section for information about the concept of those
299 files/directories.
300
301 If you want to use your own configuration, extend an existing configuration
302 and/or add additional packages to your ISO just invent a new class (or extend an
303 existing one). For example if you want to use your own class named "FOOBAR" just
304 set CLASSES="GRMLBASE,GRML_SMALL,AMD64,FOOBAR" inside /etc/grml/grml-live.local
305 or invoke grml-live using the classes option: "grml-live -c
306 GRMLBASE,GRML_SMALL,AMD64,FOOBAR ...".
307
308 More details regarding the class concept can be found in the documentation of
309 FAI itself (being available at /usr/share/doc/fai-doc/).
310
311 [[X7]]
312 [[classes]]
313 Available classes
314 -----------------
315
316 The package selection part of the classes can be found in
317 ${GRML_FAI_CONFIG}/config/package_config whereas some further classes are defined for
318 example in ${GRML_FAI_CONFIG}/config/scripts/ so specific feature sets can be
319 selected. The following classes are predefined:
320
321 * DEBORPHAN: get rid of all packages listed in output of deborphan
322
323 * GRMLBASE: the main class responsible for getting a minimal subset of what's
324 defining a Grml system. Important parts of the buildprocess are specified in
325 this class as well, so unless you have a really good reason you should always
326 use this class.
327
328 * GRML_FULL: full featured Grml, also known as the "normal", full grml as
329 introduced in December 2011 (~350MB ISO size).
330
331 * GRML_MEDIUM: medium sized Grml version, used to be known as grml-medium
332 until December 2011 (~220MB ISO size).
333
334 * GRML_SMALL: minimum sized Grml version, known as grml-small (~110MB ISO
335 size).
336
337 * GRML_XL: large size Grml version, used to be known as "full grml" until
338 December 2011 (~700MB ISO size).
339
340 * LATEX: LaTeX(-related) packages like auctex, texlive,...
341 (which used to be shipped by grml before the LaTeX removal)
342
343 * LATEX_CLEANUP: get rid of several very large LaTeX directories
344 (like some /usr/share/doc/texlive-*, /usr/share/doc/texmf,...)
345
346 * LOCALES: use full featured locales setup (see /etc/locale.gen.grml). This
347 avoids to get rid of /usr/share/locale - which happens by default otherwise - as
348 well.
349
350 * NO_ONLINE: do not run scripts during the chroot build process which require a
351 network connection
352
353 * RELEASE: run some specific scripts and commands to provide the workflow for an
354 official grml release
355
356 * REMOVE_DOCS: get rid of documentation directories (like /usr/share/doc,
357 /usr/share/man/, /usr/share/info,...)
358
359 * SOURCES: retrieve Debian source packages after installation. Files will be
360 placed in the output directory under grml_sources.
361
362 * XORG: providing important packages for use with a base grml-featured X.org
363 setup
364
365 [[files]]
366 Files
367 -----
368
369 Notice that grml-live ships FAI configuration files that do not use the same
370 namespace as the FAI packages itself. This ensures that grml-live does not clash
371 with your usual FAI configuration, so instead of /etc/fai/fai.conf (package
372 fai-client) grml uses ${GRML_FAI_CONFIG}/fai.conf instead. For more details see
373 below. To get an idea how another configuration or example files could look like
374 check out /usr/share/doc/fai-doc/examples/simple/ (provided by Debian package
375 fai-doc). Furthermore /usr/share/doc/fai-doc/fai-guide.html/ch-config.html
376 provides documentation regarding configuration possibilities.
377
378   /usr/sbin/grml-live
379
380 Script for the main build process. Requires root permissions for execution.
381
382   /etc/grml/grml-live.conf
383
384 Main configuration file for grml-live which should be considered as a reference
385 configuration file only. Please use /etc/grml/grml-live.local for local
386 configuration instead.
387
388   /etc/grml/grml-live.local
389
390 All the local configuration should go to this file. This file overrides any
391 defaults of grml-live. Configurations via /etc/grml/grml-live.local are preferred
392 over the ones from /etc/grml/grml-live.conf. If you want to override settings
393 from /etc/grml/grml-live.local as well you have to specify them on the grml-live
394 commandline.
395
396   ${GRML_FAI_CONFIG}/fai.conf
397
398 Main configuration file for FAI which specifies where all the configuration
399 files and scripts for FAI/grml-live can be found. By default the configuration
400 variables are FAI_CONFIG_SRC=file:///etc/grml/fai/config and
401 GRML_FAI_CONFIG=/etc/grml/fai/config - both pointing to a directory shipped by
402 grml-live out-of-the-box so you shouldn't have to configure anything in this
403 file.
404
405   ${GRML_FAI_CONFIG}/make-fai-nfsroot.conf
406
407 This file is used by make-fai-nfsroot(8) only. Usually you don't have to change
408 anything inside this file. If you want to modify NFSROOT though you can adjust
409 it there.
410
411   ${GRML_FAI_CONFIG}/NFSROOT
412
413 This file specifies the package list for creating the NFSROOT.
414
415   ${GRML_FAI_CONFIG}/config/
416
417 The main directory for configuration of FAI/grml-live. More details below.
418
419   ${GRML_FAI_CONFIG}/config/class/
420
421 This directory contains files which specify main configuration variables for the
422 FAI classes.
423
424   ${GRML_FAI_CONFIG}/config/debconf/
425
426 This directory provides the files for preseeding/configuration of debconf
427 through files.
428
429   ${GRML_FAI_CONFIG}/config/hooks/
430
431 This directory provides files for customising the build process through hooks.
432 Hooks are user defined programs or scripts, which are called during the
433 installation process.
434
435   ${GRML_FAI_CONFIG}/config/package_config/
436
437 Directory with lists of software packages to be installed or removed.  The
438 different classes describe what should find its way to your ISO.  When running
439 "grml-live -c GRMLBASE,GRML_SMALL,AMD64 ..." only the configuration of GRMLBASE,
440 GRML_SMALL and and AMD64 will be taken. If you use 'grml-live -c
441 GRMLBASE,GRML_SMALL,AMD64,FOOBAR ...' then the files of GRMLBASE, GRML_SMALL,
442 AMD64 **plus** the files from FOOBAR will be taken. So just create a new class to
443 adjust the package selection according to your needs.  Please notice that the
444 directory GRMLBASE contains a package list defining a minimum but still
445 reasonable package configuration.
446
447   ${GRML_FAI_CONFIG}/config/scripts/
448
449 Scripts for customising the ISO within the build process.
450
451   ${GRML_FAI_CONFIG}/live-initramfs/
452
453 This directory provides the files used for building the initramfs/initrd via
454 live-initramfs(8).
455
456 [[log-files]]
457 Available log files
458 -------------------
459
460 Starting with grml-live version 0.17.0 you should find log files in a directory
461 named 'grml_logs' in the output directory (next to grml_isos, grml_chroot,...).
462
463 grml-live versions before 0.17.0 used to log into /var/log/grml-live.log
464 and /var/log/fai/grml.
465
466 [[requirements]]
467 Requirements for the build system
468 ---------------------------------
469
470 * any Debian based system should be sufficient (if it doesn't work it's a bug,
471 please send us a bug report then). Check out <<deploy-on-debian,How do I deploy
472 grml-live on a plain Debian installation>> for details how to set up grml-live
473 on a plain, original Debian system.
474
475 * enough free disk space; at least 800MB are required for a minimal grml-live
476 run (\~400MB for the chroot [$CHROOT_OUTPUT], \~150MB for the build target
477 [$BUILD_OUTPUT] and \~150MB for the resulting ISO [$ISO_OUTPUT] plus some
478 temporary files), if you plan to use GRML_FULL you should have at least 4GB of
479 total free disk space
480
481 * fast network access for retrieving the Debian packages used for creating the
482 chroot (check out "local mirror" and "NFSROOT" to workaround this problem as far
483 as possible)
484
485 For further information see next section.
486
487 [[X8]]
488 [[current_state]]
489 Current state of grml-live with squashfs-tools and kernel
490 ---------------------------------------------------------
491
492 Use squashfs-tools >=4.2-1 (available from Grml repositories as well as from
493 Debian/testing and Debian/unstable) to build Grml (based) ISOs featuring kernel
494 version 2.6.38-grml[64] or newer.
495
496 [[faq]]
497 FAQ
498 ---
499
500 [[deploy-on-debian]]
501 How do I deploy grml-live on a plain Debian installation?
502 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
503
504 The easiest way to get a running grml-live setup is to just use Grml.
505 Of course using grml-live on a plain, original Debian installation is supported
506 as well. So there we go.
507
508 What we have: plain, original Debian squeeze (6.0).
509
510 What we want: build a Grml ISO based on Debian/wheezy for the amd64 architecture
511 using grml-live.
512
513 Instructions
514 ^^^^^^^^^^^^
515
516   # adjust sources.list:
517   cat >> /etc/apt/sources.list << EOF
518
519   # grml stable repository:
520     deb     http://deb.grml.org/ grml-stable  main
521   # deb-src http://deb.grml.org/ grml-stable  main
522
523   # grml testing/development repository:
524     deb     http://deb.grml.org/ grml-testing main
525   # deb-src http://deb.grml.org/ grml-testing main
526   EOF
527
528   # adjust apt-pinning (only prefer squashfs stuff from grml):
529   cat >> /etc/apt/preferences << EOF
530   Package: *
531   Pin: origin deb.grml.org
532   Pin-Priority: 1
533
534   Package: squashfs-tools
535   Pin: origin deb.grml.org
536   Pin-Priority: 996
537   EOF
538
539   # get keyring for apt:
540   apt-get update
541   apt-get --allow-unauthenticated install grml-debian-keyring
542
543   # optionally(!) install basefile so we don't have to build basic
544   # chroot from scratch, grab from http://daily.grml.org/
545   # mkdir -p /etc/grml/fai/config/basefiles/
546   # mv base.tgz /etc/grml/fai/config/basefiles/I386.tar.gz
547   # mv base64.tgz /etc/grml/fai/config/basefiles/AMD64.tar.gz
548
549   # install relevant tools
550   # please check out http://grml.org/grml-live/#current_state when encountering problems!
551   apt-get -o APT::Install-Recommends=false install grml-live squashfs-tools
552
553   # adjust grml-live configuration for our needs:
554   cat > /etc/grml/grml-live.local << EOF
555   ## want a faster build process and don't need smaller ISOs?
556   ## if so use zlib compression
557   # SQUASHFS_OPTIONS="-comp gzip -b 256k"
558   ## want to use a specific squashfs binary?
559   # SQUASHFS_BINARY='/usr/bin/mksquashfs'
560   ## install local files into the chroot
561   # CHROOT_INSTALL="/etc/grml/fai/chroot_install"
562   ## adjust if necessary (defaults to /grml/grml-live):
563   ## OUTPUT="/srv/grml-live"
564   FAI_DEBOOTSTRAP="wheezy http://cdn.debian.net/debian/"
565   # ARCH="amd64"
566   CLASSES="GRMLBASE,GRML_FULL,AMD64"
567   EOF
568
569   # just optional(!) - upgrade FAI to latest available version:
570   cat >> /etc/apt/sources.list << EOF
571   # fai:
572     deb http://fai-project.org/download squeeze koeln
573   EOF
574
575   # get gpg key of FAI repos and install current FAI version:
576   gpg -a --recv-keys AB9B66FD; gpg -a --export AB9B66FD | apt-key add -
577   apt-get update
578   apt-get install fai-client fai-server fai-doc
579
580 That's it. Now invoking 'grml-live -V' should build the ISO.  If everything
581 worked as expected the last line of the shell output should look like:
582
583   [*] Successfully finished execution of grml-live [running 687 seconds]
584
585 and the ISO can be found inside /grml-live/grml-live/grml_isos/ then.
586
587 [[grml_fai_config_variable]]
588 What is $GRML_FAI_CONFIG?
589 ~~~~~~~~~~~~~~~~~~~~~~~~~
590
591 The variable '$GRML_FAI_CONFIG' is pointing to the directory /etc/grml/fai by
592 default.  To provide you a maximum of flexibility you can set up your own
593 configuration directory (e.g. based on /etc/grml/fai) and use this directory
594 running grml-live with the '-D <config_dir>' option. Now '$GRML_FAI_CONFIG'
595 points to the specified directory instead of using /etc/grml/fai and all the
596 configuration files, scripts and hooks will be taken from your
597 '$GRML_FAI_CONFIG' directory.
598
599 [[how-to-debug]]
600 I've problems with the build process. How to start debugging?
601 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
602
603 Check out the logs inside the directory 'grml_logs' next to your grml_chroot,
604 grml_isos,... directories.
605
606 If you need help with grml-live or would like to see new features as part of
607 grml-live you can get commercial support via
608 link:http://grml-solutions.com/[Grml Solutions].
609
610 [[install-local-files]]
611 How do I install further files into the chroot/ISO?
612 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
613
614 Just point the configuration variable CHROOT_INSTALL to the directory which
615 provides the files you would like to install. Note that the files are installed
616 under '/' in the chroot - so you have to create the rootfs structure on your
617 own. Usage example:
618
619   echo "CHROOT_INSTALL=\$GRML_FAI_CONFIG/chroot_install" >> /etc/grml/grml-live.local
620   mkdir -p /etc/grml/fai/chroot_install/usr/src/
621   wget example.org/foo.tar.gz
622   mv foo.tar.gz /etc/grml/fai/chroot_install/usr/src/
623   grml-live ...
624
625 [[local-debian-mirror]]
626 Can I use my own (local) Debian mirror?
627 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
628
629 Yes. Set up an according sources.list configuration as class file in
630 ${GRML_FAI_CONFIG}/config/files/etc/apt/sources.list.d/ and adjust the variable
631 FAI_DEBOOTSTRAP (if not already using NFSROOT's base.tgz) inside
632 /etc/grml/grml-live.conf[.local]. If you're setting up your own class file don't
633 forget to include the class name in the class list (grml-live -c ...).
634
635 If you want to use a local (for example NFS mount) mirror additionally then
636 adjust MIRROR_DIRECTORY in /etc/grml/grml-live.conf[.local] as well.
637
638 If you want to use a HTTP Proxy (like apt-cacher-ng), set APT_PROXY. Example:
639
640   APT_PROXY="http://localhost:3142/"
641
642 [[add-additional-debian-packages]]
643 How do I add additional Debian package(s) to my CD/ISO?
644 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
645
646 Just create a new class (using the package_config directory):
647
648   # cat > /etc/grml/fai/config/package_config/MIKA << EOF
649   PACKAGES aptitude
650
651   vim
652   another_name_of_a_debian_package
653   and_another_one
654   EOF
655
656 and specify it when invoking grml-live then:
657
658   # grml-live -c GRMLBASE,GRML_SMALL,AMD64,MIKA
659
660 [[reset-grml-live-configuration]]
661 I fscked up my grml-live configuration. How do I reset it to the defaults?
662 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
663
664 Notice: this deletes all your grml-live configuration files. If that's really
665 what you are searching for just run:
666
667   rm -rf /etc/grml/fai /etc/grml/grml-live.conf
668   dpkg -i --force-confnew --force-confmiss /path/to/grml-live_..._all.deb
669
670 [[create-a-base-tgz]]
671 How do I create a base.tgz for use as NFSROOT?
672 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
673
674 First of all build the chroot system:
675
676   mkdir /tmp/nfsroot && cd /tmp/nfsroot
677   debootstrap squeeze /tmp/nfsroot/ http://cdn.debian.net/debian
678   tar zcf base.tgz ./
679
680 Then check out where your NFSROOT is located:
681
682   # grep '^NFSROOT' /etc/grml/fai/make-fai-nfsroot.conf
683   NFSROOT=/grml/fai/nfsroot
684
685 So as /grml/fai/nfsroot is your NFSROOT place the file under
686 /grml/fai/nfsroot/live/filesystem.dir/var/tmp/:
687
688   mv base.tgz /grml/fai/nfsroot/live/filesystem.dir/var/tmp/base.tgz
689
690 or even better use /etc/grml/fai/config/basefiles/$CLASSNAME.tar.gz instead.
691 Use I386 as $CLASSNAME for i386 builds and AMD64 for amd64 builds.
692
693 Now running "grml-live ..." will use this file as main system instead of
694 executing debootstrap. Check out the output for the following lines if using
695 NFSROOT:
696
697   [...]
698   Calling task_extrbase
699   Unpacking Debian base archive
700   Extracting /grml/fai/nfsroot/live/filesystem.dir/var/tmp/base.tgz
701   Calling task_mirror
702   [...]
703
704 or if using /etc/grml/fai/config/basefiles/$CLASSNAME.tar.gz for:
705
706   [...]
707   ftar: extracting /etc/grml/fai/config/basefiles///AMD64.tar.gz to
708   /grml-live/grml-live_20071029.22138/grml_chroot//
709   [...]
710
711 [TIP]
712 Existing base.tgz can be found at http://daily.grml.org/
713
714 [[apt-cacher]]
715 Set up apt-cacher-ng for use with grml-live
716 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
717
718 Make sure /etc/grml/grml-live.local provides according APT_PROXY and
719 FAI_DEBOOTSTRAP:
720
721   # cat /etc/grml/grml-live.local
722   [...]
723   APT_PROXY="http://localhost:3142/"
724   [...]
725   FAI_DEBOOTSTRAP="squeeze http://localhost:3142/cdn.debian.net/debian squeeze main contrib non-free"
726
727 Make sure apt-cacher-ng is running ('/etc/init.d/apt-cacher-ng restart').
728 That's it.  All downloaded files will be cached in /var/cache/apt-cacher-ng then.
729
730 [[revert_manifold]]
731 How do I revert the manifold feature from an ISO?
732 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
733
734 The so called manifold feature Grml ISOs use by default allows one to use the same
735 ISO for CD boot and USB boot. If you notice any problems when booting just
736 revert the manifold feature running:
737
738   % dd if=/dev/zero of=grml.iso bs=512 count=1 conv=notrunc
739
740 To switch from manifold to isohybrid mode (an alternative approach provided by
741 syslinux) then just execute:
742
743   % isohybrid grml.iso
744
745 [[basetgz]]
746 How do I create a base tar.gz (I386.tar.gz or AMD64.tar.gz)
747 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
748
749 Execute the following commands (requires root):
750
751   ARCH='amd64' # replace with i386 if necessary
752   SUITE='squeeze' # using the current stable release should always work
753   debootstrap --arch "$ARCH" --exclude=info,tasksel,tasksel-data "$SUITE" "$ARCH" http://debian.netcologne.de/debian
754   cd "$ARCH"
755   rm var/cache/apt/archives/*.deb
756   tar zcf ../"${ARCH}".tar.gz *
757
758 And finally place the generated tarball in /etc/grml/fai/config/basefiles/ (note
759 that it needs to be uppercase letters matching the class names, so: AMD64.tar.gz
760 for amd64 and I386.tar.gz for i386).
761
762 [[download]]
763 Download / install grml-live as a Debian package
764 ------------------------------------------------
765
766 Debian packages are available through the grml-repository at
767 link:http://deb.grml.org/pool/main/g/grml-live/[deb.grml.org].  If you want to
768 build a Debian package on your own (using for example a specific version or the
769 current development tree), just execute:
770
771   git clone git://git.grml.org/grml-live
772   cd grml-live
773   debuild -us -uc
774
775 [[source]]
776 Source
777 ------
778
779 The source of grml-live is available at
780 link:https://github.com/grml/grml-live/[https://github.com/grml/grml-live/]
781
782 [[bugs]]
783 Bugs
784 ----
785
786 Please report feedback, link:http://grml.org/bugs/[bugreports] and wishes
787 link:http://grml.org/contact/[to the Grml team]!
788
789 [[documentation]]
790 Documentation
791 -------------
792
793 The most recent grml-live documentation is available online at
794 http://grml.org/grml-live/ and for offline reading also available
795 in different formats:
796
797 * http://grml.org/grml-live/grml-live.epub
798 * http://grml.org/grml-live/grml-live.pdf
799
800 [[authors]]
801 Authors
802 -------
803 Michael Prokop <mika@grml.org>
804
805 /////////////////////////////////////
806 // vim:ai tw=80 ft=asciidoc expandtab
807 /////////////////////////////////////