keep processes running after ssh session disconnects code example
Example: bash how to leave a process running on remote server
# Short answer:
# Learn how to use screen
# Basic syntax:
# After logging in to remote server run:
screen # This starts a new screen.
# After starting a long process, e.g., a download, detach with:
CTRL+a d # To detach from screen, press CTRL+a, release, then press d
# To view active screens:
screen -ls
# To resume active screen:
screen -r # If there is only one active screen
screen -r screen_number # If there are multiple active screens