We have the following messages in the log:
2019/06/11 10:41:34.376 XXX_Locks - Col : 'Tran' does not exists in archive table. Will be ignored.
2019/06/11 10:41:34.376 XXX_Locks - Col : 'Prog' does not exists in archive table. Will be ignored.
2019/06/11 10:41:34.376 XXX_Locks - Col : 'Proc' does not exists in archive table. Will be ignored.
2019/06/11 10:41:34.377 XXX_Locks - Col : 'Line' does not exists in archive table. Will be ignored.
2019/06/11 10:41:34.377 XXX_Locks - Col : 'lckObjet' does not exists in archive table. Will be ignored.
It's due to typing errors in the configuration file Locks.xml, Node /<metricdescriptor>/<sql>. The correct syntax of teh SQL statement must be</sql></metricdescriptor>
<sql> select
"Spid"=P.spid,
"Usr"=substring(suser_name(P.suid),1,30),
"TranName"=substring(P.tran_name,1,30),
"ProgName"=substring(P.program_name,1,30),
"ProcName"=substring(object_name(P.id,P.dbid),1,30),
"LineNum"=P.linenum,</sql>
lckBase=substring(db_name(L.dbid),1,30),
lckObject=substring(object_name(L.id, L.dbid),1,30),
lckName=V.name,
NBLocks= count(*)
[...]
The wrong column names still exists in the current version (3.1.1):
<metricdescriptor>
<metricname> Locks </metricname>
<metrictype> GENERIC </metrictype>
<sql> select
"Spid"=P.spid,
"Usr"=substring(suser_name(P.suid),1,30),
"Tran"=substring(P.tran_name,1,30),
"Prog"=substring(P.program_name,1,30),
"Proc"=substring((case when P.dbid in ?ASM$ACCESSIBLEDBS? then object_name(P.id, P.dbid) else convert(varchar,P.id) end) ,1,30),
"Line"=P.linenum,</sql></metricdescriptor>
lckBase=substring(db_name(L.dbid),1,30),
lckObjet=substring((case when L.dbid in ?ASM$ACCESSIBLEDBS? then object_name(L.id, L.dbid) else convert(varchar,L.id) end),1,30),
lckName=V.name,
NBLocks= count(*)
[...]
Anonymous
Hi,
you are using the "Locks.xml" collector (I no longer use that colector) but I agree there is a mistake in it
I fixed the problem in the attached file (replace the file "Locks.xml" in your conf directory)
Best regards
Jpm