Is it possible to limit outside connections to a subdomain with .htaccess or similar?

Posted by digidave0205 on Stack Overflow See other posts from Stack Overflow or by digidave0205
Published on 2010-03-13T17:45:53Z Indexed on 2010/03/13 17:55 UTC
Read the original article Hit count: 208

Filed under:
|
|

I host a web application. This application serves static html pages that are refreshed at various intervals. Some as often as every 30 secs. At this time I have about 300 unique pages that are accessed via 300 unique subdomains. Some clients have at most 50 visitors to their unique page and it refreshes every 30 secs, no problem. Other clients have up to 1000 or more visitors to their page. These clients are killing my server.

There was no predefined limit upon signup but now I have to impose such a limit to remain afloat financially.

I would like to define a finite number of connections allowed for each individual subdomain in my hosting account. Connections attempted out of range of this finite value would either be rejected or redirected. I have access to .htaccess and php.ini. Is something of this nature possible? Oh, I have a dedicated/managed server at 1and1.

© Stack Overflow or respective owner

Related posts about htaccess

Related posts about subdomain