LicenseMetricTime

Product:
Cognos TM1 10.2.2
Microsoft Windows 2012 Server

Problem:
How do I list the Admin users in a TM1 application?

Solution:
There are different ways to get similar information;

List of users who have logged in to the TM1 application can be seen in the log file.

Here is a quick way to track user login/logout in TM1 using standard TM1 functionality, i.e. ACTIVE or blank STATUS Value from the }ClientProperties cube.

As of the TM1 9.1 release and later, the STATUS field is not automatically updated, so you will need to enable a background thread to keep the STATUS field up-to-date by setting the ClientPropertiesSyncInterval configuration parameter in tm1s.cfg file.

The background thread will wake up periodically and update the STATUS field for all clients indicating which are currently connected to the server. The configuration parameter ClientPropertiesSyncInterval is the number of seconds the background thread waits between updates. Example: ClientPropertiesSyncInterval=5

  • In the Server Explorer (TM1 Architect) , select View–>Display Control Objects from the top menu bar. Right click on Cubes and select Security Assignments.
  • Scroll down and ensure that Logging is checked for the }ClientProperties cube.
  • Select the tm1server and right click on View Transaction Log.
  • Select Cubes: }ClientProperties and the required date range.
  • Click Edit–>Select All–>Copy and then paste the records into an Excel spreadsheet.

The raw data in the Excel spreadsheet can be analyzed by creating a pivot table to count the number of OldValue or NewValue for each user (Key1) and for each day (LogTime). Convert the LogTime to a suitable month/year format to analyze the user login counts by month. Create your own Excel format for reporting TM1 User activity.

More information:
http://www-01.ibm.com/support/docview.wss?uid=swg21424524

Use an external program to find the usages, try this to see if they can help you;

http://www.bspsoftware.com/products/metamanager/tm1/

https://www.motio.com/content/CognosTM1-free-software.do

Use a TI process to list the users in the security cube, into a different cube, this script below need to be edit to have the USERGROUPS you want to list, and then you have to look into the result cube, to see what GROUPS each user is part of. Should give that it is easy for you to see the number of user that are ADMIN in an application.

In each TM1 application, create a new TI process, and paste below code in PROLOG and EPILOG.

“edit” groups and save and run. You will have a new cube that will list users in group.

#————————————–

# Below code should be in PROLOG
# set default values
#————————————–

sTargetCube=’ClientMemberships’;
sClientDim=’Clients’;
sClientMemberDim=’ClientsMembership’;

sCube=’}ClientGroups’;
sDim=’}Clients’;

sGroup1=’ADMIN’;
sGroup2=’DataAdmin’;
#————————————–
# create dimensions if they do not exist
#————————————–

if (DimensionExists (sClientDim)=0);
DimensionCreate (sClientDim);
endif;

if (DimensionExists(sClientMemberDim)=0);
DimensionCreate (sClientMemberDim);
endif;
#——————————————–
# create cube if not exist
#——————————————–

If (Cubeexists (sTargetCube)=0);
CubeCreate (sTargetCube,sClientDim,sClientMemberDim);
endif;

#—————————————–
# create dimension hierarchy
#——————————————

#dimensiondeleteAllElements(‘ClientsMembership’);
dimensionelementInsertDirect( sClientMemberDim,”,’Sum’,’c’);
dimensionelementComponentAdddirect(sClientMemberDim,’Sum’,sGroup1,1);
dimensionelementComponentAdddirect(sClientMemberDim,’Sum’,sGroup2,1);

dimensiondeleteAllElements(sClientDim);
#————————————————————

# Below code should be in EPILOG
# check if client is member of group
#————————————————————-

i=1;
while(i<=dimsiz(sDim));
vClient=dimnm(sDim,i);
if(long(attrs(sDim,vClient,’}TM1_DefaultDisplayValue’ ))>0);
vClientName=attrs(sDim,vClient,’}TM1_DefaultDisplayValue’ );
else;
vClientName=vClient;
endif;

if(cellgets(sCube, vClient, sGroup1) @=sGroup1);
dimensionelementinsertdirect(sClientDim,”,vClientName,’n’);
cellputn(1,sTargetCube,vClientName, sGroup1);
endif;

if(cellgets(sCube, vClient, sGroup2) @=DimensionElementPrincipalName(  ‘}Groups’,sGroup2 ) );
dimensionelementinsertdirect(sClientDim,”,vClientName,’n’);
cellputn(2,sTargetCube,vClientName, sGroup2);
endif;

i=i+1;
end;
#——————————————————————
# end of code
#——————————————————————

 

List license usage of TM1 with the TM1S.CFG parameter LicenseMetricTime

LicenseMetricTime=00:14:36

The file is created under the folder \ C:\Program Files\ibm\cognos\tm1_64\slmtagraw.

File name is IBM Cognos TM1_10.2.0_medlem register20150113200502294.slmtagraw , see the content of this file last in this doc.

 

Based on the little documentation that exists (i.e. in the .cfg file), I believe this will generate an XML file for the ILMT tool to pick up which is required for sub-capacity license monitoring.

 

