Linux: Using screen and screen under su
Linux: Using screen and screen under su If you need to run something and let is run after you close the session, you can use screen. Install the screen package and just run screen. You can de-attach from the screen shell, using the "CTRL+A" keyboard shortcut. To list the screen sessions, you can run "screen -ls" command: debian:~# screen -ls There are screens on: 14573.pts-1.debian (03/27/2019 06:59:01 PM) (Attached) 14546.pts-1.debian (03/27/2019 06:58:55 PM) (Detached) To re-attach to a screen session you can run "screen -r {session name}": debian:~# screen -r 14573.pts-1.debian In order to attach to the same screen session from different shells, you need to use the "-xr" arguments, enabling multi-display mode. debian:~# screen -xr 14573.pts-1.debian When you need to run it under su, you'll face the issue below: debian:~# sudo su - silviu silviu@debian:~$ screen Cannot o