Tracking User Logins

Post Reply
LanceTylor
Posts: 65
Joined: Mon Feb 27, 2012 12:37 am
OLAP Product: TM1
Version: 10.2.2 Fix Pack 4
Excel Version: 2010

Tracking User Logins

Post by LanceTylor » Thu Aug 01, 2013 3:06 pm

Hello All,

What is the easiest way to determine who has logged into TM1? We are conducting UAT and would like a list of who has actually been testing or even logged into TM1?

Thanks
Lance

User avatar
qml
MVP
Posts: 1042
Joined: Mon Feb 01, 2010 1:01 pm
OLAP Product: TM1
Version: 10.2.2
Excel Version: 2007 - 2016
Location: London, UK, Europe

Re: Tracking User Logins

Post by qml » Thu Aug 01, 2013 3:42 pm

Switch Performance Monitor on and you will have the }StatsByClient cube populated with traffic statistics for all users who have used the system.

Another method is to look for their private folders in the TM1 data folder. When a user logs on for the first time TM1 will create a folder for them to store their private objects (even before they create any such objects). The folder will be named like the user and the timestamp on it will tell you the first logon date.
Last edited by qml on Fri Aug 02, 2013 9:19 am, edited 1 time in total.
Kamil Arendt

LanceTylor
Posts: 65
Joined: Mon Feb 27, 2012 12:37 am
OLAP Product: TM1
Version: 10.2.2 Fix Pack 4
Excel Version: 2010

Re: Tracking User Logins

Post by LanceTylor » Thu Aug 01, 2013 4:38 pm

Thanks Kamil!

User avatar
Steve Vincent
Site Admin
Posts: 1048
Joined: Mon May 12, 2008 8:33 am
OLAP Product: TM1
Version: 10.2.2 FP1
Excel Version: 2010
Location: UK

Re: Tracking User Logins

Post by Steve Vincent » Fri Aug 02, 2013 8:40 am

Remember that performance monitor is only a current snapshot, not a historic reporting tool. if you want a full history then you would be better to write something that pulls the relevant entries from the server logs then upload those to a cube which you can keep the history in.
If this were a dictatorship, it would be a heck of a lot easier, just so long as I'm the dictator.
Production: TM1 64 bit 10.2.2, Windows 2008/2012 Server. Excel 2010, IE11 for t'internet

User avatar
Alan Kirk
Site Admin
Posts: 5719
Joined: Sun May 11, 2008 2:30 am
OLAP Product: TM1
Version: 9.5.2 64 bit moving to 10.2.2
Excel Version: 2010
Location: Sydney, Australia
Contact:

Re: Tracking User Logins

Post by Alan Kirk » Fri Aug 02, 2013 9:18 am

Steve Vincent wrote:Remember that performance monitor is only a current snapshot, not a historic reporting tool. if you want a full history then you would be better to write something that pulls the relevant entries from the server logs then upload those to a cube which you can keep the history in.
With the proviso that in the post-9.0 world Iboglix borked what was, up until that point, a nice, elegant piece of functionality to track user activity. To be able to still do that you now need to ensure that the ClientPropertiesSyncInterval config parameter is set to allow the client status to be tracked in the logs.
"To them, equipment failure is terrifying. To me, it’s 'Tuesday.' "
-----------
Before posting, please check the documentation, the FAQ, the Search function and FOR THE LOVE OF GLUB the Request Guidelines.

st2000
Posts: 56
Joined: Mon Aug 15, 2016 8:48 am
OLAP Product: TM1 (Windows) & SSAS 2014 Ent.
Version: 10.2.0 FP3
Excel Version: Excel 2013
Location: Hamburg, DE, EU
Contact:

Re: Tracking User Logins

Post by st2000 » Wed Jul 26, 2017 5:24 pm

If I don't configure the interval very narrow, I would have always a lack of actuality. If I configure it to update frequently, IBM warns about problems.
Is there any way to trigger it proactive somehow? The docs don't indicate that, but maybe I use the wrong search terms.
I mean to configure the interval very infrequent (say 1x / day), and push it to update via TI just when I need to have the actual subset of clients being ACTIVE this moment?
Any idea is highly appreciated... :mrgreen:
-----------------------------------
Best regards,
Stefan

