Error when running appium test parallel with selenium grid

When I run one test on several devices parallel, I get error: "“Failed to start an Appium session err was: Error: EPERM: operation not permitted, rename”

This error occurs on some of the device or some devices randomly. So I can run it and everything will be ok, but often I get this error.

I run hub:
java -jar selenium-server-standalone-2.53.0.jar -role webdriver -nodeConfig emulator-5554.json -hub http://127.0.0.1:4444/grid/register

Appium server:
appium --address 127.0.0.1 --port 4721 -bp 2253 --udid emulator-5554 --nodeconfig C:\SeleniumGrid\Android\emulator-5554.json

Example of the json configuration file:
{ “capabilities”:
[
{
“deviceName”: “emulator-5554”,
“browserName”:“Browser”,
“version”:“4.4.4”,
“maxInstances”: 2,
“platform”:“ANDROID”,
“appPackage”: “com.olx.olx”,
“appActivity”: “com.olx.olx.ui.activities.SplashActivity”,
“appWaitActivity”: “com.olx.olx.ui.activities.SplashActivity”
}
],
“configuration”:
{
“cleanUpCycle”:2000,
“timeout”:30000,
“proxy”: “org.openqa.grid.selenium.proxy.DefaultRemoteProxy”,
“url”:“http://127.0.0.1:4554/wd/hub”,
“host”: “127.0.0.1”,
“port”: 4554,
“maxSession”: 10,
“register”: true,
“registerCycle”: 5000,
“hubPort”: 4444,
“hubHost”: “127.0.0.1”
}
}
I can suppose, that it occurs because two or more threads refer to one apk file simultaneously

What do I wrong?

http://blog.zymr.com/configuring-appium-node-servers-with-selenium-grid

It is tutorial for starting appium servers and selenium hub. I know it.
I have a problem in execution tests

1 Like