Proof monitoring under sql

Hello

Im trying to set up the proof monitoring with an sql server, and following the instructions

root.cern.ch/drupal/content/enab … #configsql

when I want to create the table proofquerylog on mysql

CREATE TABLE proofquerylog

the problem I find is that the following column definition

group         VARCHAR(32),

has the reserved keyword “group”. Therefore I can not create such a table.

thanks, carlos

Hi Carlos,

Reserved words can be used by adding ..., i.e. group (at least in MySQL); this needs to be documented, of course. However, there seem to be other problems with this interface.
We are investigating …

Gerri

Hi Gerri

yes, I discovered it just 5 minutos ago, at least with mysql, enclosing the reserved word between quotes (...) is permitted.

Now that I have the table in mysql, Im having troubles with the logging (local5)

With (after redirecting the local5 to /var/log/xpd.mon in the syslog)

xpd.putrc ProofServ.LogToSysLog a1

I dont get any message in the xpd.mon log file.

Looking a TProofServ.cxx: gEnv->GetValue(“ProofServ.LogToSysLog”, 0)
I had the impression that setting the resource LogToSysLog to an integer I would get something,
so trying

xpd.putrc ProofServ.LogToSysLog 1

I get some messages in the log file, but not with the format that is shown here
root.cern.ch/drupal/content/enab … monitoring

I get something like:

Aug  3 12:12:00 atltest02 proofserv[8729]: cosuna:Mst-0:SvcMsg:<TProofPlayerRemote::AddOutputObject>:Memory 102704 virtual 27568 resident after merging object h98
Aug  3 12:12:00 atltest02 proofserv[8729]: cosuna:Mst-0:SvcMsg:<TProofPlayerRemote::AddOutputObject>:Memory 102704 virtual 27572 resident after merging object h99
Aug  3 12:12:00 atltest02 proofserv[8729]: cosuna:Mst-0:Info:<TProofPlayerRemote::Finalize>:finalization on Mst-0 finished
Aug  3 12:12:37 atltest02 proofserv[8729]: cosuna:Mst-0:Info:<TXProofServ::Terminate>:starting session termination operations ...
Aug  3 12:12:37 atltest02 proofserv[8729]: cosuna:Mst-0:Info:<TXProofServ::Terminate>:process memory footprint: 113388 kB virtual, 27776 kB resident 

Maybe this is related to the problems with the interface you just mentioned, but please let me know if there is a solution, or if Im doing something wrong.

btw, Im using 5.26c

thanks, carlos

Hi Carlos,

Well, the two ways are completely decoupled … I hope this is clear.

The syslog way is not available in 5.26/00xxx (for a time this is documented … :wink:): it was introduced after 5.26/00 . But it has been ported to 5.26/00-proof, so, if you want, you can give a try from there.

The fixes/changes to the SQL way will also be ported to 5.26/00-proof .

Gerri

Hi Gerri

yes, It was clear, I was mixing two things in the same thread

uppss I missed the doc. Good, I will move then to 5.26/00-proof.

thanks Gerri,

carlos

Hi Gerri

were the fixes in the SQL monitoring applied to the proof patches?
I installed the version root_v5.26.00-proof-04

and when I activate the SQL monitoring
xpd.putrc ProofServ.Monitoring SQL mysql://localhost/proofdb proofmonuser proofquerylog

I get a crash every time a run a proof job.
Just not to continue debugging it if the problem was not still solved.

thanks, carlos

Hi Carlos,

Not yet. I could not work on this much yet, unfortunately … Also, the changes are probably going to be non-backward compatible for Monalisa (which is the only implementation really used currently; by ALICE), so I am trying to understand what is the why to minimize the impact.

In addition, I will be on holiday next 10 days, so it is likely that nothing will happen before the week of August 23rd.

Cheers, Gerri

Hi Gerri,

could you please post it here, if you manage to fix it in the 5.26-proof patches? I was just interested in the sql monitoring part, Monalisa looks like too “big” for our local proof farm, I just needed a simple accounting and from the sql database I can easily extract plots and tables with accounting and monitoring info. So it would be great If those fixes could go to the 5.26-proof branch, for we might not be ready to move to 5.27 so soon.

thanks and have a nice holidays :wink:

cheers, carlos

Hi Gerri,

well, in the end I continued debugging :slight_smile:
I suspected that the crash I was getting was somehow related to the reserved keyword “group” issue.
I thought when TSQLMonitoringWriter::SendParameters creates the sql sentence “INSERT into blabla”, it should frame the group colum name between quotes as well ``.

That was one step forward, but still I had to remove single quotes from the column name, i.e. (user) instead of (‘user’).

And finally, I noticed that someone was trying to insert data into a column named “totevents”, so I added this column to the table definition in mysql
root.cern.ch/drupal/content/enab … #configsql

With those fixes, the SQL monitoring works fine (so far) with my mysql database.
I guess all these are the issues with the sql monitoring you already detected, but just in case I leave here the patch I applied.

Hope it helps, carlos
PATCH_TSQLMonitoring.cxx (1.96 KB)