Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

For quite some time I've been using screen to detach and let them run in the background. Then I discovered byobu to have mutliple tabbed shells running. Now I have a problem that I'm no longer able to detach from a screen inside my byobu shells, since Ctrl-a-d detaches the byobu session and not the screen session inside it.

I read a few times that Ctrl-a is supposed to work, which would make this Ctrl-a-a-d, but this simply switches tabs (Ctrl-a-a) and then quits the shell (Ctrl-d).

Is there a simple solution to be able to detach again?

share|improve this question

Try letting go of ctrl after the first a, so the sequence is ctrl-a, a, d. Man screen:

   C-a C-a     (other)       Toggle  to  the  window  displayed previously.  Note that this
                             binding defaults to the command character typed twice,  unless
                             overridden.   For instance, if you use the option "-e]x", this
                             command becomes "]]".

   C-a a       (meta)        Send the command character (C-a) to window.  See  escape  com‐

Or if you're using tmux instead of screen for Byobu, try just ctrl-a d. Byobu's default prefix key is ctrl-b, so if you're using that default, doubling up the ctrl-a keystroke would not be necessary.

share|improve this answer
Sadly this did not work, I have my byobu backend configured to be tmux, I'll check out the tmux documentation to see whether that works. – cdecker Jun 17 '13 at 14:50
Ah, I did not know that was possible. In that case, the extra ctrl-a may not be necessary; I have updated my answer to cover tmux. – Paul Jun 17 '13 at 17:15
Hm, that detached byobu as well. But as far as I can see there is no similar detach binding in tmux. I'll quickly switch to the screen backend. – cdecker Jun 18 '13 at 8:39
This works for detaching screen inside of a tmux session when you have bound the tmux to C-a. I think these comments are googlable :) – pferdefleisch Aug 28 '14 at 10:48

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.