I am trying to retrieve Websphere server logs through wsadmin. When connected to a ND, I might have to retrieve logs from remote nodes where I dont have SSH access.
Since I can view the logs using the Management Console, I was wondering if I could retrieve the logs using wsadmin.
I've managed to do the following:
s1 = AdminConfig.getid('/Node:'+nodeName+'/Server:'+serverName)
log = AdminConfig.showAttribute(s1, 'outputStreamRedirect')
For each server, this prints something like this:
[baseHour 24]
[fileName ${SERVER_LOG_ROOT}/SystemOut.log]
[formatWrites true]
[maxNumberOfBackupFiles 5]
[messageFormatKind BASIC]
[rolloverPeriod 24]
[rolloverSize 1]
[rolloverType SIZE]
[suppressStackTrace false]
[suppressWrites false]
[baseHour 24]
[fileName ${SERVER_LOG_ROOT}/SystemErr.log]
[formatWrites true]
[maxNumberOfBackupFiles 5]
[messageFormatKind BASIC]
[rolloverPeriod 24]
[rolloverSize 1]
[rolloverType SIZE]
[suppressStackTrace false]
[suppressWrites false]
Is there any object in wsadmin that could help me retrieve the contents of that fileName attribute?