I'm using ClarkConnect Community Edition 5.0. On p. 209 of the ClarkConnect Administration Manual one finds this tantalising tidbit:
I am very interested in generating a Web Proxy > User/IP Summary report for all my network users. I have installed the MySQLserver and the phpMyAdmin modules (which seem to be required pieces of the puzzle), but I don't know what to do from there. Can anyone help me? Thanks!
Aside 1: Report > Web Proxy Report > User/IP Summary shows only, for example, 1-30 / 41 users. Is there any way to show 1-41 / 41? The most I've ever been able to see is 30 users, but I'd like to see all users.
Aside 2: Report > Web Proxy Report > User/IP Summary seems to show only download MB rather than upload and download MB. Is there any way to show both? 'Total traffic' is more significant to me than just download traffic.
Reports are created through the ClarkConnect API using a dedicated MySQL database. This
makes extraction of the report logs simple to do in the event other report medium (ie. PDF) or
statistics are required.
I am very interested in generating a Web Proxy > User/IP Summary report for all my network users. I have installed the MySQLserver and the phpMyAdmin modules (which seem to be required pieces of the puzzle), but I don't know what to do from there. Can anyone help me? Thanks!
Aside 1: Report > Web Proxy Report > User/IP Summary shows only, for example, 1-30 / 41 users. Is there any way to show 1-41 / 41? The most I've ever been able to see is 30 users, but I'd like to see all users.
Aside 2: Report > Web Proxy Report > User/IP Summary seems to show only download MB rather than upload and download MB. Is there any way to show both? 'Total traffic' is more significant to me than just download traffic.
In Database
Share this post:
Responses (8)
-
Accepted Answer
-
Accepted Answer
-
Accepted Answer
Thanks for your reply, Ben. It looks like I could have spent a lot of time going nowhere, what with two MySQLs to access... I should let you know (if you haven't figured it out already) that I'm a complete noob at this. So herewith my questions:
1. what does 'sandboxed' mean?
2. it looks like I installed the "MySQL database server" module (at least that's the one listed in my Installation History on the Services > Software Modules page). Is that the correct one? Or do I need both? I don't see another MySQL module in the Services > Software Modules list...
3. do I type "cat /etc/system/database" at a prompt on my server (is that what you mean by command line?)
4. the passwords aren't really AAAAAAAAAAAAAA, CCCCCCCCCCCCCC, DDDDDDDDDDDDD, etc., correct? But I'm guessing that's a moot point as the one I really want is reports.password. I'll try what I think I understand and see what I come up with.
5. the code to access the MySQL console that you gave would be:
/usr/share/system-mysql/usr/bin/mysql reports -ureports -pPASSWORD
correct? I've just got to substitute 'reports' for DBNAME and USER? And the password that I retrieve from /etc/system/database, of course.
Well, I'll see where this gets me and probably return to ask a few more questions. Thanks so much for the help! -
Accepted Answer
Paul,
One important piece of the puzzle that you're missing...there are actually two isolated installations of MySQL on a ClearOS box if you installed the app-mysql module. The one the web proxy uses is sandboxed.
To access the database from the command line, you will need to fetch the database password:
cat /etc/system/database
password = AAAAAAAAAAAAAAA
reports.password = PASSWORD
zoneminder.password = CCCCCCCCCCCCCCC
archive.password = DDDDDDDDDDDDD
dspam.password = EEEEEEEEEEEEEE
The proxy database password is keyed on 'reports.password'.
Next, you'll need to access the MySQL console in a slightly different manner than the default MySQL server.
/usr/share/system-mysql/usr/bin/mysql DBNAME -uUSER -pPASSWORD
Where:
DBNAME = reports
USER = reports
PASSWORD = the password retrieved from the /etc/system/database file
Hope this helps -
Accepted Answer
For web proxy reports by email, this is all I do on my servers...
1. Install calamaris-2.29-4
2. add the following line to cron using crontab -e while logged in as root..
01 2 * * * /bin/cat /var/log/squid/access.log | /bin/nice -39 calamaris -amH 'daily worf' | /bin/mail -s "Daily Squid Report - server name" userid@somedomain.com
To get the ClearOS generated mail report add the following as above...
04 05 * * * /bin/cat /var/webconfig/reports/postfix/data-yesterday.out | /bin/mail -s "Mail Report" userid@somedomain.com
Edit mail address and Serve name as required...
Note in my two examples that should all be on one line for each one, Code Tags on this Site are not working properly and wrap - which they definitely should not do...l -
Accepted Answer
-
Accepted Answer
-
Accepted Answer
Please login to post a reply
You will need to be logged in to be able to post a reply. Login using the form on the right or register an account if you are new here.
Register Here »