ATS6.2安裝部署筆記

1.安裝依賴包
yum -y install git gcc gcc-c++ autoconf automake libtool pkgconfig pcre-devel tcl-devel expat-devel openssl-devel xz-devel boost-devel
yum -y install perl-ExtUtils-MakeMaker
yum -y install libcap libcap-devel hwloc hwloc-devel
yum -y install libunwind libunwind-devel
更新yum源安裝
yum install -y epel-release
yum -y install curl curl-devel
yum -y install ncurses  ncurses-devel
 
2.下載源碼包並安裝
tar -jxvf trafficserver-6.2.0.tar.bz2
cd trafficserver-6.2.0
./configure –prefix=/usr/local/ats –enable-example-plugins –enable-experimental-plugins
autoreconf -i
make -j 4
make install
3.下面是相應配置
[records.config]
CONFIG proxy.config.http.server_ports STRING 8080
CONFIG proxy.config.http2.enabled INT 0
CONFIG proxy.config.http.insert_response_via_str INT 2
CONFIG proxy.config.log.custom_logs_enabled INT 1
CONFIG proxy.config.log.xml_config_file STRING logs_xml.config
CONFIG proxy.config.diags.show_location INT 1
CONFIG proxy.config.http.parent_proxy_routing_enable INT 1
CONFIG proxy.config.http.no_dns_just_forward_to_parent INT 1
CONFIG proxy.config.body_factory.template_sets_dir STRING etc/trafficserver/body_factory
CONFIG proxy.config.cache.control.filename STRING cache.config
 
#no ssl and cpu affinity
CONFIG proxy.config.ssl.number.threads INT 0
CONFIG proxy.config.exec_thread.affinity INT 0
 
[remap.config]
regex_map http://(.*) http://$1
 
[logs_xml.config]
 

<LogFormat>
<Name = 「access」/>
<Format = 「%<chi> %<cqtq> %<ttms> %<{X-Forwarded-For}cqh> %
<crc>/%<pssc> %<pscl> %<cqhm> %<cquuc> %<cqhv> %<phr>/%<pqs
i> %<psct> \」%<{Referer}cqh>\」 \」%<{User-Agent}cqh>\」 %<shn
> %<sscl>」/>
</LogFormat>html

<LogObject>
<Format = 「access」/>
<Filename = 「access」/>
</LogObject>node

 
[storage.config]
var/trafficserver 4G
 
[root@node-5-153 trafficserver]# /usr/local/ats/bin/trafficserver restart
 
[root@node-5-153 trafficserver]# tail -f /usr/local/ats/var/log/trafficserver/access.log
10.0.5.153 1543982432.135 0 10.0.5.152 TCP_MEM_HIT/200 13 GET http://www.a.com/ HTTP/1.0 NONE/0 text/html 「-」 「Wget/1.12 (linux-gnu)」 www.a.com 0
相關文章
相關標籤/搜索