macOS 下 GoAccess 踩坑

2022-03-01 680 0

安装好 GoAccess 后, 即便设置好日志时间格式, 还是会报错.
经过查找后发现是 Mac 用户需要声明 LANG

命令参考:
LANG="en_US.UTF-8" goaccess --no-global-config --log-format='%h - %^ [%d:%t %^] "%m %U %H" %s %b "%R" "%u" %^ "%v" "%^" %Dms' --date-format='%d/%b/%Y' --time-format='%T' --log-file=./xxxx.log --output=./xxxx.html

macOS 下 goaccess.conf 路径 1.5.5 版本为例:
/usr/local/Cellar/goaccess/1.5.5/etc/goaccess

LANG="en_US.UTF-8" goaccess xxx.log -o report.html --log-format=COMBINED
LANG="en_US.UTF-8" goaccess xxx.log -o report02.html

感谢:
https://soulteary.com/2020/12/16/log-analysis-and-processing-goaccess.html
https://www.escapelife.site/posts/df48f637.html

相关文章

彻底删除docker
宝塔安装 nginx 失败
Ubuntu 安装 GUI 及远程桌面 Xrdp
甲骨文(Oracle Linux)手动扩容命令
ServerStatus 感觉不错, 记录一下配置过程
Centos7 防火墙管理