# How to change the Web Server Port used by the Endpoint Central MSP Application? Endpoint Central MSP, by default, uses port **8040** for agent-server communication and to access the Web client. This port can be chosen during the installation of Endpoint Central MSP. If you wish to change the port after installation, follow the steps below: 1. Stop the Endpoint Central MSP Server. 2. Edit the **websettings.conf** located under `\UEMS_MSPCentralServer\conf` directory. 3. Change the value of **http.port** (normal communication) and **https.port** (secured communication) to a desired port and save. 4. Start the Endpoint Central MSP Server and connect to the Web client using the port number you have specified. The next step is to update the Endpoint Central MSP agents with the new port number. The Endpoint Central MSP agents will contact the Endpoint Central MSP Server to pull the instructions that are available to them. Follow the steps below to update the port number in the agents that reside in the client computers: 1. Download the script from: [configureDCAgentServerCommunication_7.txt](https://www.manageengine.com/products/desktop-central/configureDCAgentServerCommunication_7.txt) 2. Rename it to `configureDCAgentServerCommunication_7.vbs`. 3. Run this script from each of your remote office computers as shown below: ```vbscript cscript configureDCAgentServerCommunication_7.vbs ``` Where: - **** refers to the DNS name of the computer where Endpoint Central MSP Server is installed - **** refers to the IP Address of the computer where Endpoint Central MSP Server is installed - **** refers to the normal port that the agents use to contact the Endpoint Central MSP Server - **** refers to the secured port that the agents use to contact the Endpoint Central MSP Server (default is 8041) - **** refers to the communication protocol between the agent and the server, i.e., HTTP or HTTPS ## Executing the script on multiple computers To execute the script on multiple computers, run the script from each of your branch offices as shown below: 1. Create a network share (e.g., `\\MyServer\MyShare`). 2. Download the script: [configureDCAgentServerCommunication_7.txt](https://www.manageengine.com/products/desktop-central/configureDCAgentServerCommunication_7.txt) 3. Rename it to `configureDCAgentServerCommunication_7.vbs` and save the VB script in the network share created in Step 1. 4. Download the PsExec utility from: http://technet.microsoft.com/en-us/sysinternals/bb897553.aspx Save it, for example, in `C:\`. 5. Run the script using the following command from the DOS prompt: ```batch C:\for /f %f in (c:\computernames.txt) do psexec \\%f -u \administrator -p CSCRIPT \\MyServer\MyShare\configureDCAgentServerCommunication_7.vbs ``` Where: - **computernames.txt** contains a list of computers where you need to install the agent, which has to be specified with its complete path - **** refers to the domain or the workgroup name - **** refers to the domain or the workgroup administrator password - **** refers to the DNS name of the computer where Endpoint Central MSP Server is installed - **** refers to the IP Address of the computer where Endpoint Central MSP Server is installed - **** refers to the normal port that the agents use to contact the Endpoint Central MSP Server - **** refers to the secured port that the agents use to contact the Endpoint Central MSP Server - **** refers to the communication protocol between the agent and the server, i.e., HTTP or HTTPS