Does Centova Cast include a proxy for streaming on port 80?


Does Centova Cast include a proxy for streaming on port 80 through Apache, so that users behind firewalls can still listen to streams?


Yes, the Centova Cast v2 includes a web proxy to allow visitors to tune in via port 80, however we strongly advise administrators to carefully consider the implications of deploying such a solution (or to upgrade to v3, which uses a much more efficient proxying mechanism.)

If you use a proxy script like this, because of the way Apache works, every listener connected to a stream you host will require one Apache server process for the entire time they are connected and listening. You can determine exactly how much memory each Apache process uses on your server by running ps aux and checking the RSS column for an httpd process, but usually it's somewhere between 10MB - 25MB per process.

This means that every listener connected to one of your hosted streams will be using 10-25MB of memory on your machine, in addition to the memory used by SHOUTcast. Even if your server is not very busy (say, 20 concurrent connections at any given time), that means you'll be using 200 - 500MB of RAM just for proxying. If you were to hit a slightly busier period where, say, 100 concurrent listeners were connected, that would be 1GB - 2.5GB of memory, which (unless you had 3-4GB of RAM) would cause your server to run out of memory, start swapping to disk, and likely go down.

This limitation is not specific to Centova Cast, and is true of all web-based SHOUTcast/IceCast proxy scripts written in a scripting language to run under Apache.

Proxying through Apache is supported by Centova Cast only because of the significant demand we've received for it, but we do not recommend the use of these types of scripts in general for the reasons above.

That said, proxying should not cause problems on low-volume streams, and in any event the performance of Centova Cast's proxy implementation will definitely meet or exceed those of any competing scripts you may have used.

NOTE: This article is for Centova Cast v2 only; an alternate version exists for Centova Cast v3.