Skip to content
BENIBIX Learn

Daemon

Infrastructure⌨️ Linux & the Command LineProcesses and Services

Also known as Linux Daemon, Background Service, Service (Linux)

A program that runs in the background all the time. It has no window.

Think of it like

Think of it like a night guard. Nobody sees him, but he is on duty all the time.

Example

Emma's server runs sshd, the SSH daemon. It waits all day for someone to log in.

Why it matters

Every server job, from web pages to logins, is a daemon. Fixing a server often means fixing one.

Definition

A daemon is a program that runs in the background with no window. It starts when the machine boots and keeps running. It waits for work, like a web request or a login. Many daemon names end in d, like sshd or crond. On most Linux systems, systemd starts and watches them.

Example code

console
$ ps -C cron
    PID TTY          TIME CMD
    845 ?        00:00:00 cron
The ? under TTY means the program has no terminal. It runs in the background.
Each box under systemd is a daemon. It runs in the background from boot.

Common mistake

Starting a server program in a terminal and closing it. The program dies with the window, so make it a daemon.

Key takeaways

  1. 1
    No window. Runs in the background.
  2. 2
    Starts at boot. And keeps running.
  3. 3
    Waits for work. Answers when asked.

Learn it properly