Prerequisites
Before disabling services on boot, make sure you have:
- SSH access to your VPS
- Root or sudo privileges
Disable a Service
Connect to your VPS:
ssh hxroot@YOUR_SERVER_IP -p 22
sudo systemctl disable nginx
Verify Disabled
sudo systemctl is-enabled nginx
Output: disabled
Mask a Service (Prevent Manual Start Too)
sudo systemctl mask nginx
Unmask:
sudo systemctl unmask nginx
✅ Service will no longer start automatically on boot.