Port 8090 already in use

2
Hi, A few minutes ago i was working on an application and suddenly it got stuck. I was trying to get an overview of all people who registered for a specific game. So i nested a listview inside a dataview that was nested inside a dataview. I then dragged a text (= common widget) in the listview and tried to select a specific attribute. When i try to open a specific association the program crashed and shut down. I tried a second time with the same result. The third time the change did work but I couldn’t start application anymore. I got the following error: What you need to know is that I’m the only person working on the application (nobody was invited) and no other application are running (mendix studio nor mendix studio pro)
asked
4 answers
2

Maybe it was not properly shut down the last time you stopped the application. Did you check your task manager? Or did you try to turn your PC off and on again? (I heard turning it off and on again is magic)

answered
3

Solved! Good old pc restart.

answered
2

Possible causes:

Cause 1: Multiple instances of Mendix Studio Pro are running at the same time and are using the same port. In our case port 8090.

    Possible solutions: 

  • You can stop the application running in the other instance of Mendix Studio Pro or just close that instance.
  • Change the port number for your application in the Server tab of the Project Settings dialog eg. change port number from 8090 to 8091
     

Cause  2: An instance of Mendix Studio Pro has crashed, but a process is still listening to port 8090

    Possible solutions: 

  • Change the port number for your application in the Server tab of the Project Settings dialog eg. change port number from 8090 to 8091
  • Stop the process that is listening to port 8090 (see example below).

 
Stop the process

Let's take a closer look at stopping the process that is still listening to port 8090 with an example.
In this example Mendix Studio Pro crashed. We are opening a new instance of Mendix Studio Pro. When we start the application we get the Warning with message “It appears that port 8090 is already in use...”. In this case we can stop the process from the command line by following the steps below.

Step 1: Open Command Prompt

  • Press Windows key and type cmd
  • Select Command Prompt

 

Note that the values in the example will differ from your values. Do not just copy the values from the example

 

Step 2: Find what process is still listening to port the port

  •     Command to find the process

                   netstat -ano | findstr :<PORT>

  •     Replace <PORT> with the port mentioned in the warning message and hit enter.

                   Eg. netstat -ano | findstr :8090

 

Step 3: Stop the process

  •     Copy the process id (PID) from previous result (see image)

                   Eg. 29565

  •     Command to kill the process:

                   taskkill /PID <PID> /F 

  •     Replace <PID>  and hit enter.

                   Eg. taskkill /PID 29565 /F

 

Step 4:

  •     Test if the process has stopped. The line should be empty.

                    Eg. netstat -ano | findstr :8090

 

Now you can restart you application and it should run on port 8090.

 

I hope this helps :)

answered
1

that error can also happened when you are working on multiple mendix project, and run the projects at the same time.

You can run multiple projects at the same time if you edit the port that you use in the project setting

(setting → edit configurations → change the runtime port to 8081 for example).

answered