Appium XCUITest failing due to Error starting iproxy: 'spawn iproxy ENOENT'

Hi,
I am attempting to run Selenium tests in real IOS device (ipad). However each time I am getting the error saying Error starting iproxy: ‘spawn iproxy ENOENT’.

Appium version: 1.6.3
IOS Device: Ipad Air
IOS version: 10.2
XCode version: 8.2

Following are my desired caps:
[Appium] Creating new XCUITestDriver session
[Appium] Capabilities:
[Appium] app: ‘/Users/Harshendu/Downloads/EGPacPlus0.1.72-dev.ipa’
[Appium] platformVersion: ‘10.2’
[Appium] automationName: ‘XCUITest’
[Appium] platformName: ‘iOS’
[Appium] udid: ‘d69cfcd0ea7e167b9a0b58b2daba958030443ac9’
[Appium] deviceName: ‘iPad Air’
[Appium] fullReset: true
[Appium] launchTimeout: ‘20000’

Appium log is:
Harshendus-MacBook-Pro:~ Harshendu$ appium
[Appium] Welcome to Appium v1.6.3
[Appium] Appium REST http interface listener started on 0.0.0.0:4723
[HTTP] --> POST /wd/hub/session {“capabilities”:{“desiredCapabilities”:{“app”:"/Users/Harshendu/Downloads/EGPacPlus0.1.72-dev.ipa",“platformVersion”:“10.2”,“automationName”:“XCUITest”,“platformName”:“iOS”,“udid”:“d69cfcd0ea7e167b9a0b58b2daba958030443ac9”,“deviceName”:“iPad Air”,“fullReset”:true,“launchTimeout”:“20000”},“requiredCapabilities”:{}},“desiredCapabilities”:{“app”:"/Users/Harshendu/Downloads/EGPacPlus0.1.72-dev.ipa",“platformVersion”:“10.2”,“automationName”:“XCUITest”,“platformName”:“iOS”,“udid”:“d69cfcd0ea7e167b9a0b58b2daba958030443ac9”,“deviceName”:“iPad Air”,“fullReset”:true,“launchTimeout”:“20000”},“requiredCapabilities”:{}}
[debug] [MJSONWP] Calling AppiumDriver.createSession() with args: [{“app”:"/Users/Harshendu/Downloads/EGPacPlus0.1.72-dev.ipa",“platformVersion”:“10.2”,“automationName”:“XCUITest”,“platformName”:“iOS”,“udid”:“d69cfcd0ea7e167b9a0b58b2daba958030443ac9”,“deviceName”:“iPad Air”,“fullReset”:true,“launchTimeout”:“20000”},{},{“desiredCapabilities”:{“app”:"/Users/Harshendu/Downloads/EGPacPlus0.1.72-dev.ipa",“platformVersion”:“10.2”,“automationName”:“XCUITest”,“platformName”:“iOS”,“udid”:“d69cfcd0ea7e167b9a0b58b2daba958030443ac9”,“deviceName”:“iPad Air”,“fullReset”:true,“launchTimeout”:“20000”},“requiredCapabilities”:{}},null,null]
[Appium] Creating new XCUITestDriver session
[Appium] Capabilities:
[Appium] app: ‘/Users/Harshendu/Downloads/EGPacPlus0.1.72-dev.ipa’
[Appium] platformVersion: ‘10.2’
[Appium] automationName: ‘XCUITest’
[Appium] platformName: ‘iOS’
[Appium] udid: ‘d69cfcd0ea7e167b9a0b58b2daba958030443ac9’
[Appium] deviceName: ‘iPad Air’
[Appium] fullReset: true
[Appium] launchTimeout: ‘20000’
[debug] [XCUITest] XCUITestDriver version: 2.4.2
[BaseDriver] Session created with session id: 16d702b5-2c38-422c-bf92-34f519abc313
[debug] [XCUITest] Xcode version set to ‘8.2’
[debug] [XCUITest] iOS SDK Version set to ‘10.2’
[debug] [XCUITest] Available devices: d69cfcd0ea7e167b9a0b58b2daba958030443ac9
[debug] [XCUITest] Creating iDevice object with udid d69cfcd0ea7e167b9a0b58b2daba958030443ac9
[XCUITest] Determining device to run tests on: udid: ‘d69cfcd0ea7e167b9a0b58b2daba958030443ac9’, real device: true
[BaseDriver] Using local app ‘/Users/Harshendu/Downloads/EGPacPlus0.1.72-dev.ipa’
[debug] [BaseDriver] Copying local zip to tmp dir
[debug] [BaseDriver] Unzipping /var/folders/lb/v8wy_7_519g99zqg57krkcy40000gn/T/20161116-35192-1m42yns.zd6o91kyb9/appium-app.zip
[debug] [BaseDriver] Testing zip archive: /var/folders/lb/v8wy_7_519g99zqg57krkcy40000gn/T/20161116-35192-1m42yns.zd6o91kyb9/appium-app.zip
[BaseDriver] Unzipped local app to ‘/var/folders/lb/v8wy_7_519g99zqg57krkcy40000gn/T/20161116-35192-1m42yns.zd6o91kyb9/Payload/EGPacPlus.app’
[debug] [XCUITest] Checking whether app ‘/var/folders/lb/v8wy_7_519g99zqg57krkcy40000gn/T/20161116-35192-1m42yns.zd6o91kyb9/Payload/EGPacPlus.app’ is actually present
[debug] [XCUITest] App is present
[debug] [ios-app-utils] Getting bundle ID from app ‘/var/folders/lb/v8wy_7_519g99zqg57krkcy40000gn/T/20161116-35192-1m42yns.zd6o91kyb9/Payload/EGPacPlus.app’: ‘com.egate-solutions.EGPacPlus’
[debug] [iOSLog] Attempting iOS device log capture via libimobiledevice idevicesyslog
[debug] [iOSLog] Found idevicesyslog: ‘/usr/local/bin/idevicesyslog’
[XCUITest] Setting up real device
[debug] [XCUITest] App is already installed.
[debug] [XCUITest] Full reset requested. Forcing app install after uninstall app
[debug] [XCUITest] App installed successfully.
[XCUITest] Using WDA path: ‘/usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent’
[XCUITest] Using WDA agent: ‘/usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent/WebDriverAgent.xcodeproj’
[XCUITest] Launching WebDriverAgent on the device
[debug] [XCUITest] Carthage found: /usr/local/bin/carthage
[debug] [XCUITest] Killing hanging processes
[debug] [XCUITest] Using real device logger ‘idevicesyslog’
[debug] [XCUITest] Beginning test with command ‘xcodebuild build test -project /usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent/WebDriverAgent.xcodeproj -scheme WebDriverAgentRunner -destination id=d69cfcd0ea7e167b9a0b58b2daba958030443ac9 -configuration Debug’ in directory ‘/usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent’
[XCUITest] Waiting for WebDriverAgent to start on device
[debug] [XCUITest] Log file for xcodebuild test: /Users/Harshendu/Library/Developer/Xcode/DerivedData/WebDriverAgent-brdadhpuduowllgivnnvuygpwhzy/Logs/Test/BDCE6950-A3F6-441D-B3C0-2C28DBF54362/Session-WebDriverAgentRunner-2016-12-16_191931-GuSz7Z.log
[debug] [WebDriverAgent] Device: Dec 16 19:19:37 HARSHENDU-BHARDWAJs-iPad XCTRunner[346] : Running tests…
[debug] [WebDriverAgent] Device: Dec 16 19:19:38 HARSHENDU-BHARDWAJs-iPad XCTRunner[346] : Continuing to run tests in the background with task ID 1
[XCUITest] Detected that WebDriverAgent is running at url ‘http://10.0.1.8:8100
[XCUITest] WebDriverAgent started at url ‘http://10.0.1.8:8100
[debug] [XCUITest] Starting iproxy to forward traffic from local port 8100 to device port 8100 over USB
[XCUITest] Error starting iproxy: ‘spawn iproxy ENOENT’
[XCUITest] Unable to start iproxy. Is it installed?
[XCUITest] Shutting down sub-processes
[XCUITest] Shutting down xcodebuild process (pid 35241)
[XCUITest] xcodebuild exited with code ‘null’ and signal ‘SIGTERM’
[XCUITest] Shutting down Logger process (pid 35246)
[XCUITest] System log exited with code ‘0’
[XCUITest] Shutting down iproxy process (pid undefined)
[debug] [XCUITest] iproxy process did not end in a timely fashion: ‘Process didn’t end after 10000ms’. Sending ‘SIGKILL’…
^C[Appium] Received SIGINT - shutting down
[MJSONWP] Encountered internal error running command: Error: Process didn’t end after 10000ms
at Timeout._onTimeout (…/…/lib/teen_process.js:240:16)
at ontimeout (timers.js:365:14)
at tryOnTimeout (timers.js:237:5)
at Timer.listOnTimeout (timers.js:207:5)
[HTTP] <-- POST /wd/hub/session 500 32261 ms - 169
[HTTP] --> POST /wd/hub/session {“desiredCapabilities”:{“app”:"/Users/Harshendu/Downloads/EGPacPlus0.1.72-dev.ipa",“platformVersion”:“10.2”,“automationName”:“XCUITest”,“platformName”:“iOS”,“udid”:“d69cfcd0ea7e167b9a0b58b2daba958030443ac9”,“deviceName”:“iPad Air”,“fullReset”:true,“launchTimeout”:“20000”},“requiredCapabilities”:{}}
[debug] [MJSONWP] Calling AppiumDriver.createSession() with args: [{“app”:"/Users/Harshendu/Downloads/EGPacPlus0.1.72-dev.ipa",“platformVersion”:“10.2”,“automationName”:“XCUITest”,“platformName”:“iOS”,“udid”:“d69cfcd0ea7e167b9a0b58b2daba958030443ac9”,“deviceName”:“iPad Air”,“fullReset”:true,“launchTimeout”:“20000”},{},null,null,null,null,null]
[Appium] Creating new XCUITestDriver session
[Appium] Capabilities:
[Appium] app: ‘/Users/Harshendu/Downloads/EGPacPlus0.1.72-dev.ipa’
[Appium] platformVersion: ‘10.2’
[Appium] automationName: ‘XCUITest’
[Appium] platformName: ‘iOS’
[Appium] udid: ‘d69cfcd0ea7e167b9a0b58b2daba958030443ac9’
[Appium] deviceName: ‘iPad Air’
[Appium] fullReset: true
[Appium] launchTimeout: ‘20000’
[debug] [XCUITest] XCUITestDriver version: 2.4.2
[BaseDriver] Session created with session id: 4a6a6b5c-85fd-48fc-ab46-c64a0c7c2277
[debug] [XCUITest] Xcode version set to ‘8.2’
[debug] [XCUITest] iOS SDK Version set to ‘10.2’
[debug] [XCUITest] Available devices: d69cfcd0ea7e167b9a0b58b2daba958030443ac9
[debug] [XCUITest] Creating iDevice object with udid d69cfcd0ea7e167b9a0b58b2daba958030443ac9
[XCUITest] Determining device to run tests on: udid: ‘d69cfcd0ea7e167b9a0b58b2daba958030443ac9’, real device: true
[BaseDriver] Using local app ‘/Users/Harshendu/Downloads/EGPacPlus0.1.72-dev.ipa’
[debug] [BaseDriver] Copying local zip to tmp dir
[debug] [BaseDriver] Unzipping /var/folders/lb/v8wy_7_519g99zqg57krkcy40000gn/T/20161116-35192-9phkwf.r8xk98jjor/appium-app.zip
[debug] [BaseDriver] Testing zip archive: /var/folders/lb/v8wy_7_519g99zqg57krkcy40000gn/T/20161116-35192-9phkwf.r8xk98jjor/appium-app.zip
[BaseDriver] Unzipped local app to ‘/var/folders/lb/v8wy_7_519g99zqg57krkcy40000gn/T/20161116-35192-9phkwf.r8xk98jjor/Payload/EGPacPlus.app’
[debug] [XCUITest] Checking whether app ‘/var/folders/lb/v8wy_7_519g99zqg57krkcy40000gn/T/20161116-35192-9phkwf.r8xk98jjor/Payload/EGPacPlus.app’ is actually present
[debug] [XCUITest] App is present
[debug] [ios-app-utils] Getting bundle ID from app ‘/var/folders/lb/v8wy_7_519g99zqg57krkcy40000gn/T/20161116-35192-9phkwf.r8xk98jjor/Payload/EGPacPlus.app’: ‘com.egate-solutions.EGPacPlus’
[debug] [iOSLog] Attempting iOS device log capture via libimobiledevice idevicesyslog
[debug] [iOSLog] Found idevicesyslog: ‘/usr/local/bin/idevicesyslog’
[XCUITest] Setting up real device
[debug] [XCUITest] App is already installed.
[debug] [XCUITest] Full reset requested. Forcing app install after uninstall app
[debug] [XCUITest] App installed successfully.
[XCUITest] Using WDA path: ‘/usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent’
[XCUITest] Using WDA agent: ‘/usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent/WebDriverAgent.xcodeproj’
[XCUITest] Launching WebDriverAgent on the device
[debug] [XCUITest] Carthage found: /usr/local/bin/carthage
[debug] [XCUITest] Killing hanging processes
[debug] [XCUITest] Using real device logger ‘idevicesyslog’
[debug] [XCUITest] Beginning test with command ‘xcodebuild build test -project /usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent/WebDriverAgent.xcodeproj -scheme WebDriverAgentRunner -destination id=d69cfcd0ea7e167b9a0b58b2daba958030443ac9 -configuration Debug’ in directory ‘/usr/local/lib/node_modules/appium/node_modules/appium-xcuitest-driver/WebDriverAgent’
[XCUITest] Waiting for WebDriverAgent to start on device
[debug] [XCUITest] Log file for xcodebuild test: /Users/Harshendu/Library/Developer/Xcode/DerivedData/WebDriverAgent-brdadhpuduowllgivnnvuygpwhzy/Logs/Test/5A54C2D4-D854-4FC6-A65C-2AD2DFFBCE91/Session-WebDriverAgentRunner-2016-12-16_192003-ZPAArX.log
[debug] [WebDriverAgent] Device: Dec 16 19:20:08 HARSHENDU-BHARDWAJs-iPad XCTRunner[352] : Running tests…
[debug] [WebDriverAgent] Device: Dec 16 19:20:09 HARSHENDU-BHARDWAJs-iPad XCTRunner[352] : Continuing to run tests in the background with task ID 1
[XCUITest] Detected that WebDriverAgent is running at url ‘http://10.0.1.8:8100
[XCUITest] WebDriverAgent started at url ‘http://10.0.1.8:8100
[debug] [XCUITest] Starting iproxy to forward traffic from local port 8100 to device port 8100 over USB
[XCUITest] Error starting iproxy: ‘spawn iproxy ENOENT’
[XCUITest] Unable to start iproxy. Is it installed?
[XCUITest] Shutting down sub-processes
[XCUITest] Shutting down xcodebuild process (pid 35293)
[XCUITest] xcodebuild exited with code ‘null’ and signal ‘SIGTERM’
[XCUITest] Shutting down Logger process (pid 35298)
[XCUITest] System log exited with code ‘0’
[XCUITest] Shutting down iproxy process (pid undefined)
[debug] [XCUITest] iproxy process did not end in a timely fashion: ‘Process didn’t end after 10000ms’. Sending ‘SIGKILL’…
[MJSONWP] Encountered internal error running command: Error: Process didn’t end after 10000ms
at Timeout._onTimeout (…/…/lib/teen_process.js:240:16)
at ontimeout (timers.js:365:14)
at tryOnTimeout (timers.js:237:5)
at Timer.listOnTimeout (timers.js:207:5)
[HTTP] <-- POST /wd/hub/session 500 31004 ms - 169
[HTTP] --> POST /wd/hub/session {“capabilities”:{“desiredCapabilities”:{“app”:"/Users/Harshendu/Downloads/EGPacPlus0.1.72-dev.ipa",“platformVersion”:“10.2”,“automationName”:“XCUITest”,“platformName”:“iOS”,“udid”:“d69cfcd0ea7e167b9a0b58b2daba958030443ac9”,“deviceName”:“iPad Air”,“fullReset”:true,“launchTimeout”:“20000”},“requiredCapabilities”:{}}}
[debug] [MJSONWP] Bad parameters: BadParametersError: Parameters were incorrect. We wanted {“required”:[“desiredCapabilities”],“optional”:[“requiredCapabilities”,“capabilities”,“sessionId”,“id”,“sessionId”,“id”,“sessionId”,“id”]} and you sent [“capabilities”]
[HTTP] <-- POST /wd/hub/session 400 3 ms - 205
Harshendus-MacBook-Pro:~ Harshendu$

I have re installed, updated, appium, ideviceinstaller, libimobiledevice, carthage, xcode, ios-deploy many times over now.
I have restarted my mac and ipad many times over now also.

I do see some related issues in here that come close to my issue but not exactly.

In the end: The app gets installed along with another icon for webdriveragent. WebDriverAgent flashes three times, App does not launch and nothing else happens.

Any help is greatly appreciated. Thank you.

Update: The app gets installed along with another icon for webdriveragent. In the end the test fails due to above issue.

I am facing a similar issue.

Were you able to overcome this one?