Targets

Last edited

Targets

Single-user mode vs Multi-user mode

multi-user mode just starts more systemd services that lets other users login like:

  • sshd - allow ssh remotely
  • getty - daemon that puts login prompt
  • NetworkManager - networking

single-user mode systemd doesn’t start these services

  • just a root shell

these are stored as .targets

Commands

Bash
# symlinks to all the units that need to be run to reach the target
ls /usr/lib/systemd/system/multi-user.target.wants/
# single user doesn't have a directry of services, its contained in the service file
cat /usr/lib/systemd/system/rescue.target 

# the actual target files
cat /usr/lib/systemd/system/multi-user.target 
cat /usr/lib/systemd/system/rescue.target