#1 screen
Posted: Mon Jul 15, 2019 2:49 pm
The screen program is enormously useful. Use it outbound from a local *nux workstation to connect to other (usually headless) *nix workstations. *nix meaning Linux, raspberryPi, freeBSD etc. I'll assume you have /etc/hosts setup on the local machine. Remote is usually on your LAN but could be anywhere. Only thing needed on the remote is ssh server e.g. openssh-server
Code: Select all
screen -d -R remotemachine
# you are still on your local machine at this time
ssh -Y remotemachine
# you are now on remotemachine and can login, go sudo, anything you want. They -Y parameter means you can even run X programs and they will display on your local machine
type Ctrl-a followed by Ctrl-d
# this will detach the screen on the remote machine but LEAVES IT ALL RUNNING
# you are now back at local machine. To re-attach and pick up where you left off, just re-enter
screen -d -R remotemachine