有时在我失去与服务器的连接后,我发现我无法再次连接到现有的 tmux 会话,因为no server running on /tmp/tmux-1000/default,但进程存在。
但是,我无法重现这个问题,我发现它可能会在 ssh 连接空闲超时或关闭终结器而不退出 ssh 后发生。
详细见下图:
~ $ ps -ef | grep tmux
huchi 1852249 1 0 10:50 ? 00:00:01 tmux new-session -t cpp
huchi 1862727 1852167 0 19:10 pts/0 00:00:00 grep --color=auto tmux
~ $
~ $ tmux ls
no server running on /tmp/tmux-1000/default
~ $
~ $ tmux start
~ $
~ $ tmux ls
no server running on /tmp/tmux-1000/default
Run Code Online (Sandbox Code Playgroud)
我的操作系统是Linux c-001 4.18.0-193.6.3.el8_2.x86_64 #1 SMP Wed Jun 10 …