Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

tmux: open terminal failed: missing or unsuitable terminal: xterm-256color

Tags:

terminal

tmux

I used home-brew to setup tmux on a mac. When trying to run tmux I keep on getting this error

open terminal failed: missing or unsuitable terminal: xterm-256color

any suggestions?

like image 983
user3256740 Avatar asked Feb 03 '14 09:02

user3256740


3 Answers

Your system doesn't have xterm-256color. You could:

  • Set TERM to something other than xterm-256color outside tmux (try just plain export TERM=xterm).

  • See if there is a package containing xterm-256color, perhaps a later version of ncurses or terminfo.

  • Install it manually from another system with something like:

    infocmp -x xterm-256color > out
    

    Then transfer the "out" file to your Mac and try:

    tic out
    
like image 59
bob Avatar answered Nov 13 '22 03:11

bob


This happened to me during a system upgrade. Unfortunately I did not see a way besides restarting: tmux kill-server and then run tmux.

like image 26
Tatsh Avatar answered Nov 13 '22 02:11

Tatsh


you can just type export TERM=xterm in console when you see this error, or put export TERM=xterm in the file ~/.bash_profile and source ~/.bash_profile. then you may never get this error again.
This works fine on my debian.

like image 23
Shawn Wang Avatar answered Nov 13 '22 04:11

Shawn Wang