cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Where to find the user log data in the log files?

Highlighted
Guest

Where to find the user log data in the log files?

Where in the log files can I find the entries of user login in and logout over a period of time? I need the data of about two months.

7 REPLIES 7
Highlighted

Re: Where to find the user log data in the log files?

Hello Sujith Dattatreya Padaki‌,

If you have audit logging enabled, you can check the audit logs for logins.  CS133798 covers how to set up audit logging.  If you don't have audit logging enabled, you might be able to find that information by combing through surviving server.###.log files. 

In general, the recommended way to track particular user actions is to configure audit logging to track the desired actions, and then refer to that when necessary.

Regards,
Kael


Kind Regards,
Kael Lizak

Senior Technical Support Engineer
PTC Integrity Lifecycle Manager
Highlighted

Re: Where to find the user log data in the log files?

Thank you for your reply.

I do not have the Audit enabled. So I will have to check in the server.log file. I could not find the details. Could you please tell me in what way the user login information is present in the server.log file?

Thanks in advance.

Highlighted

Re: Where to find the user log data in the log files?

Hello Sujith,

in your server's file  "logger.properties" in the path <install> \ IntegrityServer \ config \ properties

you can define as well the level of logging:

# Logger Configuration

# Generic logging levels:

# 0 - High (Errors, fatal, etc)

# 5 - Medium (Important information)

# 10 - Low (Debug information)

as well as the syntax of your log-entries:

#

# Message Formats

#

# {0} - class name

# {1} - the object

# {2} - category

# {3} - level

# {4} - message

# {5} - current date/time

# {6} - thread specific information

#

#

# Exception Formats

#

# {0} - class name

# {1} - the object

# {2} - category

# {3} - level

# {4} - exception class name

# {5} - exception message

# {6} - exception stack trace

# {7} - current date/time

# {8} - thread specific information

#

In my company I have added "{6} - thread specific information" to the Message

as well as "{8} - thread specific information" to the Exception to get the User listed in the Log.

One example:

2016-04-15 09:45:28,868 DEBUG [mksis.IntegrityServer] DEBUG(0): [halmhe1[Thread-59172[null]]] VPaired Field: FIELD:id=-13:dataType=7:multiValue=true:storageFormat=true:backingFieldID=0:backingType=0:name=Backward Relationships, -12

The part  "halmhe1"  is UserID on our side.

Good luck

Highlighted

Re: Where to find the user log data in the log files?

Hello Klaus,

Thank you for your  reply.

Since I have not enabled the logging, my question is, is it possible to get the history of user log details as the logging is not enabled and I want the data of over a last month

Highlighted

Re: Where to find the user log data in the log files?

Hello Sujith,

from my perspective this can't be possible, since the log-entries will be written based on your definition from logger-properties.

It is same like with the log-level:  Only if you increase log-level, extended logging will be done (greater logfiles will be written then).

Maybe experts from PTC see anything like you ask for as analysis directly from the Database?

Highlighted

Re: Where to find the user log data in the log files?

If what you want to know is when a person first logs into Integrity and then when they log out, you will not find this information either in the audit log or the server log, no matter the logging category or level. In any case, you will not get this information for the past two months, you can only try to get a solution for the future.

Typically, this is a question that comes up when we want to measure license usage, and I know many people who have tried for many years, including myself. If someone logs in, thereby holding a license, does nothing for one hour, and then logs out, you will see nothing in the logs.

I believe the answer for accurate usage monitoring is in using the additional tool called PTC System Monitor, although I have not been able to use it yet so I'm not sure.

If that is your question, let me know and I'll share my current (and incomplete) solution.

Highlighted

Re: Where to find the user log data in the log files?

Hi,

If you want to see active connection details then use the following command :

private static final String DIAG_CONNECTIONS = "diag=connections";

private static final String DIAG = "diag";

cmd = new Command(Command.IM, DIAG);

cmd.addOption(new Option(DIAG_CONNECTIONS));

response = cmdRunner.execute(cmd);

The command is: im diag diag=connections

If you want to see the login time and logout time, then you have to use PSM tool.

Thanks,

Sithik

Announcements