[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#403598: gnump3d-top produces wrong statistics when --logfiles option is used.



Package: gnump3d
Version: 2.9.9.9-2

When I activate the option
   --logfiles=/var/log/gnump3d/access.log*
in /etc/gnump3d/gnump3d.conf to enable statistics on all log files processed by logrotate, the "View the most recent tracks served." web page displays wrong statistics.

Here you can show this webpage in the described situation :
$gnump3d-top --last --logfiles=/var/log/gnump3d/access.log*  | head -n 3
<tr><td><b>Host</b></td><td><b>Time</b></td><td><b>Song</b></td></tr>
<tr><td>AReims-157-1-105-208.w90-7.abo.wanadoo.fr</td><td>04/Nov/2006:11:10:24 </td><td><a href="/nonmetal/Herman Düne/Herman Düne - Giant/07. take me back to NYC.mp3.m3u">/nonmetal/Herman Düne/Herman Düne - Giant/07. take me back to NYC.mp3</a></td></tr> <tr><td>AReims-157-1-105-208.w90-7.abo.wanadoo.fr</td><td>04/Nov/2006:11:09:21 </td><td><a href="/nonmetal/Herman Düne/Herman Düne - Giant/16.Mrs Bigger.mp3.m3u">/nonmetal/Herman Düne/Herman Düne - Giant/16.Mrs Bigger.mp3</a></td></tr>

You can see that most recent listened files seems to have been listening on 04/Nov/2006. It is not true.
If I search in log files :
$for i in /var/log/gnump3d/access.log*gz; do if zcat $i | grep -q "04/Nov"; then echo $i; fi; done
/var/log/gnump3d/access.log.44.gz      <---- contains log of november 2005
/var/log/gnump3d/access.log.7.gz        <---- contains log of november 2006

You can see that these "most recent tracks served" come from access.log.7.gz. And of course between 04/Nov/2006 and today (18/Dec/2006) there are more recent listened files that should appear in "View the most recent tracks served.", logged in files between access.log.7.gz and access.log


Maybe an interesting point : if I write myself the 10 most recent files, the output is good $gnump3d-top --last -logfiles=/var/log/gnump3d/access.log /var/log/gnump3d/access.log.1 /var/log/gnump3d/access.log2.gz /var/log/gnump3d/access.log3.gz /var/log/gnump3d/access.log4.gz /var/log/gnump3d/access.log5.gz /var/log/gnump3d/access.log6.gz /var/log/gnump3d/access.log7.gz /var/log/gnump3d/access.log8.gz /var/log/gnump3d/access.log9.gz | head -n 3
<tr><td><b>Host</b></td><td><b>Time</b></td><td><b>Song</b></td></tr>
<tr><td>c2fa9614.adsl.oleane.fr</td><td>18/Dec/2006:10:09:39 </td><td><a href="/nonmetal/Iggy Pop-In the Death Car.mp3.m3u">/nonmetal/Iggy Pop-In the Death Car.mp3</a></td></tr> <tr><td>c2fa9614.adsl.oleane.fr</td><td>18/Dec/2006:10:09:39 </td><td><a href="/nonmetal/Iggy Pop-In the Death Car.mp3.m3u">/nonmetal/Iggy Pop-In the Death Car.mp3</a></td></tr>

And if I use pattern, output is bad :
$gnump3d-top --last --logfiles=/var/log/gnump3d/access.log.[0-9].gz | head -n 3
<tr><td><b>Host</b></td><td><b>Time</b></td><td><b>Song</b></td></tr>
<tr><td>AReims-157-1-105-208.w90-7.abo.wanadoo.fr</td><td>04/Nov/2006:11:10:24 </td><td><a href="/nonmetal/Herman Düne/Herman Düne - Giant/07. take me back to NYC.mp3.m3u">/nonmetal/Herman Düne/Herman Düne - Giant/07. take me back to NYC.mp3</a></td></tr> <tr><td>AReims-157-1-105-208.w90-7.abo.wanadoo.fr</td><td>04/Nov/2006:11:09:21 </td><td><a href="/nonmetal/Herman Düne/Herman Düne - Giant/16.Mrs Bigger.mp3.m3u">/nonmetal/Herman Düne/Herman Düne - Giant/16.Mrs Bigger.mp3</a></td></tr>


System is Debian GNU/Linux Etch (last upgrade done after frozen), kernel 2.6.8-3-k7-smp, libc6 2.3.6.ds1-8





Reply to: