ATS6.2安装部署笔记

系统版本:CentOS 6.7
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>

<LogObject>
<Format = “access”/>
<Filename = “access”/>
</LogObject>

[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

原创文章,作者:赛福,如若转载,请注明出处:https://www.safecdn.cn/ats/2018/12/ats6-2-install.html

发表评论

邮箱地址不会被公开。