常用命令
作者:互联网
查询当前目录 log 文件 中含有 关键字的 文件
find . -name "*.log" | xargs grep "keywork"
nginx 日志
http{
log_format apm '[$time_local]\tclient=$remote_addr\t'
'request="$request"\t request_length=$request_length\t'
'http_referer="$http_referer"\t'
'bytes_sent=$bytes_sent\t'
'body_bytes_sent=$body_bytes_sent\t'
#'user_agent="$http_user_agent"\t'
'upstream_addr=$upstream_addr\t'
'upstream_status=$upstream_status\t'
#'cookie="$http_cookie"\t'
#'request_body="$request_body"\t'
'document_root="$document_root"\t'
'fastcgi_script_name="$fastcgi_script_name"\t'
'request_filename="$request_filename"\t'
'request_time=$request_time\t'
'upstream_response_time=$upstream_response_time\t'
'upstream_connect_time=$upstream_connect_time\t'
'upstream_header_time=$upstream_header_time\t';
access_log /opt/logs/nginx/access.log apm;
}
标签:http,log,bytes,time,request,常用命令,upstream 来源: https://www.cnblogs.com/mysgk/p/16092963.html