Topics tend to come into Leostream Support in waves. The latest stream of questions center around managing multiple simultaneous connections to a Linux machine running a VNC server. This allows several users to share one Linux machine while giving each user an independent session, similar to Microsoft Remote Desktop Services. In this blog post, we show you how you can configure the Linux server and Leostream to support this scenario.
Configuration for CentOS/RHEL 7:
- Download and install the latest Leostream Agent
sudo java -jar <Agent JAR file>
- Install VNC server package
sudo yum install tigervnc-server
- Set VNC password (replace <username> with the applicable username)
su – <username>
- Note: the user login password must match the credentials being used in Leostream
- Note: you do not have to set a view-only password
- Enable the VNC port(s) through the firewall (each user requires their own port starting from 5901)
firewall-cmd –add-port=5901/tcp –permanent
- Note: you can specify a port range for multiple users, such as:
firewall-cmd –add-port=5901-5904/tcp –permanent
- Restart the CentOS/RHEL machine
Configuring the Leostream Connection Broker for Multi-User VNC:
- Navigate to the Setup>Centers page and select Add Center
- Set the Center Type to “Remote Desktop Services/Multi-User” and input the correct information for the device. Make sure to set the maximum concurrent connections option to the intended value.
- Open the Configuration>Pools page and create a new pool that contains the VNC session offers.
- Create a Protocol Plan on the Configuration>Protocol Plans page that uses VNC by setting VNC to priority 1 and everything else to “Do not use”.
- Create a new Policy on the Configuration>Policies page and set it to offer desktops from the VNC pool that you created in step 3.
- Set the new Policy to use the VNC protocol configured in step 4 by setting it in the Plans section of the Policy form.
- On the Configuration>Assignments page set the Default Policy to the VNC policy, or assign the policy to specific users based on other parameters.
- Test the connection with Leostream Connect or the Web Client and enjoy multi-user VNC!
- List current VNC sessions:
ps -ef | grep vnc
- Kill a VNC session:
kill -9 <id-from-vnc-list>