# Cannot start webdriveragent on simulator due to port problem

**URL:** <https://forum.katalon.com/t/cannot-start-webdriveragent-on-simulator-due-to-port-problem/24084>\
**Category:** Mobile Testing\
**Tags:** mobile-testing, katalon-studio\
**Created:** [April 29, 2019, 12:18pm UTC](https://forum.katalon.com/t/cannot-start-webdriveragent-on-simulator-due-to-port-problem/24084 "2019-04-29T12:18:46Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![zll-311](https://avatars.discourse-cdn.com/v4/letter/z/34f0e0/32.png) [@zll-311](https://forum.katalon.com/u/zll-311)\
**Post date:** [April 29, 2019, 12:18pm UTC](https://forum.katalon.com/t/cannot-start-webdriveragent-on-simulator-due-to-port-problem/24084/1 "2019-04-29T12:18:46Z")

</div>

I am trying to start the automation on Mac, and already setup:  
katalon 6.1.2  
xcode 10.1 with SDK 12.1  
node v11.14.0  
npm 6.9.0  
appium 1.8.2-beta  
and manually clone webDriverAgent lastest version  
also the building of webDriverAgent in xcode passed.

but when I run the test from katalon, it says “[WD Proxy] Got an unexpected response: {“errno”:“ECONNREFUSED”,“code”:“ECONNREFUSED”,“syscall”:“connect”,“address”:“127.0.0.1”,“port”:62613}”  
actually the started webDriverAgent’s port is 8100(able to get response from curl -GET [http://127.0.0.1:8100/status](http://127.0.0.1:8100/status))  
I have tried to set wdLocalPort in desired capabilities which is not working.

from the debug info, it seems appium always set random port to start webDriverAgent, so is there a way to specific the port or any workaround?

thanks

---

<div class="post-metadata">

**Author:** ![zll-311](https://avatars.discourse-cdn.com/v4/letter/z/34f0e0/32.png) [@zll-311](https://forum.katalon.com/u/zll-311)\
**Post date:** [April 30, 2019, 2:27am UTC](https://forum.katalon.com/t/cannot-start-webdriveragent-on-simulator-due-to-port-problem/24084/2 "2019-04-30T02:27:14Z")

</div>

after search the commit of appium, problem solved, should use wdaRemotePort here
