Andy
A-ndy.dev

A-ndy.dev

Rsync two servers without staying logged in

Andy's photo
Andy
·Aug 7, 2021·

1 min read

Install Screen

$ sudo apt-get install screen

and then run screen then run your command

Close the current screen:
Ctrl+a+d

List of Screens:

$ screen -ls

There is a screen on: 31248.pts-0.ubuntu (01/07/17 08:54:29) (Detached) 1 Socket in /var/run/screen/S-root.

Enter the screen:

$ screen -r 31248

Quit screen:
First enter the screen, and then:
Ctrl+a then type capital K and choose y

PS: Screen will automatically quit after the code you run is complete

 
Share this