LinuxCommandLibrary

systemctl-enable

TLDR

Enable a service to run on boot

$ systemctl enable [unit]
copy
Enable a service to run on boot and start it now
$ systemctl enable [unit] --now
copy
Enable a user unit to run on login
$ systemctl enable [unit] --user
copy

SYNOPSIS

systemctl [OPTIONS...] enable UNIT...

DESCRIPTION

systemctl enable creates symbolic links in systemd directories to enable units to start automatically at boot (for system units) or at login (for user units). This does not start the unit immediately; use --now to both enable and start.
The symlinks are created based on the [Install] section of the unit file, typically linking into target.wants directories. Enabling is idempotent; enabling an already-enabled unit has no effect.

PARAMETERS

--now

Also start the unit after enabling
--user
Enable user service manager units instead of system units
--no-reload
Do not reload systemd configuration after enabling
--force
Enable units even if they are masked
--runtime
Enable temporarily until next reboot only

CAVEATS

Requires root privileges for system units. Enabling does not start the unit; combine with --now or use systemctl start separately. Masked units cannot be enabled without --force.

SEE ALSO

> TERMINAL_GEAR

Curated for the Linux community

Raspberry Pi 5 8GB

Raspberry Pi 5 8GB

$134.50
nuphy Air75 V2 Portable 75% Mechanical Keyboard,Wireless Keyboard

nuphy Air75 V2 Portable 75% Mechanical Keyboard,Wireless Keyboard

$129.95
GMKtec Gaming PC, K11 AMD Ryzen 9 8945HS, 32GB DDR5 RAM 1TB Mini PC Desktop Computer, Oculink, Dual NIC 2.5GbE LAN, HDMI/DisplayPort/USB4*2

GMKtec Gaming PC, K11 AMD Ryzen 9 8945HS, 32GB DDR5 RAM 1TB Mini PC Desktop Computer, Oculink, Dual NIC 2.5GbE LAN, HDMI/DisplayPort/USB4*2

$739.99
Copied to clipboard

> TERMINAL_GEAR

Curated for the Linux community

Lenovo Gen 13 ThinkPad X1 Carbon Touchscreen Laptop with Intel Ultra 7 265U Processor, 14" WUXGA 100% sRGB, 32GB DDR5 RAM, 1TB NVMe Performance SSD, FHD+ IR+ RGB Camera, and Windows 11 Pro

Lenovo Gen 13 ThinkPad X1 Carbon Touchscreen Laptop with Intel Ultra 7 265U Processor, 14" WUXGA 100% sRGB, 32GB DDR5 RAM, 1TB NVMe Performance SSD, FHD+ IR+ RGB Camera, and Windows 11 Pro

$1,589.00
New Raspberry Pi 3 Model B+ Board Raspberry PI 3B+

New Raspberry Pi 3 Model B+ Board Raspberry PI 3B+

$54.00
BOSGAME Mini PC N95, Intel 12th Mini Computers| 16GB DDR4 RAM| 512GB M.2 2280 SSD| 4K 60HZ Triple Displays by Dual HDMI+Type-C, 6W TDP Quiet Mini PC, WIFI5, BT 5.0 Office

BOSGAME Mini PC N95, Intel 12th Mini Computers| 16GB DDR4 RAM| 512GB M.2 2280 SSD| 4K 60HZ Triple Displays by Dual HDMI+Type-C, 6W TDP Quiet Mini PC, WIFI5, BT 5.0 Office

$239.99