and put a bow on the script.
This commit is contained in:
parent
452f7df2f5
commit
2572860b30
2 changed files with 17 additions and 4 deletions
|
@ -1,13 +1,27 @@
|
|||
#!/bin/bash
|
||||
|
||||
# This file is part of Fedora Project Infrastructure Ansible
|
||||
# Repository.
|
||||
#
|
||||
# The object of this script is to combine multiple http logs from the
|
||||
# proxy servers and put them into an NFS directory where they can be
|
||||
# analyzed by other software on other systems.
|
||||
# Fedora Project Infrastructure Ansible Repository is free software:
|
||||
# you can redistribute it and/or modify it under the terms of the GNU
|
||||
# General Public License as published by the Free Software Foundation,
|
||||
# either version 3 of the License, or (at your option) any later
|
||||
# version.
|
||||
#
|
||||
# Fedora Project Infrastructure Ansible Repository is distributed in
|
||||
# the hope that it will be useful, but WITHOUT ANY WARRANTY; without
|
||||
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
|
||||
# PARTICULAR PURPOSE. See the GNU General Public License for more
|
||||
# details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with Fedora Project Infrastructure Ansible Repository. If
|
||||
# not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
# Because sync-http may not get all logs for 3 days, we only merge
|
||||
# things after 4 days.
|
||||
|
||||
NUMDAYS=4
|
||||
YEAR=$(/bin/date -d "-${NUMDAYS} days" +%Y)
|
||||
MONTH=$(/bin/date -d "-${NUMDAYS} days" +%m)
|
||||
|
@ -22,7 +36,6 @@ AWSTATS=/usr/share/awstats/tools/logresolvemerge.pl
|
|||
|
||||
FILES=$( ls -1 ${HTTPLOG}/*access.log.xz | awk '{x=split($0,a,"/"); print a[x]}' | sort -u )
|
||||
|
||||
|
||||
mkdir -p ${TARGET}
|
||||
|
||||
for FILE in ${FILES}; do
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue