{ Community }
  • Academy
  • Docs
  • Developers
  • Resources
    • Community Articles
    • Apigee on GitHub
    • Code Samples
    • Videos & eBooks
    • Accelerator Methodology
  • Support
  • Ask a Question
  • Spaces
    • Product Announcements
    • General
    • Edge/API Management
    • Developer Portal (Drupal-based)
    • Developer Portal (Integrated)
    • API Design
    • APIM on Istio
    • Extensions
    • Business of APIs
    • Academy/Certification
    • Adapter for Envoy
    • Analytics
    • Events
    • Hybrid
    • Integration (AWS, PCF, Etc.)
    • Microgateway
    • Monetization
    • Private Cloud Deployment
    • 日本語コミュニティ
    • Insights
    • IoT Apigee Link
    • BaaS/Usergrid
    • BaaS Transition/Migration
    • Apigee-127
    • New Customers
    • Topics
    • Questions
    • Articles
    • Ideas
    • Leaderboard
    • Badges
  • Log in
  • Sign up

Get answers, ideas, and support from the Apigee Community

  • Home /
  • Microgateway /
avatar image
0
Question by Kristopher Kleva · Jan 04, 2016 at 09:44 PM · 664 Views microgatewayload testing

Edge Microgateway Error during Load Testing

Hello,

We've been running a series of performance tests on an array of Edge Microgateway instances load balanced using Amazon ELB.

One very consistent error I've found causing the gateways to crash appears to be be caused by the number of open file connections. Here is the error we see in the logs:

Error: EMFILE: too many open files, uv_resident_set_memory
    at Error (native)
    at /home/ec2-user/apigee-edge-micro-1.1.0/gateway/lib/logging.js:186:25
    at Array.forEach (native)
    at Object.serializeLogRecord (/home/ec2-user/apigee-edge-micro-1.1.0/gateway/lib/logging.js:149:36)
    at Object.logger.stats (/home/ec2-user/apigee-edge-micro-1.1.0/gateway/lib/logging.js:111:61)
    at null._repeat (/home/ec2-user/apigee-edge-micro-1.1.0/gateway/lib/logging.js:50:18)
    at wrapper [as _onTimeout] (timers.js:264:19)
    at Timer.unrefdHandle (timers.js:301:14)
/home/ec2-user/apigee-edge-micro-1.1.0/gateway/lib/logging.js:186
      var mem = process.memoryUsage();

The issue can be expected when running a load test and monitoring a list of open files:

lsof -i -n -P | grep node

What we find is that something with in Egde Micro appears to increase the number of open file handles until the ulimit is reached. Then this error occurs crashing the server and restarting. It appears to happen consistently when testing over 100 TPS.

Is this something unique to my installation? What can we do to prevent this kind of issue in production?

I'll attempt to increase the users ulimit -a (open files) to a higher amount than the default 1024, however is seems this would count more as a work around than a solution.

Comment
Add comment Show 1
10 |5000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by Apigeeks only
  • Viewable by the original poster
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Akhil Arora ♦ · Jan 04, 2016 at 11:06 PM 0
Link

Each http request proxied by Edge Micro will consume two fds, so a large number of concurrent or pending requests will quickly consume the default limit of 1024. Please increase the limit as @archendra says.

Close

0 Answers

  • Sort: 

Follow this Question

Answers Answers and Comments

21 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Apigee Edge Microgateway Vertical and Horizontal scaling for 1000 TPS and beyond. 3 Answers

Edgemicro intro plugin appending to response body instead of replacing 0 Answers

Transfer Edge Gateway proxys to Microgateway 2 Answers

Microgateway api key does not work, although OAuth does 1 Answer

Can we configure northbound mutual TLS for a specific Microgateway proxy? 2 Answers

  • Products
    • Edge - APIs
    • Insights - Big Data
    • Plans
  • Developers
    • Overview
    • Documentation
  • Resources
    • Overview
    • Blog
    • Apigee Institute
    • Academy
    • Documentation
  • Company
    • Overview
    • Press
    • Customers
    • Partners
    • Team
    • Events
    • Careers
    • Contact Us
  • Support
    • Support Overview
    • Documentation
    • Status
    • Edge Support Portal
    • Privacy Policy
    • Terms & Conditions
© 2021 Apigee Corp. All rights reserved. - Apigee Community Terms of Use - Powered by AnswerHub
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Create an article
  • Post an idea
  • Spaces
  • Product Announcements
  • General
  • Edge/API Management
  • Developer Portal (Drupal-based)
  • Developer Portal (Integrated)
  • API Design
  • APIM on Istio
  • Extensions
  • Business of APIs
  • Academy/Certification
  • Adapter for Envoy
  • Analytics
  • Events
  • Hybrid
  • Integration (AWS, PCF, Etc.)
  • Microgateway
  • Monetization
  • Private Cloud Deployment
  • 日本語コミュニティ
  • Insights
  • IoT Apigee Link
  • BaaS/Usergrid
  • BaaS Transition/Migration
  • Apigee-127
  • New Customers
  • Explore
  • Topics
  • Questions
  • Articles
  • Ideas
  • Badges