I have done the following:

  1. Start Selenium Grid
  2. Started 2 emulator; Started appium servers for both using appium -p --nodeconfig /absolute/path/.json
  3. Ran my script:

    DesiredCapabilities cap = new DesiredCapabilities();

        cap.SetCapability(MobileCapabilityType.BrowserName, "Chrome");
        cap.SetCapability(CapabilityType.Platform, "Android");
        cap.SetCapability("deviceName", "emulator-5554");//Nexus 5X API 24
        cap.SetCapability("devicePort", "5554");
        AndroidDriver<IWebElement> driver = new AndroidDriver<IWebElement>(new Uri("http://localhost:<port>/wd/hub"), cap);
        var navigation = driver.Navigate();
        DesiredCapabilities cap2 = new DesiredCapabilities();
        cap2.SetCapability(MobileCapabilityType.BrowserName, "Chrome");
        cap2.SetCapability(CapabilityType.Platform, "Android");
        cap2.SetCapability("deviceName", "emulator-5556");//Nexus 5X API 24
        cap2.SetCapability("devicePort", "5556");
        AndroidDriver<IWebElement> driver2 = new AndroidDriver<IWebElement>(new Uri("http://<myIP>:<appiumPort2>/wd/hub"), cap2);
        var navigation2 = driver2.Navigate();

Then on my nodeconfig it has the following:

          "browserName": "Chrome",
          "deviceName": "emulator-5554",
          "devicePort": "5554",
          "maxInstances": 2,
          "platform": "Android",
          "version": "8.0"
    "proxy": "org.openqa.grid.selenium.proxy.DefaultRemoteProxy",
    "host": "",
    "port": 4723,
    "maxSession": 1,
    "register": true,
    "registerCycle": 5000,
    "hubPort": 4444,
    "hubHost": ""

What it does is it only runs on one emulator even if I started both emulators and connected my ports to the respective emulator. Not sure what I'm missing

  • Can you attach the appium servers logs , I suspect you will see the answer there. – Amias Feb 4 at 11:32
  • I have resolved this and looking at the logs, there is a conflicting port number for bootstrap and the appium server. – Marj Feb 5 at 15:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.