How to enable and read QueryService auditing
How To
Summary
Describes how to enable QueryService auditing and the information that QueryService audit records provide.
Environment
This document describes QueryService audit for CA 12.0.4. However, it should help understand similar audits for previous
CA versions.
Steps
First read this IBM documents to learn how to get to the logging properties of a dispatcher.
* https://www.ibm.com/docs/en/cognos-analytics/12.0.0?topic=reporting-setting-up-audit
* https://www.ibm.com/support/pages/how-enable-auditing-example-audit-logons-cognos-analyitcs-when-integrating-
controller-pa-ibm-cloud
(https://www.ibm.com/support/pages/how-enable-auditing-example-audit-logons-cognos-analyitcs-when-integrating-controller-pa-ibm-cloud)
* “3. Set the Cognos System logging levels to at least Basic Level” within https://www.ibm.com/support/pages/how-
configure-audit-reporting-cognos-analytics (https://www.ibm.com/support/pages/how-configure-audit-reporting-cognos-analytics)
Once you are at the window used to setup the logging properties of a dispatcher, enable “Audit logging level for query
service”. Its level could be set to Request or Trace. The last provides more information.
The audit is recorded in the cogaudit.log file located under <install-dir>/logs.
Additional Information
To identify QueryService audit records look for Audit.RTUsage.qs.
How to interpret QueryService audit records.
Some lines mark the start or the end of a process.
First example
9.46.108.34:9300 15384 2024-04-22 14:57:07.135 -4
ECB449AACF478C95AEC97A7F11654A0EECCBA563F7E57520235A31EEED4731FB
jMlqqhqs889q2vd94G9GlGGdM898vl2dhdl94CGh 77 XQE 0 4
Audit.RTUsage.qs.XQE.QueryService Request Query Service started processing "moserCommand" request from
"unknown" report.
9.46.108.34:9300 15384 2024-04-22 14:57:25.160 -4
ECB449AACF478C95AEC97A7F11654A0EECCBA563F7E57520235A31EEED4731FB
jMlqqhqs889q2vd94G9GlGGdM898vl2dhdl94CGh 77 XQE 0 4
Audit.RTUsage.qs.XQE.QueryService Response Query Service returned response for "moserCommand" request from
"unknown" report.
Second example
9.46.108.34:9300 15384 2024-04-22 14:57:22.968 -4
ECB449AACF478C95AEC97A7F11654A0EECCBA563F7E57520235A31EEED4731FB 8f265297-3960-47d0-8629-
31fcd89f9072:94b44d61-80fc-4baf-9818-753102e0b4d4 89 DSS 0 3 Audit.RTUsage.qs.DSS
Execute START Exploration QueryService CAMID("::Anonymous")/folder[@name='My
Folders']/exploration[@name='AuditExample'] <parameters><item name="model">
<![CDATA[/content/folder[@name='Samples_DQ']/folder[@name='Models']/package[@name='GO Sales (query)']]]></item><item
name="storeID"><![CDATA[i10D6EC8A9D624487B76E5976C224B136]]></item></parameters>
9.46.108.34:9300 15384 2024-04-22 14:57:42.609 -4
ECB449AACF478C95AEC97A7F11654A0EECCBA563F7E57520235A31EEED4731FB 8f265297-3960-47d0-8629-
31fcd89f9072:94b44d61-80fc-4baf-9818-753102e0b4d4 89 DSS 0 3 Audit.RTUsage.qs.DSS
Execute END Exploration QueryService CAMID("::Anonymous")/folder[@name='My
Folders']/exploration[@name='AuditExample'] Success <parameters><item name="model">
<![CDATA[/content/folder[@name='Samples_DQ']/folder[@name='Models']/package[@name='GO Sales (query)']]]></item><item
name="storeID"><![CDATA[i10D6EC8A9D624487B76E5976C224B136]]></item></parameters>
Third example
9.46.108.34:9300 14720 2024-04-22 09:26:13.480 -4
5B9CA682A1A8A807563622A724A940B859518AB010E771C20A3627FA4D83E3F4
24dwGlw8l89y9s4ddvjyjCdw2Cyh8CM4wCdyvh98 72 XQE 0 5
Audit.RTUsage.qs.XQE.QueryService.Metadata START Started creating IOLAPMetadataProvider with arguments ^User ID:^?
Password:;LOCAL;TMR;LCID=en-us;TM1AdminHost=vottdtspa6-
6.fyre.ibm.com;TM1Protocol=http;TM1ServerPort=8041;TM1ServerName=TM1ServerName;CATALOG=CATALOG;UID=%s;PWD=%s;
9.46.108.34:9300 14720 2024-04-22 09:26:24.653 -4
5B9CA682A1A8A807563622A724A940B859518AB010E771C20A3627FA4D83E3F4
24dwGlw8l89y9s4ddvjyjCdw2Cyh8CM4wCdyvh98 72 XQE 0 5
Audit.RTUsage.qs.XQE.QueryService.Metadata END Finished creating IOLAPMetadataProvider
Lines containing the word NativeQuery display either the SQL or the MDX sent to the underlying data source.
Creation, use and destruction of data source connections are also recorded in the audit file.
Relational example
9.46.108.34:9300 14720 2024-04-22 09:26:54.394 -4 0159cd00-9775-4d6a-ab79-
e98fbe7a55eb:b6ef2137-5787-4e92-8e89-8d35e5e3716d 95 XQE 0 5
Audit.RTUsage.qs.XQE.QueryService.Connection DEFAULT created ({DATA_SOURCE=DataSource[name=gosales,
cmDataSourceName=great_outdoors_sales],
RUN_LOCALE=en})=com.cognos.xqe.data.providers.relational.jdbc.sqlserver.SqlServerConnection@b34b7731
(mailto:=com.cognos.xqe.data.providers.relational.jdbc.sqlserver.SqlServerConnection@b34b7731)
9.46.108.34:9300 14720 2024-04-22 09:26:54.395 -4 0159cd00-9775-4d6a-ab79-
e98fbe7a55eb:b6ef2137-5787-4e92-8e89-8d35e5e3716d 95 XQE 0 5
Audit.RTUsage.qs.XQE.QueryService.Connection DEFAULT Connection created/borrowed:
datasourceName=great_outdoors_sales, id=-1286899919, isReusable=true, connectionTimeout=300 s, isIdle=false, last
accessed=2024-04-22 09:26:54.394
9.46.108.34:9300 14720 2024-04-22 09:27:02.577 -4 0159cd00-9775-4d6a-ab79-
e98fbe7a55eb:b6ef2137-5787-4e92-8e89-8d35e5e3716d 95 XQE 0 5
Audit.RTUsage.qs.XQE.QueryService.Connection DEFAULT Specs for connection creation/borrowing: type=JDBC,
datasourceName=great_outdoors_sales
9.46.108.34:9300 14720 2024-04-22 09:33:20.167 -4 by-cleanup-thread 205
XQE 0 5 Audit.RTUsage.qs.XQE.QueryService.Connection DEFAULT destroyed
com.cognos.xqe.data.providers.relational.jdbc.sqlserver.SqlServerConnection@b34b7731
(mailto:com.cognos.xqe.data.providers.relational.jdbc.sqlserver.SqlServerConnection@b34b7731)
Multidimensional example
9.46.108.34:9300 14720 2024-04-22 09:26:27.421 -4
5B9CA682A1A8A807563622A724A940B859518AB010E771C20A3627FA4D83E3F4
24dwGlw8l89y9s4ddvjyjCdw2Cyh8CM4wCdyvh98 72 XQE 0 5
Audit.RTUsage.qs.XQE.QueryService.Connection DEFAULT created ({CATALOG=CATALOG, CUBE=Revenue,
DATASOURCE_PROJECT_LOCALES=[en], DATASOURCE_TYPE=TM1REST,
DATA_SOURCE=DataSource[name=%TMP%_TMR_24Retail_Revenue_CATALOG_Revenue,
cmDataSourceName=TMR_24Retail_Revenue], PRODUCT_LOCALE=en, RUN_LOCALE=en, TM1_ADMIN_HOST=vottdtspa6-
6.fyre.ibm.com, TM1_SERVER_NAME=TM1ServerName, TM1_SERVER_PORT=8041, TM1_SERVER_PROTOCOL=http, UID=xqeodp})=
{CATALOG=CATALOG, CUBE=Revenue, DATASOURCE_PROJECT_LOCALES=[en], DATASOURCE_TYPE=TM1REST,
DATA_SOURCE=DataSource[name=%TMP%_TMR_24Retail_Revenue_CATALOG_Revenue,
cmDataSourceName=TMR_24Retail_Revenue], PRODUCT_LOCALE=en, RUN_LOCALE=en, TM1_ADMIN_HOST=vottdtspa6-
6.fyre.ibm.com, TM1_SERVER_NAME=TM1ServerName, TM1_SERVER_PORT=8041, TM1_SERVER_PROTOCOL=http, UID=xqeodp}
9.46.108.34:9300 14720 2024-04-22 09:26:47.925 -4
5B9CA682A1A8A807563622A724A940B859518AB010E771C20A3627FA4D83E3F4
24dwGlw8l89y9s4ddvjyjCdw2Cyh8CM4wCdyvh98 72 XQE 0 5
Audit.RTUsage.qs.XQE.QueryService.Connection DEFAULT Specs for connection creation/borrowing: type=TM1REST,
datasourceName=TMR_24Retail_Revenue
9.46.108.34:9300 14720 2024-04-22 09:33:27.059 -4 by-cleanup-thread 205
XQE 0 5 Audit.RTUsage.qs.XQE.QueryService.Connection DEFAULT destroyed {CATALOG=CATALOG,
CUBE=Revenue, DATASOURCE_PROJECT_LOCALES=[en], DATASOURCE_TYPE=TM1REST,
DATA_SOURCE=DataSource[name=%TMP%_TMR_24Retail_Revenue_CATALOG_Revenue,
cmDataSourceName=TMR_24Retail_Revenue], PRODUCT_LOCALE=en, RUN_LOCALE=en, TM1_ADMIN_HOST=vottdtspa6-
6.fyre.ibm.com, TM1_SERVER_NAME=TM1ServerName, TM1_SERVER_PORT=8041, TM1_SERVER_PROTOCOL=http, UID=xqeodp}
Document Information
More support for:
IBM Cognos Analytics (https://www.ibm.com/mysupport/s/topic/0TO500000002PVJGA2)
Component:
Administration->Auditing
Software version:
All Versions
Document number:
7149207
Modified date:
23 April 2024