Motadata RDP Server Installation Guide
The RDP server communicates with the RDP Agent and ServiceOps to establish the RDP sesson. To do so, first install the RDP Server, configure the RDP Settings, and lastly install the RDP Agent.
Prerequisites
- ServiceOps Server should be up and running
- ServiceOps Server's IP Address is required
- ServiceOps Database port number 5432 should be open
- Domain name is required
- Host Entry of the IP Address and Domain name must be done in the local machine
This document is applicable for Ubuntu 22 only.
RDP Server Installation Setup
- Download and run the Motadata RDP Server Installer on a Linux machine.
Assign executable permission and run the setup using the below command:
chmod 777 MotadataServiceOpsMeshCentralU22
Add host entry for domain name and IP Address in your system using the below command.
Command Syntax:
echo “IPADDRESS DOMAINNAME” >> /etc/hosts
Example:
echo “172.16.12.83 mydomain.example.com” >> /etc/hosts
- Ensure you have the Domain name.
Run the file using the below command:
./MotadataServiceOpsMeshCentralU22
noteUse root user to run the command.
- Enter the IP Address of the ServiceOps Server as shown below. The IP Address is required when the RDP Server and the ServiceOps Server are installed on different machines.
- The IP Address is not asked, if the RDP Server and ServiceOps Server are installed on the same machine.
- Avoid installing the Nginx server on the remote machine that hosts the RDP server.
- Enter the DB Password of the ServiceOp Server as shown below.
It is an encrypted password. To get the password follow the below steps:
Go to the path cd /opt/flotomate/main-server/lib.
Run the below command to get the password.
cat boot-hosted-exec.conf | grep DB_PASSWORD
The installer might take approx 5 minutes to install.
The RDP server is now successfully installed. You can verify the service status using the below command.
systemctl status meshcentral.service
- Once installed, configure the RDP settings from the Technician Portal, and then the RDP Server Agent.
After installation, ensure the chown permission is applied by going to the path cd /opt/meshcentral, and using the following command:
Command Syntax: chown -R {user}:{usergroup} meshcentral
For example: chown -R flotomate:flotomate meshcentral
Additional Optional Settings
Once the RDP Server is installed, you can perform the additional configurations like changing the domain name, port, and SSL Certificate of the RDP server.
Change Domain Name
To change the domain name,
Change the domain name in the following 3 files:
- nginx.conf
- hosts
- config.json
Nginx Config File
- Open the Terminal server and go to the path /etc/nginx/conf.d/.
- Check the list of files in it using the
ll
command.
Open and edit the nginx.conf file using the command:
vim mesh_nginx.conf
The below screen appears.
- Replace the server_name with the desired domain name. For example: rdp.example.com. By default the server domain name is rdp.motadataserviceops.com.
- Once done, save the file using the
:wq!
command.
To replicate the changes, restart the nginx service whenever any changes are made in the nginx.conf file.
Host File
To edit the host file,
Go to the path /etc/hosts.
Edit the file using the below command:
vim hosts
- Edit the domain host name and also add the server IP Address before it, as shown below.
- Once done, save the file using the
:wq!
command.
Config File
To edit the RDP config file,
- Navigate to the path /opt/meshcentral/meshcentral-data and view the files in it using the
ll
command as shown below.
Next, edit the config.json file using the below command.
vim config.json
- Change the Domain name in the config file as shown below.
- Next, in the same file change the Email address and Domain name in the "letsencrypt" section as shown below.
Once done, save the file using the
:wq!
command.Restart the RDP Server service using the below command:
systemctl restart meshcentral.service
Change Port Number
ServiceOps uses the default 8443 and 4330 port numbers. In case, these are not free you can change the port to the desired one by following the below procedure.
- To change the port numbers, edit the following 3 files:
- nginx.conf
- fmt_nginx.conf
- config.json
- Before editing, kindly take the backup of config files.
- Ensure that the port is not used by any services or the ServiceOps Server.
RDP Nginx Config File
To edit the file,
- Navigate to the path /etc/nginx/conf.d/.
- Open the mesh_nginx.conf file. It contains the default port number 8443.
- Next, edit the file and change the port number from 8443 to 8089 as shown below. Here, port number 8089 is used as an example.
- Once done, save the file.
- Restart the Nginx Server service.
Fmt Nginx Config File
To edit the fmt_nginx.conf file,
- Navigate to the path /etc/nginx/conf.d/.
- Open the fmt_nginx.conf file. It contains the default port number 8443.
- Next, edit the file, and change the port number from 8443 to 8089 as shown below. Here, port number 8089 is used as an example.
- Once done, save the file.
- Restart the Nginx server service.
Ensure the same port numbers are updated in the fmt_nginx.conf and mesh_nginx.conf files.
Config.json
To edit the RDP config file,
- Navigate to the path /opt/meshcentral/meshcentral-data and view the files in it using the
ll
command as shown below.
Next, edit the config.json file using the below command.
vim config.json
- Change the aliasPort in the config file as shown below. Here, port number 8443 is replaced with 8089.
- Once done, save the file using the
:wq!
command.
Once the port number is changed in all the 3 files, allow it from Firewall using the below commands.
ufw status
ufw allow 8089Restart the Nginx and RDP server services using the below commands:
systemctl restart meshcentral
systemctl restart nginxSimilarly, using the above steps, you can change the port number 4430 in all the 3 files.
config.json
mesh_nginx.conf
fmt_nginx.conf
Change SSL Certificate
To change the SSL Certificate file for RDP,
- Navigate to the path /etc/nginx/conf.d/.
- Open the mesh_nginx.conf file.
- Edit the ssl_certificate as shown below.
- Once done, save the file.
- Restart the Nginx server service and wait for approx 30 seconds.