User avatar
gtonkin
MVP
Posts: 511
Joined: Thu May 06, 2010 3:03 pm
OLAP Product: TM1
Version: PAL 2.0.1
Excel Version: 2016 64-bit
Location: JHB, South Africa
Contact:

Re: Tracking User Logins

Post by gtonkin » Wed Jul 26, 2017 6:33 pm

Noticing that you are running 10.2.2 FP4, you could probably take advantage of additional logging by configuring your tm1s-log.properties.
I had a similar scenario where my client wanted to know who was logging in and when as well as unsuccessful logins.

Have a look at this post for what I did and suggested to another member of this forum.

I now have a log file that I can analyze, process with TI, Excel etc. and feedback on. HTH

ellissj3
Posts: 53
Joined: Tue Jun 15, 2010 1:43 pm
OLAP Product: Cognos TM1
Version: 9.0 - 10.2
Excel Version: 2010
Contact:

Re: Tracking User Logins

Post by ellissj3 » Wed Jul 26, 2017 8:55 pm

try inserting this into the tm1s-log.properties

Code: Select all

### CREATE LOGIN FILE
log4j.logger.TM1.Login = DEBUG, LOGIN
log4j.appender.LOGIN = org.apache.log4j.SharedMemoryAppender
log4j.appender.LOGIN.MemorySize = 1MB
log4j.appender.LOGIN.File = tm1login.log
log4j.appender.LOGIN.MaxFileSize = 2MB
log4j.appender.LOGIN.MaxBackupIndex = 5
log4j.appender.LOGIN.TimeZone = Local
This will put an out of all user logins into a file called "TM1Login.Log"

The link above contains this exact post, who was probably the original author, which I shamelessly stole.

User avatar
MarkTM1
Posts: 4
Joined: Wed Mar 25, 2009 2:56 am
OLAP Product: TM1
Version: 10.2
Excel Version: Excel 2010

Re: Tracking User Logins

Post by MarkTM1 » Thu Jul 27, 2017 1:23 am

TM1Top's Log file could be another way to consider, need to have the Tm1top.ini file set to log activity.
e.g.
adminhost=
servername=planning sample
logfile=c:\temp\tm1top.log
logperiod=50
logappend=T
refresh=10

st2000
Posts: 56
Joined: Mon Aug 15, 2016 8:48 am
OLAP Product: TM1 (Windows) & SSAS 2014 Ent.
Version: 10.2.0 FP3
Excel Version: Excel 2013
Location: Hamburg, DE, EU
Contact:

Re: Tracking User Logins

Post by st2000 » Thu Aug 03, 2017 3:32 pm

I tried the way using the log4j logger. Generally, it works as the TM1llogin.log-File was created immediately. But when I log in to that server, the file keeps empty. Do I have to maintain some different switches somewhere to get some content into that file?

The tm1slog.properties resides now in the same folder like the tm1s.cfg which is noticed as a requirement in the tm1_op manual.
The (only!) content of the file is:

Code: Select all

log4j.logger.TM1.Login = DEBUG, LOGIN
log4j.appender.LOGIN = org.apache.log4j.SharedMemoryAppender
log4j.appender.LOGIN.MemorySize = 1MB
log4j.appender.LOGIN.File = C:\TM1MODELS\Metadatenmgmt\tm1login.log
log4j.appender.LOGIN.MaxFileSize = 2MB
log4j.appender.LOGIN.MaxBackupIndex = 5
log4j.appender.LOGIN.TimeZone = Local
Did I overlook something? I understood the tm1_op instructions like I have just to put the .properteis-file next to the .cfg and TM1 starts logging as configured.
-----------------------------------
Best regards,
Stefan

User avatar
gtonkin
MVP
Posts: 511
Joined: Thu May 06, 2010 3:03 pm
OLAP Product: TM1
Version: PAL 2.0.1
Excel Version: 2016 64-bit
Location: JHB, South Africa
Contact:

Re: Tracking User Logins

Post by gtonkin » Thu Aug 03, 2017 3:40 pm

