0

Is it possible to drop excessive connections on per port basis?

Let's say I 've multiple virtual hosts in Nginx listening on different ports. I want to set different rules for different ports.

For eg. If port 8000 gets more than 1000 connections/sec, drop the rest of the requests without harming the limit of open file count

1 Answer 1

0

You can create a new limit_req zone on each port/listen aka server block.

And define different values on each zone.

https://www.nginx.com/blog/rate-limiting-nginx/

https://medium.freecodecamp.org/nginx-rate-limiting-in-a-nutshell-128fe9e0126c

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .