in Crash Course, Interesting, Performance

Litespeed and Varnish Plugin on a cPanel WHM server

 Update (2013/02/07): We’ve released a Varnish Litespeed Plugin for cPanel WHM

Litespeed users on cPanel WHM servers are realizing the benefits of running Varnish Cache in front of Litespeed to improve performance. While we (UNIXy) don’t officially provide support to subscribers running the cPanel Varnish Plugin with Litespeed, it does work with only a few extra manual steps. Keep in mind that we support this configuration for our fully managed VPS, dedicated server, and cluster clients free of charge. If you are a current client and need this configured, please open a ticket request. We’ll be happy to assist with this task.

In this post, I’m going to list the steps required to pair the cPanel Varnish Plugin with Litespeed on cPanel WHM servers. These few procedures apply to a blank cPanel installation (no Litespeed, no Varnish Plugin). The order below is important so don’t skip!

  • 1. Configure your Apache / PHP with the desired options and extentions. Let EasyApache finish the build.
  • 2. Install Litespeed using the command line installer with the port offset at 2000 (default).
  • 3. From WHM -> Litespeed -> Build Matching PHP binaries. Let the Litespeed builder complete before proceeding.
  • 4. Proceed with installing the cPanel Varnish Plugin. Let it complete.
  • 5. Set the Litespeed Port offset to zero in Admin Console.
  • 6. In Admin Console, Configuration -> Server -> General Settings -> Use Client IP in header -> Yes. Restart Litespeed.



UNIXY is a long-time Varnish Cache user and evangelist. They have been offering Varnish acceleration to their clients for more than three years. They have released the first cPanel Varnish plugin as well as spun a new startup, Fastlayer, the on-demand HTTP accelerator for the cloud.

That’s all folks! I hope you find this useful.