TMUX - Sharing terminal between Users

Reading Time : ~ .

More Often you would've come across sharing screens with applications like Teamviewer, Windows Remote Desktop Connection or remmina (if you're a Linux user). But if you want to share only your terminal, you can look up to Tmux. 

Installing Tmux:

apt-get update
apt-get install tmux

Starting a Tmux Session:

tmux new-session

This starts a new tmux session by default with a session-name 0. When you initialize a new session, will be 1 and so on. If you want to start a named session, the command would be

tmux new-session -s <session-name>

Connecting to existing session:

tmux attach -t <session-number>
tmux attach -t <session-name>

The above will only be possible if you're logged in as the same user as one sharing the session.

Using Sockets for different users to connect:

To Start a new session
tmux -S /tmp/socket

Change its permission for other users to access
chmod 777 /tmp/socket

for other users to attach to the session
tmux -S /tmp/socket attach
    By Posted On
SENIOR DEVELOPER at MICROPYRAMID

Need any Help in your Project?Let's Talk

Latest Comments
Related Articles
Django on GAE (google app engine) Ashwin Kumar

Google App Engine (often referred to as GAE or simply App Engine) is a platform as a service (PaaS) cloud computing platform for developing and ...

Continue Reading...
Clustering of Docker Containers using Docker Swarm Jagadeesh V

There are many available ways of Docker clustering. Kubernetes, Docker cloud, Docker Swarm etc., In this Tutorial we will learn setting up a cluster using ...

Continue Reading...
ELK Stack for Parsing your Logs- Part 2 Jagadeesh V

In Previous Tutorial we looked into Setting up EL Server which can ingest your Syslog files. In this Post, you will learn about pushing your ...

Continue Reading...

Subscribe To our news letter

Subscribe to our news letter to receive latest blog posts into your inbox. Please fill your email address in the below form.
*We don't provide your email contact details to any third parties