GroupOffice logging

Talk about anything that doesn't fit in the other catagories :) (and of course is about Group-Office)

Moderator: Developers

DanielMalmgren
Posts: 167
Joined: Fri Oct 28, 2011 6:24 pm
Location: Kisa, Sweden

GroupOffice logging

Postby DanielMalmgren » Thu Feb 07, 2013 11:19 am

Hi.
GroupOffice logs an insane amount of data to go_log in the database. Our complete GO database is right now 1.8GB, go_log is 1.5GB of this. A couple of questions relating to this:

1. Is it really needed to log this much? It seems one single activesync session can spawn hundreds of identical log lines for just one sync, why is this?

2. Is there any good way of removing old stuff from the log? We don't really need to keep this information for ever and ever. Is this just a question of a "delete from go_log where ctime < something" in the database?

3. Is there any chance of the searching capabilities in GO being improved? There is no point in having a log if you can't simply get out what you want from it. For example getting a list of all occurances when Jane Doe logged in last month seems impossible right now using only the web interface.

/Daniel

edit: Forgot to mention, according to our investigation go_log stands for about 75% of the total load on our mysql server...
rosetta
Group-Office Expert
Group-Office Expert
Posts: 546
Joined: Tue Jul 14, 2009 2:25 pm
Location: Norway
Contact:

Re: GroupOffice logging

Postby rosetta » Thu Feb 07, 2013 11:55 am

rosetta
Group-Office Expert
Group-Office Expert
Posts: 546
Joined: Tue Jul 14, 2009 2:25 pm
Location: Norway
Contact:

Re: GroupOffice logging

Postby rosetta » Thu Feb 07, 2013 11:58 am

Also, on my phone ActiveSync seems to sync contacts simply because I have called them.

So if I call a contact from my phone, and then sync it - the contact is "updated" in GO and result in a log entry. Even though the contact data has not changed.
DanielMalmgren
Posts: 167
Joined: Fri Oct 28, 2011 6:24 pm
Location: Kisa, Sweden

Re: GroupOffice logging

Postby DanielMalmgren » Thu Feb 07, 2013 12:12 pm

eagle wrote:Have you considered this?

http://wiki4.group-office.com/wiki/Activity_log
Ah, thanks. Guess that answers my question 2. I don't dare trying this during office hours, guess I'll have to try tonight...

/Daniel
DanielMalmgren
Posts: 167
Joined: Fri Oct 28, 2011 6:24 pm
Location: Kisa, Sweden

Re: GroupOffice logging

Postby DanielMalmgren » Mon Mar 18, 2013 11:52 am

I'd hoped to get some input from Intermesh on this one. Since I (naturally) forgot to do anything about the log rotating, today our mysql server turned out of disk. Now go_log is 5.5 GB.

I've also looked a bit at exactly WHAT in the log actually uses up all that space. Some numbers:

Code: Select all

mysql> select count(*) from go_log;
+----------+
| count(*) |
+----------+
| 42557820 |
+----------+
1 row in set (0.00 sec)

mysql> select count(*) from go_log where action = 'update';
+----------+
| count(*) |
+----------+
| 41731378 |
+----------+
1 row in set (25.85 sec)

mysql> select count(*) from go_log where action = 'update' and (model = 'GO_Base_Model_User' or model = 'GO_Addressbook_Model_Contact');
+----------+
| count(*) |
+----------+
| 41333819 |
+----------+
1 row in set (39.84 sec)
Seems like actually the sync of contacts using activesync is the big issue here (with 97% of all lines in the log) if I'm not misunderstanding. Is it really that interesting knowing every time a user syncs a contact to and from their phone?

Sorry for whining here, but since I can't even look at the code for the z-push backend I can't really do anything about it myself and the log function is really useless as it is now.

/Daniel
mschering
Site Admin
Site Admin
Posts: 8333
Joined: Tue Apr 20, 2004 1:06 pm
Location: The Netherlands - Den Bosch
Contact:

Re: GroupOffice logging

Postby mschering » Wed Mar 20, 2013 8:01 am

Any save and delete action is logged. IMHO that is useful. But the rotation should have been setup by default.

With debian packages /etc/cron.d/groupoffice-log is created by default. For manual installs take a look at modules/log/README.TXT
Best regards,

Merijn Schering
Intermesh
rosetta
Group-Office Expert
Group-Office Expert
Posts: 546
Joined: Tue Jul 14, 2009 2:25 pm
Location: Norway
Contact:

Re: GroupOffice logging

Postby rosetta » Wed Mar 20, 2013 8:14 am

One issue, at least the last time I looked into this, is that simply calling a person on the phone makes Z-push think that the contact has "changed" and it will be synced.

So if you have called or received a call from 30 contacts all of those will be "updated" in GO - even though none of their fields have been changed.

In the GO log module, the contact is shown as "updated" (but all fields in GO are the same).
mschering
Site Admin
Site Admin
Posts: 8333
Joined: Tue Apr 20, 2004 1:06 pm
Location: The Netherlands - Den Bosch
Contact:

Re: GroupOffice logging

Postby mschering » Wed Mar 20, 2013 8:53 am

The logging module is not so smart that it can detect that. It just logs save actions.
Best regards,

Merijn Schering
Intermesh

Who is online

Users browsing this forum: No registered users and 2 guests

cron