Bootcharts

See profile of PC used.

Debian Stable - Benchmark

Fresh installs with KDE
Debian Etch Stable (kernel 2.6.18) (png) -- 32 seconds
Debian Sarge Stable (kernel 2.4.27) (png) -- 44 seconds
Debian Woody Stable (kernel 2.4.16) (png) -- 32 seconds

Testing known hotspots in Etch Stable
Etch with dash (png) -- 30 seconds -- /bin/sh points to /bin/dash
Etch with dash and hwclock in the background (png) -- 30 seconds -- also discover and gdm scripts removed
Etch with dash, hwclock and reordered scripts (png) -- 30 seconds -- reordering using insserv
Etch with dash, hwclock, reordering and parallel execution (png) -- 30 seconds -- parallel execution with CONCURRENCY=shell
Note: Refer to Deliverable from SoC2006(pdf) for details on the implementation of the individual hotspots.

Hotspots

Dash- Using dash instead of bash during boot was tested. Two methods were considered: by linking /bin/sh to /bin/dash(png)(tgz) and by changing the scripts to use dash(png)(tgz) . By linking we got a 4 second time reduction while with changing the scripts just 2 seconds. As a remark, linking to dash has been already implemented by Ubuntu. The bootchart of the system using dash requires 53 seconds (png)(tgz)

Script reordering The scripts were reordered using insserv (ver. 1.08.0-1) but there were some problems corrected: repeated scripts in /etc/rc2.d already started in /etc/rcS.d and stop-bootlogd, bootlogd and klogd. Reordering we got a 2 second improvement. Bootchart(tgz).
The boot of the reference system requires 53 seconds (png)(tgz). See init-scripts order used in the reference , with the insserv original reordering and with the modifications.
Reordering the init scripts with insserv was again tried with a 2 seconds slower boot time than with the original order. See bootchart. From a system starting in 53 seconds I got a 2 second improvement by using a previously tweaked insserv order. See bootchart. Furthermore, by removing the remaining repeated scripts (already started in /etc/rcS.d) I got a further 2 second time improvement, i.e., a 4 seconds improvement. See order used and bootchart.

Parallel execution The boot time difference between parallel execution using CONCURRENCY=startpar and CONCURRENCY=shell in /etc/default/rcS was tested. CONCURRENCY=startpar shows no improvement from a modified script order with insserv while there is a further 2 second improvement with CONCURRENCY=shell. Thus, the total time improvement with parallel execution and reordering was of 4 seconds. The reason for this behaviour may be due to a bug found in startpar. See the bootchart using shell(tgz) and using startpar(tgz).The boot of the reference system requires 53 seconds (png)(tgz).

Preloading The Preload program from Behdad Esfahbod (a result from SoC2005) was tried again and after two reboots it showed a 2 second time improvement. mapprefix and exeprefix were set to empty such that all files would be accepted. The results were compared with mapprefix being set to the directories used by some of the init scripts (strace -f initscript), adjusting the quantum time of preload (cycle parameter) and changing the position of the initscript to start just after hwclockfirst.sh. The results were the same: a 2 second time improvent. See the bootchart of preload accepting all files(tgz)and the bootchart with a selected set of directories from mapprefix(tgz). The boot of the reference system requires 53 seconds (png)(tgz).

Preload 0.2 and 0.4 were compared with no good results. See log file. For preload 0.2 the default gave 1 second more while the modified configuration showed no time difference. With preload 0.4 both default and the modified configuration remained with the original boot time. The original system took 51 seconds to boot.

Preload test on fresh install Just preload 0.4 was installed with the same configuration as in the preload comparison above. With the default configuration, after one reboot the time was 1 second slower. See bootchart. The modified configuration bootchart behaves similar.

readahead 0.20050517.0220. By using readahead shortly after the system starts to boot (near udev), the boot time is even increased by 2 seconds (e.g. S03readahead in /etc/rcS.d with the list of files to read ahead. On the other side, by using some of the files used by KDE during startup there is almost a one second improvement as may be seen in the bootchart.We use readahead in /etc/rcS.d position S42. The list used can be found in here and its bootchart may be compared with the reference.

Prelinking Tried prelinking with the aim of making the boot faster. Used the package of prelink from debian in unstable and there was no significant time improvement. Prelinking was added after readahead in a custom script run during the boot in /etc/rcS.d/S70prelink. What the script does is to prelink: kdeinit, Xorg, kwin, kdesktop, kicker, artsd, kaccess, ktip, klipper and korgac. The bootchart with prelink can be compared with the reference.

Less verbose The verbose option from the file /etc/default/rcS was changed to "VERBOSE=no" and "VERBOSE=quiet" but the effect was a one second longer boot time. See the bootchart with "VERBOSE=no" and bootchart with "VERBOSE=quiet".The boot of the reference system requires 52 seconds (png).

Remove extra scripts By removing useless init-scripts from the symbolic link pool (/etc/rc?.d) we got a further second improvement in the boot time. The two init-scripts removed were hotkey-setup and gdm. The former can be removed as I'm not using a laptop and the latter because I'm using KDE. The boot time was reduced from 46 to 45 seconds. See the new bootchart and compare with the reference bootchart.

Discover. There is an effect when the discover init-script is removed.It is funny to see that when I remove discover (/etc/rcS.d/S36discover) from the boot, a disk utilisation and cpu usage peak appear at the end of loading KDE.See the new bootchart and compare with the reference bootchart.

Fresh installs with KDE

Woody (kernel 2.4.16) bootchart (png)(tgz log)
Sarge (kernel 2.4.27) bootchart (png)(tgz log)
Etch (kernel 2.6.15) bootchart (png)(tgz log)
Sid (kernel 2.6.16) bootchart (png)(tgz log)


Fresh installs with KDE and modified bootchart to stop with ktip (instead of the default kdm,kdm_greet)(scripts installed)

Sid (kernel 2.6.16) (png)(tgz log)

Sid (kernel 2.6.16) with hwclock scripts modified (png)(tgz log)
2 Seconds less. Script: hwclockfirst.sh(new)(old)
Script: hwclock.sh(new)(old)
discover was removed after this test

Sid (kernel 2.6.16) with discover script removed. (png)(tgz log)
No time difference

Sid (kernel 2.6.16) with network script modified (sent ifup to background) (png)(tgz log)
No time difference.
Script: networking(new)(old)

Sid (kernel 2.6.16) linking /bin/sh to /bin/dash. (png)(tgz log)
3 seconds less
Procedure

Sid (kernel 2.6.16) using startpar and insserv (png)(tgz log)
2 seconds less
Procedure,Insserv automatically generated log,original init order and new init order.

Sid (kernel 2.6.16) using preload with default init order (S96 in /etc/rc2.d/)(png)(tgz log)
and with the modified init order (S47 in /etc/rcS.d/)(png)(tgz log)
0 seconds less in both cases
Procedure.

Sid (kernel 2.6.16) installed previously with bootchart stopping with ktip. (ssh installed) (scripts installed)

Base system (png)(tgz log)

Readahead 1.0.1-2 from ubuntu (png)(tgz log)0 seconds less

Readahead 0.20050517.0220-0 from ubuntu (png)(tgz log)1 seconds more