[appium-device-farm-5] — How to enable ‘Server-Logs’ in “Appium Device Farm” plugin

Get a step-by-step walkthrough in the video below!
Inthis article, we will walk you through how to enable server logs in the Appium Device Farm plugin.
What Are “Server Logs” in Device Farm?
Server logs capture runtime details such as:
- Device detection and registration
- Session allocation
- Appium command routing
- Errors and exceptions at plugin level
These logs are useful when:
- You’re troubleshooting issues with device assignment
- You need audit trails for test runs
- You want to monitor real-time device interactions
Device Farm —” Server” screen : Without Log argument
appium server started without log argument.
appium -ka 800 --use-plugins=device-farm -pa /wd/hub --plugin-device-farm-platform=android

Step-by-Step: Enable Server Logs in Appium Device Farm
Start Appium with the Plugin and Log Options
Use the following command to start Appium server with logging enabled:
appium -ka 800 --use-plugins=device-farm -pa /wd/hub --plugin-device-farm-platform=android --log ./devicefarm.log
Breakdown of Key Flags:
--log ./devicefarm.log
Saves server logs to the given file.
Note: The --log
option is critical—it writes all server activity to the specified file path.
Example:

Execute the script:

Complete Script — https://github.com/AppiumGuide/AppiumGuide/blob/main/src/test/java/com/appiumguide/devicefarm/devicefarm_firstscriptdemo.java
Observe that user able to execute the script using Device Farm plugin
Sample Log Output:

GitHub Link:
🎬 Explore More! Watch My Latest Videos on YouTube!
Visit My Official Blog:
No comments:
Post a Comment