Portal Server Logging - Part 2

In Part 1, i wrote about the basic logging features of Sun Java System Portal Server 7.x. In this part i will explain few advanced  features(rest i will cover in part 3), these include

As mentioned in part 1, if the portlet deployment fails, you need to check the logs from PAS(Portal Administration Server). By default the log level is SEVERE. For debugging purposes you need to decrease the log level. This can be done by using the CLI command

<portal-install-dir>/bin/psadmin set-logger -u amadmin -f <password-file> -m pas -O debug.com.sun.portal -L FINEST

This works very well, but if you feel that too much log is generated and if you are interested only in the portlet deployment related logs, then you need to change the log level of the portlet related logger as follows.

Changing the log level of a logger 

1. First you need to know the name of the portlet related logger, issue the following command to get the list of loggers

<portal-install-dir>/bin/psadmin list-loggers -u amadmin -f <password-file> -m pas

The output will be something like this

debug.com.sun.portal
debug.com.sun.portal.admin.server
debug.com.sun.portal.audit
debug.com.sun.portal.community.admin.mbeans
debug.com.sun.portal.desktop.admin.mbeans
debug.com.sun.portal.desktop.dp.xml
debug.com.sun.portal.fabric.mbeans
debug.com.sun.portal.fabric.tasks
debug.com.sun.portal.fabric.util
debug.com.sun.portal.monitoring.admin.mbeans
debug.com.sun.portal.portlet.admin.mbeans
debug.com.sun.portal.portlet.admin.mbeans.tasks
debug.com.sun.portal.portletcontainercommon.descriptor
debug.com.sun.portal.rewriter.admin.mbeans
debug.com.sun.portal.sra.admin.mbeans
debug.com.sun.portal.ssoadapter.mbeans
debug.com.sun.portal.subscriptions.admin.mbeans
debug.com.sun.portal.ubt.admin.mbeans
debug.com.sun.portal.wsrp.consumer.admin.mbeans
debug.com.sun.portal.wsrp.producer.admin.mbeans
 

In the above list portlet related loggers are "debug.com.sun.portal.portlet.admin.mbeans" and "debug.com.sun.portal.portlet.admin.mbeans.tasks". You need to use "debug.com.sun.portal.portlet.admin.mbeans", because "debug.com.sun.portal.portlet.admin.mbeans" is parent logger of "debug.com.sun.portal.portlet.admin.mbeans.tasks".

2. Now set the log level for the portlet logger as follows

<portal-install-dir>/bin/psadmin set-logger -u amadmin -f <password-file> -m pas -O debug.com.sun.portal.portlet.admin.mbeans -L FINEST

After issuing this command, you will see that only portlet related logs is appearing in the log level FINEST, while the rest is still at the level SEVERE

Redirecting the logs from a logger to different file

Is there a way to isolate the logs related to portlet so i don't need to search for portlet related logs in the portal.0.0.log file. This can be done as follows

<portal-install-dir>/bin/psadmin set-logger -u amadmin -f <password-file> -m pas -O debug.com.sun.portal.portlet.admin.mbeans -L FINEST --file

This creates a separate file for all the logs from portlet logger(i.e all the logs that has the logger "debug.com.sun.portal.portlet.admin.mbeans.\*" will be in new file and the name of the file will be portal.portlet.admin.mbeans.0.0.log)

After the problem is found, you may want to reset the logger back to the parent log file. this can be done as follows 

<portal-install-dir>/bin/psadmin reset-logger -u amadmin -f <password-file> -m pas -O debug.com.sun.portal.portlet.admin.mbeans

After this command, the logs from portlet logger will go to the parent log file, i.e portal.0.0.log, with the same level as that of the parent.

 

Comments:

Are there plans to get the partial lifecycle support working so that ajax components will work correctly in the JSF Portlets?

Posted by Jason Williams on June 11, 2008 at 04:02 PM IST #

Post a Comment:
  • HTML Syntax: NOT allowed
About

Deepak Gothe

Search

Categories
Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today