视频缓存优化配置

把下面的配置文件加到cdnbest区域的自定义配置里

下面只配置了ts|mp4的文件扩展名,如果还需要添加其他视频文件请在下面的配置里添加,例:<acl_file_ext split='|'>ts|mp4|flv</acl_file_ext>

always_online='1'加上这个参数源挂了,还可以利用节点上的缓存访问

<!--#start 400 -->
<config>
	<request action='vhs' >
		<table name='BEGIN'>
			<chain  action='continue' >
				<acl_file_ext  split='|'>ts|mp4</acl_file_ext>
				<mark_remove_header   attr='Accept-Encoding' val='' ></mark_remove_header>
			</chain>
			<chain  action='continue' >
				<mark_flag  always_online='1' x_cache='1' via='1' x_real_ip='1' ></mark_flag>
			</chain>
		</table>
	</request>
</config>

这个命令可以查看效果

dstat --nocolor 2

 

原文地址:https://www.cnblogs.com/kangleweb/p/8058279.html