st2000 wrote:
Thu Aug 03, 2017 3:32 pm
...The tm1slog.properties resides now in the same folder like the tm1s.cfg which is noticed as a requirement in the tm1_op manual...
Just checking if this is a typo - is your file called tm1s-log.properties There must be a hyphen between tm1s and log.

lotsaram
MVP
Posts: 2998
Joined: Fri Mar 13, 2009 11:14 am
OLAP Product: TM1, CX
Version: TM1 10.2.2 PA 2.0x
Excel Version: 2010 2013 365
Location: Switzerland

Re: Tracking User Logins

Post by lotsaram » Thu Aug 03, 2017 5:40 pm

I use this pretty much always and it works flawlessly

log4j.appender.USR=org.apache.log4j.SharedMemoryAppender
log4j.appender.USR.File=userlogin.log
log4j.appender.USR.MaxFileSize=5 MB
log4j.appender.USR.TimeZone=Local
log4j.logger.TM1.Login=DEBUG, USR
Please place all requests for help in a public thread. I will not answer PMs requesting assistance.

st2000
Posts: 56
Joined: Mon Aug 15, 2016 8:48 am
OLAP Product: TM1 (Windows) & SSAS 2014 Ent.
Version: 10.2.0 FP3
Excel Version: Excel 2013
Location: Hamburg, DE, EU
Contact:

Re: Tracking User Logins

Post by st2000 » Fri Aug 04, 2017 1:07 pm

Unfortunately my typo only occured in the post, but not in the filename... this would have been easier :lol:

I used lotsarams script, but faced the same experience: Log-file (userlogin.log) will be created after saving the file changes for ....properties.
Then starting Perspectives, logging in, logging out.
Then opened the userlogin.log-file: empty.
Expected: 2 entries documenting the login and the logout before (or at least the login).

As of blog entries concerning log4j (TM1-agnostic), the rootlogger-configuration is not neccessary as this exists anyway behind the scenes. And in your examples this is omitted as well. So I guess, this will not be the cause...

Could it be, that I have a wrong expectation about the frequency of updates performed by log4j? Perhaps the login/logout-events are triggered somewhere, but the file just updated in longer intervals...
It is a local installed Testdummy-TM1-installation I shut down every evening. Might I need to configure also the interval to write the lines down to the file more frequently?
-----------------------------------
Best regards,
Stefan

Drg
Posts: 62
Joined: Fri Aug 12, 2016 10:02 am
OLAP Product: tm1
Version: 10.2.0 - 10.3.0
Excel Version: 2010

Re: Tracking User Logins

Post by Drg » Fri Aug 04, 2017 2:12 pm

st2000 wrote:
Fri Aug 04, 2017 1:07 pm
Unfortunately my typo only occured in the post, but not in the filename... this would have been easier :lol:

I used lotsarams script, but faced the same experience: Log-file (userlogin.log) will be created after saving the file changes for ....properties.
Then starting Perspectives, logging in, logging out.
Then opened the userlogin.log-file: empty.
Expected: 2 entries documenting the login and the logout before (or at least the login).

As of blog entries concerning log4j (TM1-agnostic), the rootlogger-configuration is not neccessary as this exists anyway behind the scenes. And in your examples this is omitted as well. So I guess, this will not be the cause...

Could it be, that I have a wrong expectation about the frequency of updates performed by log4j? Perhaps the login/logout-events are triggered somewhere, but the file just updated in longer intervals...
It is a local installed Testdummy-TM1-installation I shut down every evening. Might I need to configure also the interval to write the lines down to the file more frequently?
Read this:
https://www.ibm.com/support/knowledgece ... 503fe.html
search params begin 'audit'

st2000
Posts: 56
Joined: Mon Aug 15, 2016 8:48 am
OLAP Product: TM1 (Windows) & SSAS 2014 Ent.
Version: 10.2.0 FP3
Excel Version: Excel 2013
Location: Hamburg, DE, EU
Contact:

Re: Tracking User Logins

Post by st2000 » Fri Aug 04, 2017 3:13 pm

