22

Let's say I have a byobu session running with multiple tabs open. Then if I open a new terminal, and start byobu, it will take me into the same session. If I then switch byobu tabs in one terminal, the other terminal will also switch to the same tab.

Is it possible to have different tabs of the same byobu session open in different terminals?

2
  • 1
    No it doesn't. It behaves independently by default. What version of Ubuntu are you running? Are you on an older version still relying on screen rather than tmux? In Ubuntu 12.04 it works as you want it to. On Debian Squeeze and I guess 10.04 it still uses GNU Screen by default.
    – gertvdijk
    Jan 17, 2013 at 1:31
  • 1
    I am on 12.04, using tmux backend.
    – Alex
    Jan 17, 2013 at 2:14

2 Answers 2

29

Great question!

This isn't directly possible, due to the way Tmux works, from a client-server perspective.

Nonetheless, there is a viable workaround... Basically, you just need to have separate sessions. Byobu makes this easy and convenient through a couple of keybindings.

  • F2 creates new windows
  • Alt-Left and Alt-Right moves back and forth between them
  • Ctrl-F2 creates a vertical splits
  • Shift-F2 creates horizontal splits
  • Shift-Up, -Down, -Left, -Right, move around the splits
  • Ctrl-Shift-F2 creates a new session
  • Alt-Up and Alt-Down moves between sessions

The latter two should solve your problem!

Full disclosure: Author and maintainer of Byobu here

3
  • 1
    Thanks for your response (and thanks for Byobu! I use it every day). That sounds like a good workaround, those session keybindings will be handy.
    – Alex
    Mar 25, 2013 at 0:48
  • Thanks Dustin! I'm going to start using sessions more often than tabs now to scratch this itch! (btw: I love byobu! Thanks!)
    – Ch4ni
    Jun 2, 2016 at 13:58
  • I am sorry, Ctrl+Shift+F2 does not work on Mac with touchbar in iTerm2. Just Apple's logo on top of the screen appears. What should I do instead?
    – Abzac
    Aug 12, 2019 at 16:14
6

Since this is the top hit on Google, I'll add a solution that works for the version of tmux I'm using:

byobu list-sessions

Notice the number they are prefixed with. To connect with a different "view" of an existing session, you just do:

byobu new-session -t <number>

See the discussion here:

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .