Skip to content
Frankie Wittevrongel edited this page Nov 11, 2019 · 7 revisions

This page is a community contribution. Not official dietPi Documentation

Creating DietPi

Prior to be shipped, the script PREP_SYSTEM_FOR_DIETPI.sh is executed on every imagefile.

First boot

On the first boot of a fresh install of DietPi. The systemd services are launched in the following order :

  1. DietPi-FS_partition_resize (inflate root partition to 100% of the disk space available)
  2. DietPi-RAMlog
  3. DietPi-RAMdisk (mount /boot/DietPi and it's config files in RAM as a tmpfs)
    1. DietPi-PreBoot (Detect HW, Set overclock, Set CPU Governor, Call Apply_DietPi_FirstRun_Settings )
    2. Apply_DietPi_FirstRun_Settings: Generate Swapfile, Apply Timezone,Locale,Keyboard, and a lot more ...
  4. DietPi-Boot (start network interfaces, set swap, run survey, set install stage to 2, Start ntpd )
  5. DietPi-PostBoot( Print DietPi login banner )

Then, when you login rootfs/etc/bashrc.d/dietpi.bash is executed and load dietpi/dietpi-login

  • execute Run_DietPi_First_Run_Setup where all the questions are asked or dietpi.txt is used to automate.
  • dietpi-update
  • run dietpi-software installs

Second boot

TODO

On normal operation

The following services are launched in this order

  1. DietPi-RAMlog
  2. DietPi-RAMdisk (mount /boot/DietPi and it's config files in RAM as a tmpfs)
  3. DietPi-PreBoot (Detect HW, Set overclock, Set CPU Governor )
  4. DietPi-Boot (start network interfaces, start ntpd )
  5. DietPi-PostBoot(check for dietpi updates, start dietpi-services, Print DietPi login banner )

Then, when you login rootfs/etc/bashrc.d/dietpi.bash is executed and load dietpi/dietpi-login

  • show licence