18

I installed tmux using sudo apt-get install tmux on my Ubuntu 16.04 system.

I tried running tmux by simply typing tmux in terminal.That went on fine. But none of the functions like "creating new window Ctrl-b + c" , "list windows Ctrl-b + w ", "split window into two Ctrl-b + % " seems to work. I get no response

What should I do?

7 Answers 7

38

Release the C-b before press the other commands

2
  • 1
    I now suddenly have this problem. I suspect something is intercepting Ctrl-B. I've been a long time user of tmux, I know to release the C-b before I press the next key. I just got many updates. FWIW I'm using KDE Plasma.
    – Johan
    Apr 15, 2020 at 12:51
  • Yeah now my CTRL+B is writing ^B in the window... wonder what went wrong Mar 3, 2023 at 12:43
4

If the tmux shortcuts don't work you need to start by typing the commands mannually.

tmux new-window, tmux split-window and see if those work.

If they do, you need to check on the mannual pages man tmux and see if tmux new-window and all other command's shortcut you are trying to use are bound as you think they are in section KEY BINDINGS.

In the KEY BINDINGS section look for the prefix key and other shortcuts which you are trying to accomplish if they are defined with the keys you are pressing.

Not really sure about Ubuntu repositories but it's better if you install the latest version of tmux from their github repo yes means building from source.

After a quick search i found out that version: 2.2 of tmux that ships with ubuntu 16.04 is buggy so i think you should update from source to latest as they suggest.

Your tmux -V (for version) matters sometimes so updating to the latest can prevent most problems.

2

I have been facing this problem and it was really pain, eventually I found out that I have to press ctrl+b and release it and then press the other key.

for example, to create a new terminal hold ctrl+b and release it then press shift+5 (%)

Do this for other fuctions.

1

One possible cause for this could be the server at an incompatibly higher version than the client. And therefore, if you manage to go out of the tmux windows, you'll be greeted with server version is too old for client. The only solve for this could be not detaching from the tmux server, and using a tool like https://github.com/tmux-plugins/tmux-resurrect.

To go ahead using tmux next, run tmux kill-server and restore them by again running another.

1
  • I was noticing intermittent issues creating new windows and panes, and now that you mention it, these issues do coincide with brew upgrades. Creating a brand new session restores the functionality.
    – yobiscus
    Jul 16, 2021 at 13:19
0

I have been facing this problem and it was really pain. Eventually, I found out that I have to press Ctrl+B, release it and then press the other key.

For example, to create a new terminal hold Ctrl+B, release it and then press Shift+5 (%).

Do this for other functions.

0

If it's not a keymap problem, it could be caused by a default shell.

In my case, I just removed zsh by accident, then C+b or C+" are not working even the current window shell works.

It is not easy to find out for me.

0

Make sure you entered the tmux session.

This may be a silly answer but I'm the first to admit it happened to me.

Reasoning:

  • i use screen to create a tmux session via screen -S tmux
  • since I named it that way it threw me off and I kept trying the tmux commands. (I know :/)
  • so make sure to hit tmux and then try and its fine.

Glad it was simple mistake on my part. Hope it helps someone that was not awake like me at the time.

You must log in to answer this question.

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