screen keeps processes alive when you close SSH. Handy for bots, builds or game consoles before you write a systemd unit.
Steps
Install screen:
sudo apt updatesudo apt install -y screenStart a named session:
screen -S myappInside screen, start your process. Detach without killing it: Ctrl+A then D.
List and reattach:
screen -lsscreen -r myapp
Tips
- With several sessions use
screen -r PIDor the exact name. - For long-lived services, move to a systemd unit when you can.
ext step
Always-on servers: Deploy your Cloud VPS.