You mean I need to switch on the auditing function to get system logging?
That leads to "game over" for me. I reside in Germany, and if I would activate auditing (which logs much more than just logins...) I would at least get serious trouble with the working council (and probably commit a crime against a citizen right I would translate as informational self-determination, which also applies at work).

Thanks a lot to all repliers and sorry for confusion.
I didn't relate auditing with logging and thought, it were different functions. :oops:
-----------------------------------
Best regards,
Stefan

Wim Gielis
MVP
Posts: 1538
Joined: Mon Dec 29, 2008 6:26 pm
OLAP Product: TM1
Version: PAL 2.0
Excel Version: 2016
Location: Brussels, Belgium
Contact:

Re: Tracking User Logins

Post by Wim Gielis » Fri Aug 04, 2017 3:25 pm

st2000 wrote:
Fri Aug 04, 2017 3:13 pm
You mean I need to switch on the auditing function to get system logging?
That leads to "game over" for me. I reside in Germany, and if I would activate auditing (which logs much more than just logins...) I would at least get serious trouble with the working council (and probably commit a crime against a citizen right I would translate as informational self-determination, which also applies at work).

Thanks a lot to all repliers and sorry for confusion.
I didn't relate auditing with logging and thought, it were different functions. :oops:
These are not related to each other.
I have a model running on my laptop where I tested the tm1s-log.properties contents of Lotsaram, yesterday. It worked beautifully.
I could see myself logging on and off.
The tm1s.cfg file of that model clearly has AuditLogOn=F.
Best regards,

Wim Gielis

Excel Most Valuable Professional, 2011-2014
http://www.wimgielis.com ==> 103 TM1 articles and a lot of custom code
Newest blog article: TM1 message log analysis with Power Query

User avatar
gtonkin
MVP
Posts: 511
Joined: Thu May 06, 2010 3:03 pm
OLAP Product: TM1
Version: PAL 2.0.1
Excel Version: 2016 64-bit
Location: JHB, South Africa
Contact:

Re: Tracking User Logins

Post by gtonkin » Fri Aug 04, 2017 3:41 pm

st2000 wrote:
Thu Aug 03, 2017 3:32 pm
I tried the way using the log4j logger....

Code: Select all

log4j.logger.TM1.Login = DEBUG, LOGIN
log4j.appender.LOGIN = org.apache.log4j.SharedMemoryAppender
log4j.appender.LOGIN.MemorySize = 1MB
log4j.appender.LOGIN.File = C:\TM1MODELS\Metadatenmgmt\tm1login.log
...
Have you tried just using tm1login.log for the file, without the path? just wondering if there may be some issue with Java and the slashes.

Code: Select all

log4j.appender.LOGIN.File = C:\\TM1MODELS\\Metadatenmgmt\\tm1login.log
Gave it a *quick* test on my side and may be the cure.

st2000
Posts: 56
Joined: Mon Aug 15, 2016 8:48 am
OLAP Product: TM1 (Windows) & SSAS 2014 Ent.
Version: 10.2.0 FP3
Excel Version: Excel 2013
Location: Hamburg, DE, EU
Contact:

Re: Tracking User Logins

Post by st2000 » Tue Aug 22, 2017 9:13 am

Sorry for the late feedback. I tried it without a path: Defined logfile was created into the folder where the tm1slog.properties resides (same as TM1s.cfg). But empty. So generally the triggering works somehow under the hood, but not the entry of the log event.

Then I tried the style with double backslashs. In this case neither the file will not be created nor something else seems to happen.

We use an older TM1 version (10.2.0), maybe something was different at this version.
I will postpone this to the time we start a new project using PA.

Thank you all for your help, I will report if I stumble over the trick :)
-----------------------------------
Best regards,
Stefan

BrianL
MVP
Posts: 261
Joined: Mon Nov 03, 2014 8:23 pm
OLAP Product: TM1
Version: 9.5.2 10.1 10.2 PA2
Excel Version: 2016

Re: Tracking User Logins

Post by BrianL » Wed Aug 23, 2017 1:25 pm

I believe the TM1.Login logger was first made available in 10.2.2 FP1. Anything earlier than that will not create any login log entries.

Post Reply