NOTE: ILMT https://www.ibm.com/developerworks/community/wikis/home?lang=en#!/wiki/IBM+License+Metric+Tool

is IBM software which is free and is required when PVU licensed software has been installed on a Virtual environment.

# LicenseMetricTime
# Sets the time of day the TM1 server will generate a License Metric Tag file.
# A License Metric Tag file is an XML file which contains information about license metrics consumed by software product instances.
# In the case of TM1 server, the reported authorized user metrics are the number of Modelers, Contributors and Explorers.
# The License Metric Tag files produced by various instances of TM1 servers are collected by the IBM License Metric Tool (ILMT) agent and aggregated to produce final metrics based on the TM1 product version.
#
# The format of the LicenseMetricTime parameter is dd:hh:mm where:
# * dd is the number of days from today that the system will start automatically producing License Metric tag files. For example, 00 is today, 01 is tomorrow.
# * hh:mm is the time of day in 24-hour format.
# Type: optional, dynamic
LicenseMetricTime=00:14:36

More information:

http://www-01.ibm.com/support/docview.wss?uid=swg21959520&myns=swgimgmt&mynp=OCSS9RXT&mync=E&cm_sp=swgimgmt-_-OCSS9RXT-_-E

Use AUDIT logging to find when users are logged into the Applications.

You want to enable audit logging for the TM1 server, process the audit log, and review the details of the audit log.

 

This shows how to use the audit log, for your or use any TM1 server that you have available.

 

Open Windows Explorer, and then navigate to Tm1 folder for your application or the example application GreatOutdoors

Open the tm1s.cfg file in Notepad.

You want to enable the audit log and specify how frequently this log is to be updated.

Set the value of the AuditLogOn parameter to T.

Set the value of the AuditLogUpdateInterval parameter to 60.

The AuditLogUpdateInterval indicates the amount of time, in minutes, that TM1waits before moving the events.  The events are moved from the temporary audit file into the final audit log.

Save the file and close Notepad.

 

You may need to restart your TM1 applications service to make the changes in TM1S.CFG to take affect.

 

From the Start menu, point to All Programs\IBM Cognos\TM1, and then click Architect.

Expand TM1, and then double-click greatoutdoors.

You are prompted to log on to the GreatOutdoors TM1 server.

In the UserName box, type admin, leave the Password box blank, and then click OK.

Ensure that greatoutdoors is selected, and then from the Server menu, click Process Audit Log Events.

You are prompted to update the audit log with the latest events.

Click Yes, and then from the Server menu, click View Audit Log.

The Audit Log window opens.

Click Run Query.

The Results section of the Audit Log window shows a list of audit events.

You can further refine your results by choosing a different time period, as well as by specifying the event owner and type.

Close the Audit Log window.

 

Export the Audit log to Excel for further processing.

 

More Information on the file:

<?xml version=”1.0″ encoding=”UTF-8″?>

<LicenseMetrics version=”0.1″

xmlns=”http://www.ibm.com/xml/ns/licensemetrics”

xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance”

xsi:schemaLocation=”http://www.ibm.com/xml/ns/licensemetrics licensemetrics.xsd”>

<Product>

<ProductName>IBM Cognos TM1</ProductName>

<ProductVersion>10.2.0</ProductVersion>

<ProductId type=”guid”>4acad4f5525b4bd0a78723fcd6cd6154</ProductId>

<InstanceId type=”installation_path”><![CDATA[C:\Program Files\ibm\cognos\tm1_64\bin64]]></InstanceId>

<InstanceName><![CDATA[medlem register]]></InstanceName>

</Product>

<Metrics>

<Metric LogTime=”Apr 18, 2016 7:05:02 PM GMT”>

<Type>GROUP_INFO</Type>

<SubType>GROUP_DETAIL</SubType>

<Value><![CDATA[Group ADMIN is a modeling group: The predefined admin group ADMIN is considered a Modeling group.]]></Value>

<Period>

<StartTime>Apr 18, 2016 7:05:02 PM GMT</StartTime>

<EndTime>Apr 18, 2016 7:05:02 PM GMT</EndTime>

</Period>

</Metric>

<Metric LogTime=”Apr 18, 2016 7:05:02 PM GMT”>

<Type>GROUP_INFO</Type>

<SubType>GROUP_DETAIL</SubType>

<Value><![CDATA[Group DataAdmin is a modeling group: The predefined admin group DataAdmin is considered a Modeling group.]]></Value>

<Period>

<StartTime>Apr 18, 2016 7:05:02 PM GMT</StartTime>

<EndTime>Apr 18, 2016 7:05:02 PM GMT</EndTime>

</Period>

</Metric>

<Metric LogTime=”Apr 18, 2016 7:05:02 PM GMT”>

<Type>GROUP_INFO</Type>

<SubType>GROUP_DETAIL</SubType>

<Value><![CDATA[Group SecurityAdmin is a modeling group: The predefined admin group SecurityAdmin is considered a Modeling group.]]></Value>

<Period>

<StartTime>Apr 18, 2016 7:05:02 PM GMT</StartTime>

