Install Varnish Cache in CentOS

Source: Internet
Author: User
Tags varnish automake

Install Varnish Cache RedHat/CentOS in CentOS. If you want to install varnish in RedHat/CentOS, install the following software packages: development-devellibjavastgroffpcre-develpkgconfig the following command runs yum install-y automake autoconf libtool ncurses-devel libxslt groff pcre-devel pkgconfig [root @ node18 ~] After yum Package Manager is configured. # Yum install-y automake autoconf libtool ncurses-devel libxslt groff pcre-devel pkgconfigLoaded plugins: fastestmirrorLoading mirror speeds from cached hostfile * base: Using * extras: Using * updates: mirrors. grandcloud. cnSetting up Install ProcessPackage automake-1.9.6-2.3.el5.noarch already installeds and latest versionPackage autoconf-2.59-12.noarch already inst Alled and latest release libtool-1.5.22-7.el5_4.i386 already installed and latest versionPackage ncurses-devel-5.5-24.20060715.i386 already installed and latest versionPackage libxslt-1.1.17-4.el5_8.3.i386 already installed and latest versionPackage groff-1.18.1.1-13.el5.i386 already installed and latest release pcre-devel-6.6-6.el5_6.1.i386 already installed and latest Pkgconfig-0.21-2.el5.i386 already installed and latest versionNothing to do [root @ node18 ~] # Download varnish source code and compile and install mkdir varnish_setupcd varnish_setup/wget http://repo.varnish-cache.org/source/varnish-2.1.5.tar.gztar zxf varnish-2.1.5.tar.gzcd varnish-2.1.5. /autogen. sh. /configure -- prefix =/usrmakmcm bin/varnishtest &&. /varnishtest tests /*. vtc # <= This step is time-consuming and can be omitted cd .. /.. # <== if a test is executed, otherwise, install make install. Note: the installation in this article is different from the default installation. varnishd will be installed in the/usr/sbin/varnishd configuration file/usr/etc/varnish/default. vcl is installed below Detailed record: [root @ node18 ~] # Mkdir varnish_setup [root @ node18 ~] # Cd varnish_setup/[root @ node18 varnish_setup] # wget http://repo.varnish-cache.org/source/varnish-2.1.5.tar.gz--2012-11-20 10:23:32 -- guest repo.varnish-cache.org... 194.31.39.155Connecting to repo.varnish-cache.org | 194.31.39.155 |: 80... connected. An HTTP request has been sent and is waiting for response... 200 OK length: 1530856 (1.5 M) [application/x-gzip] Saving: 'varnish-2.1.5.tar.gz '100% [================================== ==>] 1,530,856 51.2 K/s in 20 s 10:23:53 (73.2 KB/s) -'varnish-2.1.5.tar.gz 'saved [1530856/1530856] [root @ node18 varnish_setup] # [root @ node18 varnish_setup] # tar zxf varnish-2.1.5.tar.gz [root @ node18 varnish_setup] # cd varnish-2.1.5 [root @ node18 varnish -2.1.5] # lsaclocal. m4 config. guess depcomp install-sh Makefile. in varnishapi. pc. inautogen. sh config. h. in doc lib manbin config. sub etc LICENSE missingChangeLog configure include ltmain. sh READMEcompile configure. ac INSTALL Makefile. am redhat [root @ node18 varnish-2.1.5] # [root @ node18 varnish-2.1.5] #. /autogen. sh + aclocal + libtoolize -- copy -- force + autoheader + automake -- add-missing -- copy -- foreign + autoconf [root @ node18 varnish-2.1.5] #. /configure -- prefix =/usrchecking build system type... i686-redhat-linux-gnuchecking host system type... i686-redhat-linux-gnuchecking target system type... i686-redhat-linux-gnuchecking for a BSD-compatible install... /usr/bin/install-cchecking whether build environment is sane... yeschecking for gawk... gawkchecking whether make sets $ (MAKE )... yeschecking for gcc... gccchecking for C compiler default output file name... a. outchecking whether the C compiler works... yes... configure: creating. /config. statusconfig. status: creating Makefileconfig. status: creating bin/Makefileconfig. status: creating bin/varnishadm/Makefileconfig. status: creating bin/varnishd/Makefileconfig. status: creating bin/varnishlog/Makefileconfig. status: creating bin/varnishhist/Makefileconfig. status: creating bin/varnishncsa/Makefileconfig. status: creating bin/varnishreplay/Makefileconfig. status: creating bin/varnishstat/Makefileconfig. status: creating bin/varnishsizes/Makefileconfig. status: creating bin/varnishtest/Makefileconfig. status: creating bin/varnishtop/Makefileconfig. status: creating doc/Makefileconfig. status: creating doc/sphinx/Makefileconfig. status: creating etc/Makefileconfig. status: creating include/Makefileconfig. status: creating lib/Makefileconfig. status: creating lib/libvarnish/Makefileconfig. status: creating lib/libvarnishapi/Makefileconfig. status: creating lib/libvarnishcompat/Makefileconfig. status: creating lib/libvcl/Makefileconfig. status: creating lib/libjemalloc/Makefileconfig. status: creating man/Makefileconfig. status: creating redhat/Makefileconfig. status: creating varnishapi. pcconfig. status: creating config. hconfig. status: executing depfiles commands [root @ node18 varnish-2.1.5] # makemake all-recursivemake [1]: entering directory '/root/varnish_setup/varnish-2.1.5' Making all in your demake [2]: Entering directory '/root/varnish_setup/varnish-2.1.5/include 'make [2]: nothing to be done for 'all '. make [2]: Leaving directory '/root/varnish_setup/varnish-2.1.5/include 'Making all in libmake [2]: entering directory '/root/varnish_setup/varnish-2.1.5/lib 'Making all in libvarnishcompatmake [3]: entering directory '/root/varnish_setup/varnish-2.1.5/lib/libvarnishcompat' if/bin/sh .. /.. /libtool -- tag = CC -- mode = compile gcc-DHAVE_CONFIG_H-I. -I. -I .. /.. -I .. /.. /include-g-O2-MT daemon. lo-MD-MP-MF ". deps/daemon. tpo "-c-o daemon. lo daemon. c; \ then mv-f ". deps/daemon. tpo "". deps/daemon. plo "; else rm-f ". deps/daemon. tpo "; exit 1; fimkdir. libs gcc-DHAVE_CONFIG_H-I. -I. -I .. /.. -I .. /.. /include-g-O2-MT daemon. lo-MD-MP-MF. deps/daemon. tpo-c daemon. c-fPIC-DPIC-o. libs/daemon. o... mkdir. libsgcc-g-O2-o. libs/varnishsizes. o .. /.. /lib/libvarnish /. libs/libvarnish. so-lrt-lnsl .. /.. /lib/libvarnishcompat /. libs/libvarnishcompat. so .. /.. /lib/libvarnishapi /. libs/libvarnishapi. so-lpcre-lm-lcurses-lpthread creating varnishsizesmake [3]: Leaving directory '/root/varnish_setup/varnish-2.1.5/bin/varnishsizes' make [3]: entering directory '/root/varnish_setup/varnish-2.1.5/bin' make [3]: Nothing to be done for 'all-am '. make [3]: Leaving directory '/root/varnish_setup/varnish-2.1.5/bin' make [2]: leaving directory '/root/varnish_setup/varnish-2.1.5/bin' Making all in manmake [2]: entering directory '/root/varnish_setup/varnish-2.1.5/man' make [2]: Nothing to be done for 'all '. make [2]: Leaving directory '/root/varnish_setup/varnish-2.1.5/man' Making all in etcmake [2]: entering directory '/root/varnish_setup/varnish-2.1.5/etc' make [2]: Nothing to be done for 'all '. make [2]: Leaving directory '/root/varnish_setup/varnish-2.1.5/etc' Making all in docmake [2]: entering directory '/root/varnish_setup/varnish-2.1.5/doc 'Making all in sphinxmake [3]: entering directory '/root/varnish_setup/varnish-2.1.5/doc/sphs' make [3]: Nothing to be done for 'all '. make [3]: Leaving directory '/root/varnish_setup/varnish-2.1.5/doc/sphinx' make [3]: entering directory '/root/varnish_setup/varnish-2.1.5/doc 'make [3]: Nothing to be done for 'all-am '. make [3]: Leaving directory '/root/varnish_setup/varnish-2.1.5/doc 'make [2]: leaving directory '/root/varnish_setup/varnish-2.1.5/doc 'Making all in redhatmake [2]: entering directory '/root/varnish_setup/varnish-2.1.5/redhat' make [2]: Nothing to be done for 'all '. make [2]: Leaving directory '/root/varnish_setup/varnish-2.1.5/redhat 'make [2]: entering directory '/root/varnish_setup/varnish-2.1.5' make [2]: Nothing to be done for 'all-am '. make [2]: Leaving directory '/root/varnish_setup/varnish-2.1.5 'make [1]: leaving directory '/root/varnish_setup/varnish-100' [root @ node18 varnish-2.1.5] # [root @ node18 varnish-2.1.5] # cd bin/varnishtest &&. /varnishtest tests /*. vtc # top TEST tests/a00000.vtc passed (0.001 s) # top TEST tests/a00001.vtc passed (0.001 s) # top TEST tests/a00002.vtc passed (0.001 s) # top TEST tests/a00003.vtc passed (0.001 s) # top TEST tests/a00004.vtc passed (0.001 s) # top TEST tests/a00005.vtc passed (0.001 s) # top TEST tests/a00006.vtc passed (0.001 s) # top TEST tests/a00007.vtc passed (0.001 s) # top TEST tests/a00008.vtc passed (1.806 s) # top TEST tests/a00009.vtc passed (0.256 s) # top TEST tests/a00010.vtc passed (0.002 s) # top TEST tests/b00000.vtc passed (0.757 s) # top TEST tests/b00001.vtc passed (0.675 s) # top TEST tests/b00002.vtc passed (0.683 s )... # top TEST tests/v00023.vtc passed (0.575 s) # top TEST tests/v00024.vtc passed (0.587 s) # top TEST tests/v00025.vtc passed (0.673 s) # top TEST tests/v00026.vtc passed (0.590 s) # top TEST tests/v00028.vtc passed (0.581 s) # top TEST tests/v00029.vtc passed (1.310 s) # top TEST tests/v00030.vtc passed (0.585 s) # top Slowest test: tests/p00005.vtc 8.022 s # top Total tests run: 196 # top Total duration: 204.346 s [root @ node18 varnishtest] # [root @ node18 varnishtest] # cd .. /.. [root @ node18 varnish-2.1.5] # make installMaking install in your demake [1]: Entering directory '/root/varnish_setup/varnish-2.1.5/include 'make [2]: entering directory '/root/varnish_setup/varnish-2.1.5/include 'make [2]: Nothing to be done for 'Install-exec-am '. test-z "/usr/include/varnish" | mkdir-p -- "/usr/include/varnish"/usr/bin/install-c-m 644 'shmlog. h''/usr/include/varnish/shmlog. h'/usr/bin/install-c-m 644 'shmlog _ tags. h''/usr/include/varnish/shmlog_tags.h'/usr/bin/install-c-m 644 'stat _ field. h''/usr/include/varnish/stat_field.h'/usr/bin/install-c-m 644 'stats. h''/usr/include/varnish/stats. h'/usr/bin/install-c-m 644 'varnishapi. h''/usr/include/varnish/varnishapi. h'make [2]: Leaving directory '/root/varnish_setup/varnish-2.1.5/include 'make [1]: leaving directory '/root/varnish_setup/varnish-2.1.5/include 'making install in lib... making install in redhatmake [1]: Entering directory '/root/varnish_setup/varnish-2.1.5/redhat 'make [2]: entering directory '/root/varnish_setup/varnish-2.1.5/redhat' make [2]: Nothing to be done for 'Install-exec-am '. make [2]: Nothing to be done for 'Install-data-am '. make [2]: Leaving directory '/root/varnish_setup/varnish-2.1.5/redhat 'make [1]: leaving directory '/root/varnish_setup/varnish-2.1.5/redhat' make [1]: Entering directory '/root/varnish_setup/varnish-2.1.5' make [2]: entering directory '/root/varnish_setup/varnish-2.1.5' make [2]: Nothing to be done for 'Install-exec-am '. /root/varnish_setup/varnish-2.1.5/install-sh-d-m 0755/usr/var/varnishtest-z "/usr/lib/pkgconfig" | mkdir-p --" /usr/lib/pkgconfig "/usr/bin/install-c-m 644 'varnishapi. pc ''/usr/lib/pkgconfig/varnishapi. pc 'make [2]: Leaving directory '/root/varnish_setup/varnish-2.1.5 'make [1]: leaving directory '/root/varnish_setup/varnish-100' [root @ node18 varnish-2.1.5] # [root @ node18 varnish-2.1.5] # whereis varnishvarnish: /usr/etc/varnish/usr/include/varnish [root @ node18 varnish-2.1.5] # whereis varnishdvarnishd: /usr/sbin/varnishd/usr/man/man1/varnishd.1 [root @ node18 varnish-2.1.5] # ls/usr/etc/varnish/default. vcl/usr/etc/varnish/default. vcl [root @ node18 varnish-2.1.5] #

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.