Chapter 7. Creating system boot scripts

Table of Contents
Introduction
How does the booting process with these scripts work?
Creating directories
Creating the rc script
Creating the rcS script
Creating the functions script
Creating the checkfs script
Creating the halt script
Creating the loadkeys script
Creating the mountfs script
Creating the reboot script
Creating the sendsignals script
Creating the setclock script
Creating the sysklogd script
Creating the template script
Setting up symlinks and permissions

Introduction

This chapter will create the necessary scripts that are run at boot time. These scripts perform tasks such as remounting the root file system mounted read-only by the kernel into read-write mode, activating the swap partition(s), running a check on the root file system to make sure it's intact and starting the daemons that the system uses.

We will be using SysV style init scripts. We have chosen this style because it is widely used and we feel confortable with it. If you want to try something else, someone has written an LFS-Hint on BSD style init scripts.