I usually use gnu screen like this:
1. start a screen session for all my tasks
2. When I login to a machine, I connect to a screen session (screen -x) made by my colleague (so this makes it an “inner screen”)
Problem is, when I need to detach from the “inner screen” via “:detach” command or ctrl+a+d, I get detached from my main screen (in #1).
Is it possible to detach from “inner screen”?
Thanks
Use ctrl+a, a to send ctrl+a to the inner screen. That is, to detach the inner screen press ctrl+a, a, d. Alternatively press ctrl+a, a, and write
:detach.I also work with the same screen setup as you and found it more convenient to change the ctrl+a shortcut to ctrl+l (lower case “L”) on my local machine. That way you can access the inner screen directly with ctrl+a instead of the tedious ctrl+a, a. To do that add this to your local
~/.screenrc: