goaccess achieve nginx achieve visualization log

A: goaccess module
goaccess nginx log module is directed to goaccess module in implementation, the principle is very simple, as long as there can be directed to a file, goaccess is already integrated display a page of good data, and very beautiful image. Then explain the following environments and operating procedures.
1: Install nginx, whether it is better or yum install source installation but whatever the absolute path access.log can find, yum install the path, then this is /var/log/nginx/access.log, if the source of the words is compiled, then usr local / at / / nginx is in /usr/local/nginx/logs/access.log
2: installing nginx, we must first start nginx
3: enter the ip address on the Web site can access the page displays the access nginx , the installation was successful nginx
4: install goaccess module, the first to have the source epel, if not need to go to the official website of Tsinghua copied and put /etc/yum.reops.d/epel.repo, and then execute yum -y install epel then -y install goaccess yum.
5: perform again after a successful installation vim /etc/goaccess.conf, modify the configuration file, the daemon to change into a true find daemonize False ture, then:. wq save to
6: goaccess /var/log/nginx/access.log -o /usr/share/nginx/html/goaccess.html --log- format = COMBINED --real-time-html execute this command in a shell they can. yum deployment path and source code is not the same, you need to find the following, in front access.log find the path back is to find a path to html folder
7: will show after this command is a process, on behalf of goaccess run successfully, as shown below:

8: test page, enter your ip address plus page path, you'll see this data as 192.168.86.138/goaccess.html

Guess you like

Origin www.cnblogs.com/bobo-wq/p/11513088.html
Recommended