telinit
system administrationLinux/Unix
The telinit command is one of the most frequently used commands in Linux/Unix-like operating systems. telinit Change SysV init runlevel or systemd system state
Quick Reference
Command Name:
telinit
Category:
system administration
Platform:
Linux/Unix
Basic Usage:
telinit [options] [arguments]
Common Use Cases
Syntax
telinit [option] <runlevel>
Options
Option | Description |
---|---|
-t SEC, --timeout=SEC |
Set timeout for processes in seconds (SysVinit) |
-f, --force |
Force operation (SysVinit) |
-e, --evaluate |
Evaluate variables in /etc/inittab (SysVinit) |
-h, --help |
Display help and exit |
-V, --version |
Output version information and exit |
Common Runlevels:
Runlevel | Description |
---|---|
0 |
Halt or shutdown the system |
1, s, S |
Single-user mode (for maintenance/recovery) |
2 |
Multi-user mode without networking (varies by distribution) |
3 |
Multi-user mode with networking (command line) |
4 |
User-definable (not commonly used) |
5 |
Multi-user mode with networking and GUI |
6 |
Reboot the system |
q, Q |
Reload init configuration |
Examples
How to Use These Examples
The examples below show common ways to use the telinit
command. Try them in your terminal to see the results. You can copy any example by clicking on the code block.
# Basic Examples Basic
# Change to runlevel 3 (multi-user mode without GUI)
sudo telinit 3