<EndTime>Apr 18, 2016 7:05:02 PM GMT</EndTime>

</Period>

</Metric>

<Metric LogTime=”Apr 18, 2016 7:05:02 PM GMT”>

<Type>GROUP_INFO</Type>

<SubType>GROUP_DETAIL</SubType>

<Value><![CDATA[Group TESTGROUP is a contributor group: Group TESTGROUP has WRITE permission on cube ClientMemberships.]]></Value>

<Period>

<StartTime>Apr 18, 2016 7:05:02 PM GMT</StartTime>

<EndTime>Apr 18, 2016 7:05:02 PM GMT</EndTime>

</Period>

</Metric>

<Metric LogTime=”Apr 18, 2016 7:05:02 PM GMT”>

<Type>GROUP_INFO</Type>

<SubType>Number of Modeling groups</SubType>

<Value>3</Value>

<Period>

<StartTime>Apr 18, 2016 7:05:02 PM GMT</StartTime>

<EndTime>Apr 18, 2016 7:05:02 PM GMT</EndTime>

</Period>

</Metric>

<Metric LogTime=”Apr 18, 2016 7:05:02 PM GMT”>

<Type>GROUP_INFO</Type>

<SubType>Number of Contributor groups</SubType>

<Value>1</Value>

<Period>

<StartTime>Apr 18, 2016 7:05:02 PM GMT</StartTime>

<EndTime>Apr 18, 2016 7:05:02 PM GMT</EndTime>

</Period>

</Metric>

<Metric LogTime=”Apr 18, 2016 7:05:02 PM GMT”>

<Type>GROUP_INFO</Type>

<SubType>Number of Explorer groups</SubType>

<Value>0</Value>

<Period>

<StartTime>Apr 18, 2016 7:05:02 PM GMT</StartTime>

<EndTime>Apr 18, 2016 7:05:02 PM GMT</EndTime>

</Period>

</Metric>

<Metric LogTime=”Apr 18, 2016 7:05:02 PM GMT”>

<Type>AUTHORIZED_USER</Type>

<SubType>MODELER</SubType>

<Value><![CDATA[Admin]]></Value>

<Period>

<StartTime>Apr 18, 2016 7:05:02 PM GMT</StartTime>

<EndTime>Apr 18, 2016 7:05:02 PM GMT</EndTime>

</Period>

</Metric>

<Metric LogTime=”Apr 18, 2016 7:05:02 PM GMT”>

<Type>USER_INFO</Type>

<SubType>MODELER</SubType>

<Value><![CDATA[User Admin is a Modeler. Belongs to group ADMIN. The predefined admin group ADMIN is considered a Modeling group.]]></Value>

<Period>

<StartTime>Apr 18, 2016 7:05:02 PM GMT</StartTime>

<EndTime>Apr 18, 2016 7:05:02 PM GMT</EndTime>

</Period>

</Metric>

<Metric LogTime=”Apr 18, 2016 7:05:02 PM GMT”>

<Type>AUTHORIZED_USER</Type>

<SubType>MODELER</SubType>

<Value><![CDATA[Roger]]></Value>

<Period>

<StartTime>Apr 18, 2016 7:05:02 PM GMT</StartTime>

<EndTime>Apr 18, 2016 7:05:02 PM GMT</EndTime>

</Period>

</Metric>

<Metric LogTime=”Apr 18, 2016 7:05:02 PM GMT”>

<Type>USER_INFO</Type>

<SubType>MODELER</SubType>

<Value><![CDATA[User Roger is a Modeler. Belongs to group ADMIN. The predefined admin group ADMIN is considered a Modeling group.]]></Value>

<Period>

<StartTime>Apr 18, 2016 7:05:02 PM GMT</StartTime>

<EndTime>Apr 18, 2016 7:05:02 PM GMT</EndTime>

</Period>

</Metric>

<Metric LogTime=”Apr 18, 2016 7:05:02 PM GMT”>

<Type>USER_INFO</Type>

<SubType>Number of Modeling users</SubType>

<Value>2</Value>

<Period>

<StartTime>Apr 18, 2016 7:05:02 PM GMT</StartTime>

<EndTime>Apr 18, 2016 7:05:02 PM GMT</EndTime>

</Period>

</Metric>

<Metric LogTime=”Apr 18, 2016 7:05:02 PM GMT”>

<Type>USER_INFO</Type>

<SubType>Number of Contributor users</SubType>

<Value>0</Value>

<Period>

<StartTime>Apr 18, 2016 7:05:02 PM GMT</StartTime>

<EndTime>Apr 18, 2016 7:05:02 PM GMT</EndTime>

</Period>

</Metric>

<Metric LogTime=”Apr 18, 2016 7:05:02 PM GMT”>

<Type>USER_INFO</Type>

<SubType>Number of Explorer users</SubType>

<Value>0</Value>

<Period>

<StartTime>Apr 18, 2016 7:05:02 PM GMT</StartTime>

<EndTime>Apr 18, 2016 7:05:02 PM GMT</EndTime>

</Period>

</Metric>

</Metrics>

</LicenseMetrics>