Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

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

I'm trying to set up pairing with tmux (wemux specifically). I have a pair user set up on my system and can ssh into pair and attach to a tmux session manually. However when I set up Forcecommand in the Match block to attach to tmux automatically on login, it fails saying that there is no tmux session to attach to.

Permissions are set to 777 on the socket.

I'm on OsX mountain lion, if that helps.

Any ideas?

share|improve this question

closed as off topic by EEAA, HopelessN00b, Brent Pabst, pauska, mdpc Dec 14 '12 at 16:54

Questions on Server Fault are expected to relate to server, networking, or related infrastructure administration within the scope defined by the community. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about reopening questions here.If this question can be reworded to fit the rules in the help center, please edit the question.

up vote 0 down vote accepted

If the other participant uses a different user account, you need to state the path to the socket you want to connect to with the -S /path/to/some/socket flag. The same flag can be specified when creating the tmux server.

This is because if you do not specify the socket path manually, the default location for the socket is /tmp/tmux-[USER ID]/default as you can see in tmux's source code. That means it differs for every user account.

A word of advice: You should not be setting the socket to 777 as this enables any user on the system to attach to sessions in it and execute commands in the shell running within. That most probably causes a serious security hole.

One idea to have an easy setup would be to create a group which contains all users allowed to join the tmux server and set it to be the owning group of the socket while setting the mode to 770.

share|improve this answer

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