Web Service Load Testing with Yandex.Tank

Overview

Yandex.Tank is a powerful, easy-to-configure tool for performance testing web services and applications. Our VMware Cloud Director template "Yandex Tank" provides a ready-to-use environment capable of generating:

  • Tens to hundreds of thousands of HTTP/HTTPS requests per second

  • Support for GET and POST methods

  • Detailed performance metrics and reporting

Setup Instructions

1. Deploy the Virtual Machine

  1. In VMware Cloud Director, select the "Yandex Tank" template from the public directory

  2. Default VM configuration:

    • CPU: 2 cores

    • RAM: 1GB

    • Storage: 15GB

    • OS: Ubuntu Server 20.04

    • Network: "IP pool" mode (automatic address assignment)

2. Configure the Test Parameters

Edit the configuration file located at /opt/yandex_tank/load.yml:

nano /opt/yandex_tank/load.yml

Key Configuration Parameters:

overload:
  enabled: false # Set true to enable Yandex report dashboard
  token_file: "/opt/yandex_tank/token.txt" # Yandex API token location

phantom:
  address: example.com:443 # Target [address]:[port]
  ssl: false # Set true for HTTPS testing
  headers:
   - "[User-Agent: Mozilla/5.0 (Windows NT 10.0...)]"
   - Host: example.com
   - Connection: close
  uris:
   - / # Tested endpoints (add more as needed)
  load_profile:
   load_type: rps # Requests per second method
   schedule: line(1, 50, 30s) # Ramp from 1 to 50 RPS over 30 seconds

Running the Test

Execute the test with:

yandex-tank -c /opt/yandex_tank/load.yml

  

Key Metrics to Analyze

  1. Summary Statistics:

    • count: Total requests (e.g., 6911)

    • net_e: Network errors (0 is ideal)

    • http_e: HTTP errors (0 is ideal)

    • avg ms: Average response time (e.g., 4.1ms)

  2. HTTP Status Codes:

    • Successful requests show code 200

    • Other codes indicate issues (404, 500, etc.)

  3. Response Time Percentiles:

    • Shows what percentage of requests completed within certain times

    • Example: 100% < 31ms, 50% < 3.3ms

Performance Considerations

  • Increased request volume typically leads to:

    • Longer processing times

    • Potential request queuing

    • Possible timeouts (code 110)

  • Adjust schedule parameters gradually to find breaking points

Optimization Tips

  1. Start with conservative load profiles

  2. Monitor for network/http errors

  3. Gradually increase load to identify performance thresholds

  4. Compare results across different test runs

This template provides an efficient way to identify performance bottlenecks and optimize your web service's capacity. For complex scenarios, consider adjusting the load profile or adding more test URIs.

 

 

Have you tried Cloud4U services? Not yet?

Visit Website

Try for free

  • 37 Users Found This Useful
Was this answer helpful?

Related Articles

Performance of enterprise web applications in Docker containers on VMware vSphere 6.5

Docker containers are becoming more and more popular as a deployment platform for enterprise...