Freebsd11安裝varrish記錄

Varnish是一款高性能的開源HTTP加速器,挪威最大的在線報紙 Verdens Gang 使用3台Varnish代替了原來的12台Squid,性能比以前更好。
Varnish 的作者Poul-Henning Kamp是FreeBSD的內核開發者之一,他認為現在的計算機比起1975年已經複雜許多。在1975年時,儲存媒介只有兩種:內存與硬碟。但現在計算機系統的內存除了主存外,還包括了CPU內的L1、L2,甚至有L3快取。硬碟上也有自己的快取裝置,因此Squid Cache自行處理物件替換的架構不可能得知這些情況而做到最佳化,但操作系統可以得知這些情況,所以這部份的工作應該交給操作系統處理,這就是 Varnish cache設計架構。
varnish項目是2006年發布的第一個版本0.9.距今已經有十多年,經過varnish開發團隊和網友們的辛苦耕耘,現在的varnish已經很健壯。很多門戶網站已經部署了varnish,並且反應都很好,甚至反應比squid還穩定,且效率更高,資源佔用更少。相信在反向代理,web加速方面,varnish已經有足夠能力代替squid。

下面為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’.

QUICK-START GUIDE

 

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.

 

===> SECURITY REPORT:

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

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

/usr/local/sbin/varnishd

/usr/local/bin/varnishtest

 

This port has installed the following startup scripts which may cause

these network services to be started at boot time.

/usr/local/etc/rc.d/varnishncsa

/usr/local/etc/rc.d/varnishd

/usr/local/etc/rc.d/varnishlog

 

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:

http://www.varnish-cache.org/

===>  Cleaning for varnish5-5.1.3

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

/usr/ports/www/varnish5

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

 

 

以下文章點擊率最高

Loading…

     

如果這文章對你有幫助,請掃左上角微信支付-支付寶,給於打賞,以助博客運營