wget -c http://repo.varnish-cache.org/source/varnish-3.0.1.tar.gz
tar xzvf varnish-3.0.1.tar.gz
cd varnish-3.0.1
./configure --prefix=/usr/local/varnish
make
make install
groupadd varnish
useradd -d /var/lib/varnish -g varnish -s /sbin/nologin varnish
ln -s /usr/local/varnish/sbin/varnishd /usr/sbin/varnishd
如果在make的时候报错 No package 'libpcre' found 可以安装 yum -y install pcre-devel