Skip to main content

Boot Process

Ethereal's boot process is very intricate and involves some key components.

Kernel

The kernel of Ethereal is known as Hexahedron. It is a modular kernel with support for SMP, USB, networking, etc.

At boot, the startup screen is handled by Hexahedron (indicated by the cube in the upper right).

There are two stages of Hexahedron's boot process - the initial stage and the final stage.
The separation between the two stages is indicated by a change in font by the kernel

Hexahedron initial stage
Initial stage - ramdisk decompression
Hexahedron loading drivers
Final stage - driver loading and init running

In the first stage:

  • Basic features are initialized, such as ACPI, VFS, SMP, etc.
  • All builtin filesystem drivers (RamFS, KernelFS, etc.) are initialized (along with socket drivers)
  • The initial ramdisk is mounted
  • The initial ramdisk is decompressed.
  • The next font, kernel symbol map, etc. are loaded from the ramdisk

In the second stage:

  • The kernel processes and initializes all drivers
  • The process system is started, creating tasks
  • The init task is launched

Init

The init task is the first thing ran by the kernel. It is located at userspace/init/ in the source tree.

Init runs all shell scripts from /etc/init.d/, setting up the system for configuration

Finally, depending on parameters from /kernel/cmdline, it launches one of 3 tasks:

  • celestial, the main window server (if no parameters are specified)
  • termemu --fullscreen, a single-user terminal emulator (if the parameter --single-user is specified)
  • terminal, a legacy fallback terminal emulator (if the parameter --old-kernel-terminal is specified)

Final launch targets

Celestial

Celestial is the main window server of Ethereal, discussed in detail here

Ethereal screenshot
A screenshot of Celestial

termemu

termemu (or terminal emulator) is the main terminal emulator in Ethereal.
Some design inspiration for this was taken from ToaruOS - the terminal emulator can operate in both standalone and windowed modes.

Terminal emulator
A screenshot of termemu running in fullscreen mode

terminal

You should not use this interface. It has been deprecated for a very long time.

terminal was the original terminal emulator. More accurately, it just passes input from its subprocess to /device/kconsole.