I have a video website running on a VPS under Apache2 that will soon start doing pay per view. Until it starts generating decent revenue, I don't want to invest in more servers, so to start with I need to provide a good enough service to the customers I get.
I also host a couple of other websites, but these aren't expected to use a lot of bandwidth.
I know that my major bottleneck is bandwidth - so I think the best thing to do is to prevent access to the video site to new connections once my bandwidth limit gets near. Anyone who is already viewing a movie should not be affected.
Any ideas on the best way to achieve this?
Update: The bandwidth limitation isn't my allocated bandwidth from the provider but rather the available bandwidth for my VPS through the network card. I found that once I hit about 250 simultaneous downloads things start to deteriorate. Assuming each download is at 1mbps I want to start throttling things once I hit 250mbps - in theory I can get 1000mbps, but it doesn't look like that really works.