Varnish是一款高性能的开源HTTP加速器,挪威最大的在线报纸 Verdens Gang 使用3台Varnish代替了原来的12台Squid,性能比以前更好。
Varnish 的作者Poul-Henning Kamp是FreeBSD的内核开发者之一,他认为现在的计算机比起1975年已经复杂许多。在1975年时,储存媒介只有两种:内存与硬盘。但现在计算机系统的内存除了主存外,还包括了CPU内的L1、L2,甚至有L3快取。硬盘上也有自己的快取装置,因此Squid Cache自行处理物件替换的架构不可能得知这些情况而做到最佳化,但操作系统可以得知这些情况,所以这部份的工作应该交给操作系统处理,这就是 Varnish cache设计架构。

下面为FREEBSD UNIX安装VARNISH的过程,VARNISH的具体配置过程,以会陆续发布在本博客,敬请期待。

gmake[1]: Leaving directory ‘/usr/ports/www/varnish5/work/varnish-cache-varnish-5.1.3’

====> Compressing man pages (compress-man)

===> Staging rc.d startup script(s)

===>  Installing for varnish5-5.1.3

===>  Checking if varnish5 already installed

===>   Registering installation for varnish5-5.1.3

Installing varnish5-5.1.3…

===> Creating groups.

Creating group ‘varnish’ with gid ‘429’.

===> Creating users

Creating user ‘varnish’ with uid ‘429’.

Creating user ‘varnishlog’ with uid ‘430’.



It’s two in the morning and someone posted a link to your website on

slashdot.  Don’t panic, it takes only a minute to set up Varnish in

front of your web server:

1) Install Varnish

2) Reconfigure your web server to listen on localhost:8080

3) sysrc varnishd_enable=YES

4) service varnishd start


Refer to the documentation for more advanced configuration.



This port has installed the following files which may act as network

servers and may therefore pose a remote security risk to the system.




This port has installed the following startup scripts which may cause

these network services to be started at boot time.





If there are vulnerabilities in these programs there may be a security

risk to the system. FreeBSD makes no guarantee about the security of

ports included in the Ports Collection. Please type ‘make deinstall’

to deinstall the port if this is a concern.


For more information, and contact details about the security

status of this software, see the following webpage:

===>  Cleaning for varnish5-5.1.3

root@wiz:/usr/ports/www/varnish5 # pwd


root@wiz:/usr/ports/www/varnish5 # make install clean






邮箱地址不会被公开。 必填项已用*标注