website view en/doc/scratchbook/base-system.html @ rev 1344

Resize balinor logo to 120px
author Christophe Lincoln <pankso@slitaz.org>
date Fri Jan 22 23:02:15 2021 +0100 (2021-01-22)
parents c2f9d5d0f314
children
line source
1 <!DOCTYPE html>
2 <html lang="en">
3 <head>
4 <meta charset="UTF-8">
5 <title>SliTaz Scratchbook - Base System</title>
6 <meta name="description" content="">
7 <meta name="expires" content="never">
8 <meta name="modified" content="2008-11-22 17:00:00">
9 <meta name="publisher" content="www.slitaz.org">
10 <meta name="author" content="Christophe Lincoln">
11 <link rel="shortcut icon" href="favicon.ico">
12 <link rel="stylesheet" href="book.css">
13 </head>
14 <body>
16 <!-- Header and quick navigation -->
17 <div id="header">
18 <div align="right" id="quicknav">
19 <span id="top"></span>
20 <a href="index.html">Table of contents</a> |
21 <a href="base-apps.html">Base apps</a>
22 </div>
23 <h1><font color="#3E1220">SliTaz Scratchbook</font></h1>
24 </div>
26 <!-- Content. -->
27 <div id="content">
28 <div class="content-right"></div>
31 <h2><font color="#df8f06">Base System</font></h2>
32 <p>
33 Build a SliTaz GNU/Linux distro running in RAM and using BusyBox.
34 </p>
35 <ul>
36 <li><a href="#about">About.</a></li>
37 <li><a href="#src">Wget src.</a></li>
38 <li><a href="#prepa">Unpack and prepare the Linux Kernel.</a></li>
39 <li><a href="#rootfs">Creation of the Root System</a>, the root
40 file System (rootfs).</li>
41 <li><a href="#config">Configure the box.</a></li>
42 <li><a href="#initramfs">Generate the initramfs</a>, compressed cpio archive.</li>
43 <li><a href="#rootcd">Construction of the root of the CD-ROM</a> (rootcd), and the
44 configuration files of Syslinux.</li>
45 <li><a href="#mkiso">Create an ISO image with genisoimage or mkisofs.</a></li>
46 <li><a href="#testiso">Burn or test the ISO with Qemu.</a></li>
47 </ul>
49 <h3 id="about">About</h3>
50 <p>
51 This document describes the construction of the SliTaz base system and why we use a
52 Linux Kernel, BusyBox and Syslinux to boot the system. SliTaz uses an initramfs
53 archive unpacked in RAM by the Kernel at boot. We will create a box to hold a
54 root of 3 to 4MB and use strip on the libraries and binaries to save space.
55 </p>
56 <p>
57 The scripts and configuration files are created with GNU nano, using the keystroke
58 &lt;ctrl+x&gt; to save and exit. But of course you are free to replace with your own text editor.
59 </p>
60 <p>
61 This document is based on a howto found in the archive of BusyBox, which is itself based on
62 a paper presented by Erik Anderson in the Embedded Systems Conference in 2001.
63 </p>
65 <h3 id="src">Wget src</h3>
66 <p>
67 Create a src directory for downloading and compiling:
68 </p>
69 <pre> # mkdir -p src
70 # cd src
71 </pre>
72 <ul>
73 <li>Linux Kernel 2.6.20
74 (<a href="http://www.kernel.org/">http://www.kernel.org/</a>).
75 <pre># wget ftp://ftp.kernel.org/pub/linux/kernel/v2.6/linux-2.6.20.tar.bz2</pre>
76 </li>
77 <li>Busybox 1.2.2
78 (<a href="http://www.busybox.net/">http://www.busybox.net/</a>).
79 <pre># wget http://www.busybox.net/downloads/busybox-1.2.2.tar.bz2</pre>
80 </li>
81 <li>Syslinux 3.35
82 (<a href="http://syslinux.zytor.com/">http://syslinux.zytor.com/</a>).
83 <pre># wget ftp://ftp.kernel.org/pub/linux/boot/syslinux/syslinux-3.35.tar.gz</pre>
84 </li>
85 <li>SliTaz tools 1.1. Download SliTaz tools, unpack, save the file in src/ and that's it:
86 <pre> # wget http://download.tuxfamily.org/slitaz/sources/tools/slitaz-tools-1.1.tar.gz
87 # tar xzf slitaz-tools-1.1.tar.gz</pre>
88 </li>
89 </ul>
91 <h3 id="prepa">Unpack and prepare the Linux Kernel</h3>
92 <p>
93 We will begin by compiling a Linux Kernel, which may take a little time.
94 </p>
95 <h4>Linux Kernel</h4>
96 <p>
97 Your Kernel must support the intramfs filesystem, otherwise the CD-ROM will not start. You can
98 also install the modules in a directory so as not to touch the host system. The configuration
99 of the Linux kernel sources is done by <code>make menuconfig</code> using ncurses or graphically
100 with <code>make gconfig</code> or <code>make xconfig</code> using GTK development packages and/or
101 Qt respectively. You can find in <a href="http://doc.slitaz.org/en:cookbook:slitaztools">SliTaz tools</a>,
102 Makefiles for the various 2.6.xx kernels.
103 </p>
104 <p>
105 A feature of the 2.6 Kernels is that if we make menuconfig, xconfig or config for the first time,
106 the setup menu is displayed based on the configuration of our current kernel.
107 </p>
108 <p>
109 The options depend on your needs, you can install module-init-tools to support compressed modules
110 or for a minimal install, you can select only the vital options.
111 </p>
112 <p>
113 We start by changing into the sources, <code>make mrproper</code> to put things in order, then we start a
114 configuration interface: gconfig, xconfig, menuconfig or oldconfig:
115 </p>
116 <pre> # tar xjf linux-2.6.20.tar.bz2
117 # cd linux-2.6.20
118 # make mrproper
119 # cp ../slitaz-tools-1.1/Makefiles/linux-2.6.20-slitaz.config .config
120 # make oldconfig
121 (# make menuconfig)
122 # make bzImage
123 # make modules
124 # make INSTALL_MOD_PATH=$PWD/_pkg modules_install
125 # cd ..
126 </pre>
127 <p>
128 If you want more info on compiling Kernels, there are many textbooks. Note that you can install the
129 Kernel and after rebooting, you can compile your own Kernel following the same instructions.
130 </p>
132 <h3 id="rootfs">Creation of the root system (rootfs)</h3>
133 <p>
134 The next step will create a file named ‘rootfs’ - Root File System, in the working directory SliTaz/:
135 </p>
136 <pre> # mkdir ../rootfs
137 </pre>
138 <h4>Install BusyBox</h4>
139 <p>
140 BusyBox (<a href="http://www.busybox.net/">www.busybox.net</a>) is a single executable offering
141 versions of the main tools necessary to use a Linux Kernel. It is (mainly) intended to be used
142 embedded and can do almost anything. As well as proposing (coreutils) shell commands and a daemons
143 system, it also provides a websever and client/server (DHCP, udhcpc).
144 </p>
145 <pre> # tar xjf busybox-1.2.2.tar.bz2
146 </pre>
147 <p>
148 Configure and compile, remembering the dumpkmap options, init, etc - you can find help in the Makefile in
149 SliTaz Busybox tools. Make install creates a _install directory in the current directory:
150 </p>
151 <pre> # cd busybox-1.2.2
152 # cp ../slitaz-tools-1.1/Makefiles/busybox-1.2.2.config .config
153 # make oldconfig
154 (# make menuconfig)
155 # make
156 # make install
157 # chmod 4755 _install/bin/busybox
158 </pre>
159 <p>
160 Copy files compiled by BusyBox in the directory _install to the root file system (rootfs):
161 </p>
162 <pre> # cp -a _install/* ../../rootfs
163 </pre>
164 <p>
165 The linuxrc link pointing to /bin/busybox, folders /bin, /lib and /sbin were added to the directory
166 /rootfs - you can check this. It may be that the link isn't there if you didn't select the option
167 initrd support in Busybox. We'll delete the linuxrc link and create a link for init that points to
168 /bin/busybox:
169 </p>
170 <pre> # cd ../../rootfs
171 # ls -CF
172 bin/ linuxrc@ sbin/ usr/
174 # rm linuxrc
175 # ln -s bin/busybox init
176 </pre>
177 <h4>ldd on BusyBox</h4>
178 <p>
179 The ldd command can show any libraries used by a program. Libraries used by Busybox may differ
180 depending on the host system. On Debian for example, copying the libraries in /lib/tls. The following
181 commands are given using ‘v’ for verbose mode. To eliminate the symbols of executable binaries
182 and shared libraries we can utilize strip. Note you may also use the mklibs or uClibc libraries.
183 </p>
184 <pre> # mkdir lib
185 </pre>
186 <p>
187 SliTaz or another:
188 </p>
189 <pre> # cp /lib/{libcrypt.so.1,libm.so.6,libc.so.6} lib
190 # cp /lib/ld-linux.so.2 lib
191 </pre>
192 <p>
193 Example on Debian Etch:
194 </p>
195 <pre> # cp /lib/tls/{libcrypt.so.1,libm.so.6,libc.so.6} lib
196 # cp /lib/ld-linux.so.2 lib
197 </pre>
198 <p>
199 Cleanup libraries with strip:
200 </p>
201 <pre> # strip -v lib/*
202 </pre>
203 <h4>Linux tree and configuration</h4>
204 <p>
205 Make some directories for a classic Linux branch SliTaz installation. /dev for devices, /etc, /home,
206 /usr, /proc, /root and co. To learn more about the hierarchy of a file system and its contents,
207 there is a File System Hierarchy Standard available in various formats at
208 <a href="http://www.pathname.com/fhs/">www.pathname.com/fhs/</a>.
209 </p>
210 <p>
211 You are free to create your own directory tree. In traditional Unix systems, /usr usually contains
212 files from the distribution, /dev contains devices (devices), /etc contains configuration files,
213 /lib libraries, /home for home users and /var for variable data. Note that we do not create
214 /lib, /bin or /sbin - these are created when BusyBox is installed.
215 </p>
216 <pre> # mkdir -p dev etc root home proc media mnt sys tmp var
217 # mkdir -p usr/{lib,local,games,share} \
218 var/{cache,lib,lock,log,games,run,spool} \
219 media/{cdrom,flash,usbdisk}
220 </pre>
221 <p>
222 Change permissions on the /tmp directory:
223 </p>
224 <pre> # chmod 1777 tmp
225 </pre>
226 <p>
227 Setting up glibc - note /etc/ld.so.conf and /etc/rpc are not essential for a micro system:
228 </p>
229 <pre> # touch etc/ld.so.conf
230 # cp /etc/rpc etc
231 </pre>
232 <h4>Create the devices in /dev</h4>
233 <p>
234 This can be done with the script ‘mkdevs.sh’ found in BusyBox, or with our script ‘mktazdevs.sh’ in
235 SliTaz tools. If you want more details, read the scripts. If you used the BusyBox version, we must
236 still create the pts directory:
237 </p>
238 <pre> # cp ../src/slitaz-tools-1.1/utils/mktazdevs.sh bin
239 # ./bin/mktazdevs.sh dev
240 or:
241 # cp ../src/busybox-1.2.2/examples/bootfloppy/mkdevs.sh bin
242 # ./bin/mkdevs.sh dev
243 # mkdir -p dev/{pts,input,shm,net,usb}
244 </pre>
245 <p>
246 Note that we start mdev-s with the rcS script to create devices dynamically at boot.
247 </p>
248 <h4>Support for the resolution of hostnames (DNS)</h4>
249 <p>
250 Copy the libraries libnss_* of the host system into our SliTaz system. These libraries are used for
251 name resolution and are cleaned with strip:
252 </p>
253 <pre> # cp /lib/{libnss_dns.so.2,libnss_files.so.2} lib
254 # cp /lib/libresolv.so.2 lib
255 # strip -v lib/*.so*
256 </pre>
258 <h3 id="config">Configuration of your box</h3>
259 <p>
260 Create the necessary files in /etc. For more info, just look at the contents of the files.
261 We start by creating some files relevant to the core operating system.
262 </p>
263 <h4>Network</h4>
264 <p>
265 Create basic files used to configure the network:
266 </p>
267 <pre> # echo "127.0.0.1 localhost" &gt; etc/hosts
268 # echo "localnet 127.0.0.1" &gt; etc/networks
269 # echo "slitaz" &gt; etc/hostname
270 # echo "order hosts,bind" &gt; etc/host.conf
271 # echo "multi on" &gt;&gt; etc/host.conf
272 </pre>
273 <h4>/etc/nsswitch.conf</h4>
274 <p>
275 Configuration files used to resolve names:
276 </p>
277 <pre> # nano etc/nsswitch.conf
278 </pre>
279 <pre class="script"># /etc/nsswitch.conf: GNU Name Service Switch config.
280 #
282 passwd: files
283 group: files
284 shadow: files
286 hosts: files dns
287 networks: files
289 </pre>
290 <h4>/etc/securetty</h4>
291 <p>
292 /etc/securetty lists terminals that can connect to root:
293 </p>
294 <pre> # nano etc/securetty
295 </pre>
296 <pre class="script"># /etc/securetty: List of terminals on which root is allowed to login.
297 #
298 console
300 # For people with serial port consoles
301 ttyS0
303 # Standard consoles
304 tty1
305 tty2
306 tty3
307 tty4
308 tty5
309 tty6
310 tty7
312 </pre>
313 <h4>/etc/shells</h4>
314 <p>
315 /etc/shells, a shells list of valid connections. This file is used by the SSH server (Dropbear):
316 </p>
317 <pre> # nano etc/shells
318 </pre>
319 <pre class="script"># /etc/shells: valid login shells.
320 /bin/sh
321 /bin/ash
322 /bin/hush
324 </pre>
325 <h4>/etc/issue and /etc/motd</h4>
326 <p>
327 /etc/issue is displayed at the end of boot and the message of the day is displayed after logging in:
328 </p>
329 <pre> # echo "SliTaz GNU/Linux 1.0 Kernel \r \l" &gt; etc/issue
330 # echo "" &gt;&gt; etc/issue
331 # nano etc/motd
332 </pre>
333 <pre class="script">
334 (°- { Get documentation in: /usr/share/doc.
335 //\ Use: 'less' or 'more' to read files, 'su' to be root. }
336 v_/_
338 SliTaz is distributed in the hope that it will be useful, but
339 with ABSOLUTELY NO WARRANTY.
341 </pre>
342 <h4>/etc/busybox.conf</h4>
343 <p>
344 The configuration file for BusyBox, it can set duties on BusyBox applications. For more information, you can read the
345 <a href="http://doc.slitaz.org/en:handbook:security">security</a> page in the Handbook. BusyBox.conf file:
347 </p>
348 <pre> # nano etc/busybox.conf
349 </pre>
350 <pre class="script"># /etc/busybox.conf: SliTaz GNU/linux Busybox configuration.
351 #
353 [SUID]
354 # Allow command to be run by anyone.
355 su = ssx root.root
356 passwd = ssx root.root
357 loadkmap = ssx root.root
358 mount = ssx root.root
359 reboot = ssx root.root
360 halt = ssx root.root
362 </pre>
363 <p>
364 For added security, change the permissions on the file:
365 </p>
366 <pre> # chmod 600 etc/busybox.conf
367 </pre>
368 <h4>/etc/inittab</h4>
369 <p>
370 Minimal configuration file for init. It helps to have a root console without having to
371 go through the login and a console on tty2.
372 </p>
373 <pre> # nano etc/inittab
374 </pre>
375 <pre class="script"># /etc/inittab: init configuration for SliTaz GNU/Linux.
377 ::sysinit:/etc/init.d/rcS
378 ::respawn:-/bin/sh
379 tty2::askfirst:-/bin/sh
380 ::ctrlaltdel:/bin/umount -a -r
381 ::ctrlaltdel:/sbin/reboot
383 </pre>
384 <p>
385 You will also find a wider example of an inittab file in the archive of BusyBox.
386 </p>
387 <h4>/etc/profile</h4>
388 <p>
389 This file is read at each login and affects all users. We must use the ./profile
390 config file for each individual user:
391 </p>
392 <pre> # nano etc/profile
393 </pre>
394 <pre class="script"># /etc/profile: system-wide .profile file for the Bourne shells
396 PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games"
397 LD_LIBRARY_PATH="/usr/lib:/lib"
399 if [ "`id -u`" -eq 0 ]; then
400 PS1='\e[1m\u@\h:\w\#\e[m '
401 else
402 PS1='\e[1m\u@\h:\w\$\e[m '
403 fi
405 DISPLAY=:0.0
407 export PATH LD_LIBRARY_PATH PS1 DISPLAY ignoreeof
408 umask 022
410 </pre>
411 <h4>Users, groups and passwords</h4>
412 <p>
413 Create configuration files of users, groups and passwords in /etc/ {passwd, shadow, group, gshadow}, and adjust permissions:
414 </p>
415 <pre> # echo "root:x:0:0:root:/root:/bin/sh" &gt; etc/passwd
416 # echo "root::13525:0:99999:7:::" &gt; etc/shadow
417 # echo "root:x:0:" &gt; etc/group
418 # echo "root:*::" &gt; etc/gshadow
419 # chmod 640 etc/shadow
420 # chmod 640 etc/gshadow
421 </pre>
422 <p>
423 You can add other users, like hacker is used by the LiveCD mode. You can also configure a password for the root user
424 with the <code>passwd</code> command. To add an existing user to an existing group, you must edit /etc/group and /etc/gshadow because
425 the applet <code>adduser</code> provided by BusyBox doesn't offer all of the options provided by the original program.
426 </p>
427 <h4>/etc/fstab or /etc/mtab</h4>
428 <p>
429 List filesystems to be mounted:
430 </p>
431 <pre> # nano etc/fstab
432 </pre>
433 <pre class="script"># /etc/fstab: information about static file system.
434 #
435 proc /proc proc defaults 0 0
436 sysfs /sys sysfs defaults 0 0
437 devpts /dev/pts devpts defaults 0 0
438 tmpfs /dev/shm tmpfs defaults 0 0
440 </pre>
441 <p>
442 /etc/mtab is used by other mkfs*, for listing the mounted partitions. It needs /proc because there is a link on /proc/mounts:
443 </p>
444 <pre> # chroot . /bin/ash
445 /# ln -s /proc/mounts /etc/mtab
446 </pre>
447 <h4>Keyboard</h4>
448 <p>
449 You can create a kmap file specific to your keyboard with the dumpkmap command provided by BusyBox.
450 You can find some kmap files in SliTaz tools. To create a fr_CH kmap file:
451 </p>
452 <pre> /# mkdir /usr/share/kmap
453 /# /bin/busybox dumpkmap &gt; /usr/share/kmap/fr_CH.kmap
454 /# exit
455 </pre>
456 <p>
457 Once this is done, you can automatically load your keyboard with loadkmap in a /etc/init.d/rcS script:
458 </p>
459 <h4>/usr/share/doc</h4>
460 <p>
461 You can also add various documents, such as a SliTaz user manual, which you can download as a tar.gz from the website:
462 </p>
463 <pre> # mkdir -p usr/share/doc
464 </pre>
465 <h4>Installing the udhcpc script</h4>
466 <p>
467 Udhcpc DHCP client supplied by Busybox is fast and stable, but is developed independently.
468 Web site: <a href="http://udhcp.busybox.net/">http://udhcp.busybox.net/</a>. You can use the default
469 script found in the archive of BusyBox. This script goes into /usr/share/udhcpc/default.script,
470 but this can be changed via the command line. On SliTaz, the client is started at boot by the script
471 /etc/init.d/network.sh via the configuration file /etc/network.conf:
472 </p>
473 <pre> # mkdir usr/share/udhcpc
474 # cp ../src/busybox-1.2.2/examples/udhcp/simple.script \
475 usr/share/udhcpc/default.script
476 # chmod +x usr/share/udhcpc/default.script
477 </pre>
478 <h4>/etc/init.d/rcS</h4>
479 <p>
480 To finish off this draft, you must create the init script /etc/init.d/rcS to mount the filesystems
481 and run some commands. For more information, you can look at the
482 <a href="http://doc.slitaz.org/en:cookbook:bootscripts">boot scripts</a> page.
483 You can change the value of the variable KMAP= for the keyboard:
484 </p>
485 <pre> # mkdir etc/init.d
486 # nano etc/init.d/rcS
487 </pre>
488 <pre class="script">#! /bin/sh
489 # /etc/init.d/rcS: rcS initial script.
490 #
492 KMAP=fr_CH
494 echo "Processing /etc/init.d/rcS... "
496 /bin/mount proc
497 /bin/mount -a
498 /bin/hostname -F /etc/hostname
499 /sbin/ifconfig lo 127.0.0.1 up
500 /sbin/loadkmap &lt; /usr/share/kmap/$KMAP.kmap
503 </pre>
504 <pre> # chmod +x etc/init.d/rcS
505 </pre>
506 <h4>Note</h4>
507 <p>
508 Note that you can still install the Tazpkg package manager (10 kb) that we created,
509 you will find information to install in the source tarball. You can also install various
510 files from SliTaz tools, such as the licence.
511 </p>
513 <h3 id="initramfs">Build an initramfs cpio archive</h3>
514 <p>
515 The initramfs is a <code>cpio</code> archive generated from the root of the system,
516 it is decompressed in RAM by the Linux Kernel at boot to create the filesystem (also in RAM).
517 To generate an initramfs archive, using the root directory of system files (rootfs), we
518 facilitate a search with <code>find</code> and add some pipes <code>|</code>.
519 Then we create a cpio archive using <code>gzip</code> which we put in the working directory.
520 </p>
521 <p>
522 The SliTaz initramfs <strong>rootfs.gz</strong> is the root system, but with a <code>.gz</code>
523 extension. If you want to change the name, you need to edit the configuration file for
524 isolinux: isolinux.cfg or the menu.lst for GRUB.
525 </p>
526 <p>
527 Generation of the initramfs:
528 </p>
529 <pre> # find . -print | cpio -o -H newc | gzip -9 &gt; ../rootfs.gz
530 </pre>
531 <p>
532 You should now have a file rootfs.gz about 1 to 2MB in the working directory SliTaz/.
533 </p>
534 <p>
535 For a new image, when making changes in rootfs, simply copy the new rootfs.gz archive to rootcd/boot
536 and create a new image with <code>genisoimage</code> or <code>mkisofs</code>. For this you can also
537 use <strong>mktaziso</strong> within SliTaz tools. This script will check if the directories are present,
538 create a new compressed cpio archive and generate a new bootable ISO image.
539 </p>
541 <h3 id="rootcd">Make rootcd files</h3>
542 <p>
543 The following steps will help you create the root of the bootable CD-ROM. We begin by creating the rootcd,
544 boot and isolinux directories for the CD-ROM files:
545 </p>
546 <pre> # cd ..
547 # mkdir -p rootcd/boot/isolinux
548 </pre>
549 <p>
550 Optionally, you can create some other directories in which to place various data, such as HTML documents or packages.
551 </p>
553 <h4 id="linux">Copy the Kernel</h4>
554 <p>
555 Just copy the Kernel previously compiled to rootcd/boot:
556 </p>
557 <pre> # cp src/linux-2.6.20/arch/i386/boot/bzImage rootcd/boot
558 </pre>
559 <h4>Copy the initramfs into rootcd/boot</h4>
560 <p>
561 Copy the rootfs.gz to rootcd/boot. We must not forget to generate a new initramfs archive for any changes
562 made to the rootfs (root file system):
563 </p>
564 <pre> # cp rootfs.gz rootcd/boot
565 </pre>
566 <h4>Install the isolinux bootloader</h4>
567 <p>
568 The bootloader isolinux - simply copy the isolinux.bin from the source archive of Syslinux:
569 </p>
570 <pre> # cd src
571 # tar xzf syslinux-3.35.tar.gz
572 # cp syslinux-3.35/isolinux.bin ../rootcd/boot/isolinux
573 # cd ..
574 </pre>
575 <h4>isolinux.cfg - Configure isolinux</h4>
576 <p>
577 Here is an example of an isolinux.cfg file that should work well. You can change it if you wish:
578 </p>
579 <pre> # nano rootcd/boot/isolinux/isolinux.cfg
580 </pre>
581 <pre class="script">display display.txt
582 default slitaz
583 label slitaz
584 kernel /boot/bzImage
585 append initrd=/boot/rootfs.gz rw root=/dev/null vga=788
586 implicit 0
587 prompt 1
588 timeout 80
590 </pre>
591 <p>
592 Here are some changes that you might like to make in isolinux.cfg:
593 </p>
594 <ul>
595 <li>The timeout value is the number of seconds to wait before booting
596 You can make it 0 or delete the line to start instantly, or choose to wait as long as 10s.</li>
597 <li>prompt can be set to 0 to disable the ‘boot:’ prompt.</li>
598 <li>You can add more lines to view the contents of several text files when the user presses F1, F2, F3, etc.</li>
599 </ul>
600 <h4>display.txt</h4>
601 <p>
602 A small welcome note, powered by isolinux, you can modify this file if you wish:
603 </p>
604 <pre> # nano rootcd/boot/isolinux/display.txt
605 </pre>
606 <pre class="script">
607 /* _\|/_
608 (o o)
609 +----oOO-{_}-OOo---------------------------------------------------+
610 ____ _ _ _____
611 / ___|| (_)_ _|_ _ ____
612 \___ \| | | | |/ _` |_ /
613 ___) | | | | | (_| |/ /
614 |____/|_|_| |_|\__,_/___|
616 SliTaz GNU/Linux - Temporary Autonomous Zone
618 &lt;ENTER&gt; to boot.
620 */
621 </pre>
623 <h3 id="mkiso">Create an ISO image with genisoimage or mkisofs</h3>
624 <pre> # genisoimage -R -o slitaz-cooking.iso -b boot/isolinux/isolinux.bin \
625 -c boot/isolinux/boot.cat -no-emul-boot -boot-load-size 4 \
626 -V "SliTaz" -input-charset iso8859-1 -boot-info-table rootcd
627 </pre>
628 <p>
629 For each change in the root of the box, you must create a new ISO image.
630 </p>
631 <p>
632 You can create a small script that will generate a new compressed cpio archive and a new image,
633 or use mktaziso within SliTaz tools. Note that you can also use GRUB to boot the box.
634 </p>
636 <h3 id="testiso">Burn or test ISO image with Qemu</h3>
637 <p>
638 You can burn the ISO image with Graveman, k3b or wodim and boot it. Simple burning command using wodim (also valid for cdrecord), with a 2.6.XX. Kernel:
639 </p>
640 <pre># wodim -v -speed=24 -data slitaz-cooking.iso
641 </pre>
642 <h4>Qemu</h4>
643 <p>
644 Note that you can test the ISO image with the software emulator Qemu (On Debian # aptitude install qemu).
645 To emulate the newly created ISO image, simply type:
646 </p>
647 <pre># qemu -cdrom slitaz-cooking.iso
648 </pre>
649 <h4>Following chapter</h4>
650 <p>
651 The next chapter <a href="base-apps.html">Base applications</a> provides all the instructions to install
652 and configure the basic applications and libraries.
653 </p>
655 <!-- End of content -->
656 </div>
658 <!-- Footer. -->
659 <div id="footer">
660 <div class="footer-right"></div>
661 <a href="#top">Top of the page</a> |
662 <a href="index.html">Table of contents</a>
663 </div>
665 <div id="copy">
666 Copyright &copy; <span class="year"></span> <a href="http://www.slitaz.org/en/">SliTaz</a> -
667 <a href="http://www.gnu.org/licenses/gpl.html">GNU General Public License</a>;<br />
668 Documentation is under
669 <a href="http://www.gnu.org/copyleft/fdl.html">GNU Free Documentation License</a>
670 and code is <a href="http://validator.w3.org/">valid xHTML 1.0</a>.
671 </div>
673 </body>
674 </html>