Redirecting Weblogic Logs to /var/log/messages

Hi all,
I've seen a few threads on here regarding this but they're all for older WLS versions.  I'm trying to get my server messages into /var/log/messages.
I've seen and read a few posts about this and using log4j.  I've added the necessary jars to the domain/lib folder and created a log4j.properties file and its the latter part I think is the issue....
I've tried adding it to the setDomain.sh CLASSPATH and the also to the servers classpath in the WLS Console, however I can't see any record of it getting picked up in the logs.
The server is set to log4j and I've confirmed this using WLST.  Does anyone have any suggestions?
Weblogic is version 11.1.1.7
Thanks
Dave

There could be two reasons:
1. You have to exit GGSCI and restart again for GLOBALS changes to take effect, which you may not have done.
2. you might still be using SYSLOG in manager parameter file which overrides the GLOBALS setting as per the below explaination from Oracle.
"You can use SYSLOG as a GLOBALS or Manager parameter, or both. When present in the GLOBALS parameter file, it controls message filtering for all of the Oracle GoldenGate processes on the system. When present in the Manager parameter file, it controls message filtering only for the Manager process. If used in both the GLOBALS and Manager parameter files, the Manager setting overrides the GLOBALS setting for the Manager process."

Similar Messages

  • ERROR messages in /var/log/messages

    Hi,
    I encountered a error messages in /var/log/messages please find below
    Dec 9 04:03:08 drs syslogd 1.4.1: restart (remote reception).
    Dec 9 04:03:18 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:03:18 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:03:18 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:03:18 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:03:18 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:03:18 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:03:18 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:03:18 drs init: Id "h1" respawning too fast: disabled for 5 minutes
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs init: Id "h1" respawning too fast: disabled for 5 minutes
    Dec 9 04:10:46 drs rpc.mountd: authenticated unmount request from 10.3.141.26:651 for /opt/backup_log/srv (/opt/backup_log)
    Dec 9 04:10:47 drs rpc.mountd: authenticated mount request from 10.3.141.26:657 for /opt/backup_log/websrv (/opt/backup_log)
    Dec 9 04:10:47 drs rpc.mountd: authenticated unmount request from 10.3.141.26:672 for /opt/backup_log/websrv (/opt/backup_log)
    Dec 9 04:10:47 drs rpc.mountd: authenticated mount request from 10.3.141.26:677 for /opt/backup_log/ws (/opt/backup_log)
    Dec 9 04:12:01 drs rpc.mountd: authenticated unmount request from 10.3.141.26:849 for /opt/backup_log/ws (/opt/backup_log)
    Dec 9 04:13:20 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    and database (oracle 10g) is running fine, but i cant figure out what could be the problem, can anyone just help me out on this.
    Jafar

    Hi,
    #h1:35:respawn:/etc/init.d/init.cssd run >/dev/null 2>&1 </dev/null
    by commenting above line in initttab file would stop messaging, is this would have any adverse affect on the database. As its a production server, so i am really taking time to resolve it. Your suggestions are welcome. If there is no harm in commenting the above line then i would go forward to comment that line.
    Thanks
    Jafar>

  • Log4j not logging messages out to weblogic console for custom automatplugin

    Hi,
    We have a custom automation plugin for the OSM application build 381 in our environment(HP-UX Itanium platform). The plugins are bundled in a single ear application "A.ear" which is a mixed bag of pre-defined automation plugins of type XsltSender, XsltAutomator(both InternalReciever as well ExternalReceiver) as well other custom automators(java). For logging of messages in order to aid debugging of custom automators, we are using a logger "com.xyz.osm.plugin" which is also declared in log4j.xml file that is within omslogging.jar. You must already be aware that the build scripts of assembling, deploying ansd registering plugins also includes omslogging.jar are part of the application ear.
    <category name="com.mtsa.osm.plugin">
    <priority value="debug"/>
    </category>
    Below java code snippet is taken from our custom automation plugin classes indicating how the above logger is being used for printing messages.
    //Declaration
    private static Log log = LogFactory.getLog("com.mtsa.osm.plugin");
    mthod1(){
    log.info("xyz");
    In addition to the above logger, the pre-defined automators XsltSender, XsltReceiver also enable logging from xsl files by making the "log" parameter available. Thus we have lines such as the one below in our xsl files that should print messages to the weblogic console.
    <xsl:variable name="addLog1" select="java:info($log, 'transformSiebelActivationRequest: ***** Starting *****')"/>
    The logger that allows printing of these lines is "com.mslv.oms.automation".
    <category name="com.mslv.oms.automation">
    <priority value="info"/>
    </category>
    These configurations should have ideally allowed one to see messages such as one below getting printed out to weblogic console:
    <16-Mar-2012 8:59:36,931 CDT PM> <INFO> <plugin.XSLTReceiver> <ExecuteThread: '19' for queue: 'oms.automation'> <transformSiebelActivationRequest: ***** Starting *****>
    Unfotunately after having done all the above configuration, we are still unable to see any such log messages in the console apart from those emitting from SOP and from <xsl:message> inserted in java & xsl files respectively.
    I also checked if the log4j sub-system is able to correctly initialize after parsing the log4j.xml. It does and one can confirm it by setting system property log4j.debug=true in setDomainEnv.sh file.
    $$$$$$$$ log4j initialization by application classloader for oms.ear application $$$$$$$$$$$$$$$$$$
    log4j: Trying to find [log4j.xml] using context classloader weblogic.utils.classloaders.GenericClassLoader@1592141 finder: weblogic.utils.classloaders.CodeGenClassFinder@1112e85 annotation: oms@.
    log4j: Using URL [zip:/home/osmwl/bea/user_projects/domains/dev04/servers/osmdev04/tmp/_WL_user/oms/amuube/omslogging.jar!/log4j.xml] for automatic log4j configuration.
    log4j: Preferred configurator class: org.apache.log4j.xml.DOMConfigurator
    log4j: System property is :null
    log4j: Standard DocumentBuilderFactory search succeded.
    log4j: DocumentBuilderFactory is: org.apache.xerces.jaxp.DocumentBuilderFactoryImpl
    $$$$$$$$ log4j initialization by application classloader for custom automation plugin xyz.ear application $$$$$$$$$$$$$$$$$$
    log4j: Trying to find [log4j.xml] using context classloader weblogic.utils.classloaders.GenericClassLoader@1b7a8c5 finder: weblogic.utils.classloaders.CodeGenClassFinder@10bc849 annotation: xyz.ear@.
    log4j: Using URL [zip:/home/osmwl/bea/user_projects/domains/dev04/servers/osmdev04/tmp/_WL_user/xyz.ear/ah0eeq/omslogging.jar!/log4j.xml] for automatic log4j configuration.
    log4j: Preferred configurator class: org.apache.log4j.xml.DOMConfigurator
    log4j: System property is :null
    log4j: Standard DocumentBuilderFactory search succeded.
    log4j: DocumentBuilderFactory is: weblogic.xml.jaxp.RegistryDocumentBuilderFactory
    log4j: debug attribute= "false".
    Ironically, logging levels for loggers defined in log4j.xml of oms.ear could be dynamically changed from log4jAdmin.jsp page and the results are immediately visible. However for some reason, loggers defined in log4j.xml of custom plugin application were completely getting ignored. I don't see any warnings or erro messages in the logs indicating that log4j configuration failed for custom application failed. We want to refrain using SOP and <xsl:message> but I am afraid we have no option other than filling up our sources files with them.
    Bottomline, how do we get application B(which in our case is the custom plugin) to log messaged the console just like that done by application A(oms.ear).
    I am sure OSM developers would like to leverage log4j bundled with OSM SDK to log messages that would aid in trouble-shooting during development cycles. Both application ear files have commons-logging-1.1.jar,log4j-1.2.13.jar, omslogging.jar available in their classpaths. In other words, META-INF/MANIFEST.MF file of oms.war(web module within oms.ear) and xyz.jar(ejb module within xyz.ear) has references to these jars.
    Appreciate if one can reply and let me know if they could get log messages to print from custom plugin.
    Thanks
    Edited by: user3693508 on Mar 18, 2012 11:38 AM

    Hi,
    We have a custom automation plugin for the OSM application build 381 in our environment(HP-UX Itanium platform). The plugins are bundled in a single ear application "A.ear" which is a mixed bag of pre-defined automation plugins of type XsltSender, XsltAutomator(both InternalReciever as well ExternalReceiver) as well other custom automators(java). For logging of messages in order to aid debugging of custom automators, we are using a logger "com.xyz.osm.plugin" which is also declared in log4j.xml file that is within omslogging.jar. You must already be aware that the build scripts of assembling, deploying ansd registering plugins also includes omslogging.jar are part of the application ear.
    <category name="com.mtsa.osm.plugin">
    <priority value="debug"/>
    </category>
    Below java code snippet is taken from our custom automation plugin classes indicating how the above logger is being used for printing messages.
    //Declaration
    private static Log log = LogFactory.getLog("com.mtsa.osm.plugin");
    mthod1(){
    log.info("xyz");
    In addition to the above logger, the pre-defined automators XsltSender, XsltReceiver also enable logging from xsl files by making the "log" parameter available. Thus we have lines such as the one below in our xsl files that should print messages to the weblogic console.
    <xsl:variable name="addLog1" select="java:info($log, 'transformSiebelActivationRequest: ***** Starting *****')"/>
    The logger that allows printing of these lines is "com.mslv.oms.automation".
    <category name="com.mslv.oms.automation">
    <priority value="info"/>
    </category>
    These configurations should have ideally allowed one to see messages such as one below getting printed out to weblogic console:
    <16-Mar-2012 8:59:36,931 CDT PM> <INFO> <plugin.XSLTReceiver> <ExecuteThread: '19' for queue: 'oms.automation'> <transformSiebelActivationRequest: ***** Starting *****>
    Unfotunately after having done all the above configuration, we are still unable to see any such log messages in the console apart from those emitting from SOP and from <xsl:message> inserted in java & xsl files respectively.
    I also checked if the log4j sub-system is able to correctly initialize after parsing the log4j.xml. It does and one can confirm it by setting system property log4j.debug=true in setDomainEnv.sh file.
    $$$$$$$$ log4j initialization by application classloader for oms.ear application $$$$$$$$$$$$$$$$$$
    log4j: Trying to find [log4j.xml] using context classloader weblogic.utils.classloaders.GenericClassLoader@1592141 finder: weblogic.utils.classloaders.CodeGenClassFinder@1112e85 annotation: oms@.
    log4j: Using URL [zip:/home/osmwl/bea/user_projects/domains/dev04/servers/osmdev04/tmp/_WL_user/oms/amuube/omslogging.jar!/log4j.xml] for automatic log4j configuration.
    log4j: Preferred configurator class: org.apache.log4j.xml.DOMConfigurator
    log4j: System property is :null
    log4j: Standard DocumentBuilderFactory search succeded.
    log4j: DocumentBuilderFactory is: org.apache.xerces.jaxp.DocumentBuilderFactoryImpl
    $$$$$$$$ log4j initialization by application classloader for custom automation plugin xyz.ear application $$$$$$$$$$$$$$$$$$
    log4j: Trying to find [log4j.xml] using context classloader weblogic.utils.classloaders.GenericClassLoader@1b7a8c5 finder: weblogic.utils.classloaders.CodeGenClassFinder@10bc849 annotation: xyz.ear@.
    log4j: Using URL [zip:/home/osmwl/bea/user_projects/domains/dev04/servers/osmdev04/tmp/_WL_user/xyz.ear/ah0eeq/omslogging.jar!/log4j.xml] for automatic log4j configuration.
    log4j: Preferred configurator class: org.apache.log4j.xml.DOMConfigurator
    log4j: System property is :null
    log4j: Standard DocumentBuilderFactory search succeded.
    log4j: DocumentBuilderFactory is: weblogic.xml.jaxp.RegistryDocumentBuilderFactory
    log4j: debug attribute= "false".
    Ironically, logging levels for loggers defined in log4j.xml of oms.ear could be dynamically changed from log4jAdmin.jsp page and the results are immediately visible. However for some reason, loggers defined in log4j.xml of custom plugin application were completely getting ignored. I don't see any warnings or erro messages in the logs indicating that log4j configuration failed for custom application failed. We want to refrain using SOP and <xsl:message> but I am afraid we have no option other than filling up our sources files with them.
    Bottomline, how do we get application B(which in our case is the custom plugin) to log messaged the console just like that done by application A(oms.ear).
    I am sure OSM developers would like to leverage log4j bundled with OSM SDK to log messages that would aid in trouble-shooting during development cycles. Both application ear files have commons-logging-1.1.jar,log4j-1.2.13.jar, omslogging.jar available in their classpaths. In other words, META-INF/MANIFEST.MF file of oms.war(web module within oms.ear) and xyz.jar(ejb module within xyz.ear) has references to these jars.
    Appreciate if one can reply and let me know if they could get log messages to print from custom plugin.
    Thanks
    Edited by: user3693508 on Mar 18, 2012 11:38 AM

  • Sun logs: /var/adm/messages vs. /var/svc/log/*

    On Solaris 10, is /var/adm/messages still the "gold standard" for startup and shutdown log messages, or have the critical logs moved to /var/svc/log/$service_name?
    It's not like I can't look in one or the other, but I'm trying to gauge the relative importance of the two.
    Is there another location that I'm overlooking?

    aaron.m wrote:
    On Solaris 10, is /var/adm/messages still the "gold standard" for startup and shutdown log messages, or have the critical logs moved to /var/svc/log/$service_name?Depends on what you mean by "startup" messages. There are two types I can think of.
    During boot the kernel might generate a few messages about drivers and buffers and stuff. This is stored in a kernel buffer that is visible when you type 'dmesg'. When syslog starts up, it dumps the contents into the messages file so you have a static copy. I don't think this behavior changes between Solaris 9 and Solaris 10.
    For the actual startup "scripts" (SMF, /etc/init.d, /etc/rc?), Solaris 9 and earlier didn't have any sort of capture location. It was common for scripts to print to STDOUT/STDERR, and that would be delivered to the console only. Since many of the scripts are running before filesystems are mounted read/write, it didn't try to save the output.
    Now with SMF, it does more work to capture that output and you can find that in the service log files that you mention.
    So none of the logs have really moved, but you now have more logs than you did before.
    Darren

  • Error Mesages in /var/log/messages

    Hi,
    Dec 9 04:03:08 drs syslogd 1.4.1: restart (remote reception).
    Dec 9 04:03:18 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:03:18 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:03:18 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:03:18 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:03:18 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:03:18 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:03:18 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:03:18 drs init: Id "h1" respawning too fast: disabled for 5 minutes
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    Dec 9 04:08:19 drs logger: Could not access /etc/oracle/scls_scr/drs/root/crsstart.
    Dec 9 04:08:19 drs init: Id "h1" respawning too fast: disabled for 5 minutes
    Dec 9 04:10:46 drs rpc.mountd: authenticated unmount request from 10.3.141.26:651 for /opt/backup_log/srv (/opt/backup_log)
    Dec 9 04:10:47 drs rpc.mountd: authenticated mount request from 10.3.141.26:657 for /opt/backup_log/websrv (/opt/backup_log)
    Dec 9 04:10:47 drs rpc.mountd: authenticated unmount request from 10.3.141.26:672 for /opt/backup_log/websrv (/opt/backup_log)
    Dec 9 04:10:47 drs rpc.mountd: authenticated mount request from 10.3.141.26:677 for /opt/backup_log/ws (/opt/backup_log)
    Dec 9 04:12:01 drs rpc.mountd: authenticated unmount request from 10.3.141.26:849 for /opt/backup_log/ws (/opt/backup_log)
    Dec 9 04:13:20 drs logger: Oracle Cluster Ready Services disabled by corrupt install
    I observed above mesages in /var/log/messages, can anyone tell what does it mean
    Version - oracle 10g
    Platform - Linux.
    Thanks
    Jafar

    Hi,
    #h1:35:respawn:/etc/init.d/init.cssd run >/dev/null 2>&1 </dev/null
    by commenting above line in initttab file would stop messaging, is this would have any adverse affect on the database. As its a production server, so i am really taking time to resolve it. Your suggestions are welcome. If there is no harm in commenting the above line then i would go forward to comment that line.
    Thanks
    Jafar

  • Permanently set /var/log/messages* to mode 644

    What process constantly changes /var/log/messages* mode back to 640? I want to disable that. Thanks.

    I would guess logrotate.  Have you checked /etc/logrotate.d/syslog?  Does it specify a particular permission there?
    If not specified, logrotate should retain the permissions of the existing file.
    Marc

  • How to move weblogic.log to /var/logs

    Weblogic Server 5.1, Sun Solaris 5.8
    How do I change the path for this log file ?
    Thank you,
    -pete

    "Pete Lancashire" <[email protected]> wrote:
    >
    Weblogic Server 5.1, Sun Solaris 5.8
    How do I change the path for this log file ?
    Thank you,
    -peteYou can change the location of the weblogic.log file by setting weblogic.system.logFile
    to be wherever you want is to go.
    ex. weblogic.system.logFile=/var/logs/weblogic.log
    Hope it helps

  • GG writing more info to /var/log/messages

    Dear All,
    Thank you very much for your continuous support .
    GG version: 11.2
    DB version: 11.2
    OS: OEL 5
    Am seeing log of info being writtent to /var/log/messages.
    AS per reference guide, i have used SYSLOG NONE parameter in GLOBALS file but still am seeing info is being written to /var/log/messages file.
    i have tried SYSLOG ERROR and SYSLOG ERROR, WARN
    but still GG is writing INFO messages to messages file.
    Could some one help me to resolve it.
    Thank you very much in advance
    Best Regards
    Vamshi

    There could be two reasons:
    1. You have to exit GGSCI and restart again for GLOBALS changes to take effect, which you may not have done.
    2. you might still be using SYSLOG in manager parameter file which overrides the GLOBALS setting as per the below explaination from Oracle.
    "You can use SYSLOG as a GLOBALS or Manager parameter, or both. When present in the GLOBALS parameter file, it controls message filtering for all of the Oracle GoldenGate processes on the system. When present in the Manager parameter file, it controls message filtering only for the Manager process. If used in both the GLOBALS and Manager parameter files, the Manager setting overrides the GLOBALS setting for the Manager process."

  • Cmn_err doesnt log to /var/adm/messages

    HI,
    I am trying cmn_err to log my messages using different error level. But it is not logging messages to /var/adm/messages file, also not printing on console. I have tried diff options like ! ^ etc. but all efforts proved futile. Can anyone help me?
    - Mayur Talati

    We had a problem on one system similar to yours.
    It tured out that the problem was caused by someone
    removing /usr/ccs/bin/m4 in order to favor a locally
    installed version of m4 in /usr/local/bin. The problem is,
    the syslog daemon needs to find m4 when it starts
    and apparently it must be in /usr/ccs/bin/m4.
    Check if you have /usr/ccs/bin/m4 on your system and
    look in /var/adm/messages for any syslogd startup errors.

  • Logging to weblogic.log

     

    hi
    i need couple of clarifications with regard to implementation of logging with
    weblogic.
    a) Is logging implemented using JMS? ( Is logging asynchronous?)
    b) I am wondering if i can use logging api into some helper classes that wouldn't
    be run in weblogic server. If weblogic server is a pre-requisite, then i will
    not be able to use this logging api in these classes.
    Thanks
    Rob Woollen <[email protected]> wrote:
    From server-side code (ie servlets or EJB). do
    LogServiceDef log = T3Services.getT3Services().log();
    to get the log, and then you can use log.inform(), log.debug, or
    log.error as appropriate.
    See
    http://www.weblogic.com/docs45/classdocs/weblogic.common.LogServicesDef.html
    -- Rob
    Rob Woollen
    Software Engineer
    BEA WebLogic
    [email protected]
    Vinny Carpenter wrote:
    Hi there. I have a cluster of WebLogic 4.5.1 servers running under
    Solaris 2.6. My application consists of two EJB's and a couple of
    servlets as front end. As part of the application logging process,I
    output certain text using System.out.println and System.err.printlnthat
    are typically displayed on the console.
    How can I redirect those messages to the machine's weblogic.log file??
    Is there a logging mechanism that will allow me to do that?? thanks
    --Vinny

  • Overhead in weblogic logging

    Does anyone have an info on the performance overhead of logging within
    weblogic (6.1 sp2). There doesn't seem to be a way to turn down the
    logging to weblogic.log from info to something like error or warning
    level. I thought the StdoutSeverityLevel parameter would do that but it
    only controls what is written to standard out not the weblogic.log.
    Also, should the access log be enabled in production systems? Since it
    writes a line to the log for every http hit, I was wondering what kind
    of performance overhead that might make.
    Kirk

    FYI: The LogToStdOut option only applies to the console output, not the
    weblogic.log file.
    Nils
    Pamal wrote:
    >
    Hi,
    You can turn off complete logging by unchecking the Log to Stdout in WebLogic
    administration console. Or the same can be achieved by giving the following in
    config.xml
    <WebServer DefaultWebApp=""
    LogFileName="./config/petstore/logs/access.log"
    LoggingEnabled="false" Name=""/>
    You can also set the level of logging to Info, Debug etc
    Regards,
    Pamal
    Rob Woollen <[email protected]> wrote:
    I don't believe there's any current way to limit what gets written to
    the
    weblogic.log.
    Writes to the access.log are buffered internally in the server so their
    performance impact shouldn't be too big.
    FWIW, I'd recommend that you run performance tests on your application
    first and
    then consider turning off logging only if it has a significant impact.
    -- Rob
    Kirk Everett wrote:
    I totally agree and was only thinking about doing this in a productionenv. I
    just wanted to know if you could (or should) turn off the access.logand the
    weblogic.log. Is there even a way to turn down what gets put in the
    weblogic.log?
    Kirk
    Cameron Purdy wrote:
    Logging can be expensive, but only consider this once you have a
    stable
    application. Usually the application-level (not server-level) loggingis the
    prime culprit, and you can reduce this with clever use of the deletekey in
    source code files. You can also redirect stdout and stderr to nuland you
    can turn off logging options once you are sure that things are stable.
    Peace,
    Cameron Purdy
    Tangosol, Inc.
    Clustering Weblogic? You're either using Coherence, or you shouldbe!
    Download a Tangosol Coherence eval today at http://www.tangosol.com/
    "Kirk Everett" <[email protected]> wrote in message
    news:[email protected]...
    Does anyone have an info on the performance overhead of logging
    within
    weblogic (6.1 sp2). There doesn't seem to be a way to turn downthe
    logging to weblogic.log from info to something like error or warning
    level. I thought the StdoutSeverityLevel parameter would do thatbut it
    only controls what is written to standard out not the weblogic.log.
    Also, should the access log be enabled in production systems? Sinceit
    writes a line to the log for every http hit, I was wondering whatkind
    of performance overhead that might make.
    Kirk
    ============================
    [email protected]

  • Cluster & Weblogic logs

    Hi.,
              I have set up a weblogic cluster running from a shared disk. Currently both
              servers create their log files (Weblogic.log) in their directories on the
              shared disk. I would like the log to be on the local drive. When I try and
              change the file location with a fully qualified directory and filename,
              instead of creating the logfile on the local drive as expected, for some
              reason the fully qualified path is appended to the cluster directory on the
              shared disk.
              Is this a bug ?
              Eran
              

    We ran into a similar problem and solved it by making the per-server
              directories underneath the cluster home directory symlinks to the local
              disk, rather than actual directories on the shared filesystem.
              So if your cluster directory is /cluster:
              /cluster
              /cluster/server1 -> /var/log
              /cluster/server2 -> /var/log
              /cluster/server3 -> /var/log
              The symlinks get resolved relative to the NFS client they're on - so each
              server ends up writing its logs to local disk at /var/log. The drawback is
              that your per-server properties files (if any) need to be on the local
              disks, rather than on the shared filesystem. But you could probably get
              around this by linking from /var/log back into the shared filesystem (not
              sure...we don't have per-server props files).
              Ideally I'd rather be able to just give the logfile a fully-qualified
              pathname rather than this weird symlink stuff, but this seems to work...
              Mike Benham <[email protected]> wrote in message
              news:[email protected]...
              >
              > Yes this is a bug that has been identified. We should accept both
              > fully qualified and relative path names. It should be fixed in the next
              > maintenance release, but I suppose you could hack functionality by using
              > relative pathnames until then:
              > "../../../../dir/outside/of/weblogic/install" =)
              >
              > - Mike
              >
              >
              >
              > Jean-François ESPERET wrote:
              > >
              > > Eran Shtiegman a écrit :
              > >
              > > > Hi.,
              > > >
              > > > I have set up a weblogic cluster running from a shared disk.
              Currently both
              > > > servers create their log files (Weblogic.log) in their directories on
              the
              > > > shared disk. I would like the log to be on the local drive. When I
              try and
              > > > change the file location with a fully qualified directory and
              filename,
              > > > instead of creating the logfile on the local drive as expected, for
              some
              > > > reason the fully qualified path is appended to the cluster directory
              on the
              > > > shared disk.
              > > >
              > > > Is this a bug ?
              > > >
              > > > Eran
              > >
              > > I've got the same problem and it seems to be a bug and I'll tell you why
              I think
              > > so:
              > > we're running Weblogic under Solaris 2.6 Sparc and when we put a fully
              qualified
              > > directory and filename (unix), it creates a directory starting with 'c:'
              . I
              > > mean it creates a MS Windows like directory into an Unix filesystem.
              

  • Weblogic.log

    Hi,
              I am using weblogic5.1. I use System.out.println() to output messages to Weblogic console. But I cannot see these messages in weblogic.log. If I start weblogic as Windows service, since there is no weblogic console, I cannot see any messages outputed using System.out.print(). Is there any way to configure such that I can direct System.out.println() messages to weblogic.log, or any other file so I can view these messages.
              Thanks a lot.
              Zhe
              

    [email protected] wrote:
              > I would want to think so to,
              > But I guess Weblogic grabs the Out variable first (and make a private copy
              > for itself ...?)
              Strange - I thought it does this to redirect all System.out.println's to it's
              log, but looking at the System.out in the debugger shows that it's the same
              one System.initializeSystemClass() created.
              > Dimitri do you know of any "undocumented" JDK property to set the standard
              > op stream ...other than
              > java xxx > mylog.txt ?
              Nop. I guess you can get clever and do it as a part of the 1.4 logging initialization
              (called by System.initializeSystemClass()).
              > peace,
              > _NR
              > "Dimitri I. Rakitine" <[email protected]> wrote in message
              > news:[email protected]...
              >> [email protected] wrote:
              >> > Hmmm..tough call.. A cheap way would be to set
              >>
              >> > System.setOut(PrintStream out) to some file or something... before the
              > first
              >>
              >> I thought that WebLogic does it by itself, doesn't it?
              >>
              >> > System.out.printX() gets called...
              >>
              >> > peace,
              >> > -NR
              >>
              >>
              >>
              >>
              >>
              >>
              >>
              >>
              >>
              >> > "Zhe Liu" <[email protected]> wrote in message
              >> > news:[email protected]...
              >> >>
              >> >> Thank you very much for you reply.
              >> >>
              >> >> Does that mean I have to use the LogServicesDef to replace all
              > System.out
              >> > in my
              >> >> code? I am wondering whether there is a way to see the System.out
              > messages
              >> > without
              >> >> changing code, say, just change the configuration or
              > weblogic.properties.
              >> > I have
              >> >> many JSP pages and I am encounting a problem that weblogic will die by
              >> > itsself
              >> >> in production. But I have no idea which page may cause the problem. It
              >> > will be
              >> >> very helpful if I can see all the messages sending to System.out. But
              > it
              >> > is difficult
              >> >> to change all source code in a short time.
              >> >>
              >> >> Zhe
              >> >>
              >> >> <[email protected]> wrote:
              >> >> >As far as I remember there is a way to do that in WLS 5.1 ,using the
              >> >> >LogServicesDef and I am not sure if they were deprecated !!
              >> >> >
              >> >> >http://www.weblogic.com/docs51/classdocs/API_t3.html#services
              >> >> >
              >> >> >and
              >> >> >
              >> >> >http://www.weblogic.com/docs51/classdocs/API_servlet.html
              >> >> >
              >> >> >T3ServicesDef t3s = T3Services.getT3Services();String consoleEnabled
              >> >> >=
              >> >> >t3s.config().getProperty("weblogic.system.enableConsole");String
              > logmsg
              >> >> >=
              >> >> >"bla set to " + bla + " at " + new
              >> >> >java.util.Date();LogServicesDef logger = t3s.log();logger.log(logmsg);
              >> >> >"Zhe Liu" <[email protected]> wrote in message
              >> >> >news:[email protected]...
              >> >> >> Hi,
              >> >> >>
              >> >> >> I am using weblogic5.1. I use System.out.println() to output
              > messages
              >> >> >to
              >> >> >Weblogic console. But I cannot see these messages in weblogic.log. If
              >> >> >I
              >> >> >start weblogic as Windows service, since there is no weblogic console,
              >> >> >I
              >> >> >cannot see any messages outputed using System.out.print(). Is there
              > any
              >> >> >way
              >> >> >to configure such that I can direct System.out.println() messages to
              >> >> >weblogic.log, or any other file so I can view these messages.
              >> >> >>
              >> >> >> Thanks a lot.
              >> >> >>
              >> >> >> Zhe
              >> >> >
              >> >> >
              >> >>
              >>
              >>
              Dimitri
              

  • How to write  to weblogic.log from JSP ?

    It is possible to write some messages to weblogic.log from JSP?
              

    Use weblogic.logging.LogOutputStream class to log messages into
              weblogic.log file.
              javap on weblogic.logging.LogOutputStream
              for e.g
              <%@ page import="weblogic.logging.*" %>
              <%
              LogOutputStream los = new LogOutputStream("TEST");
              los.error("Writing into Log file");
              %>
              Hope this helps.
              --kumar allamraju
              Mikhail Ershov wrote:
              > It is possible to write some messages to weblogic.log from JSP?
              

  • Using GenericPortlet sublcass .. cannot get any log messages to come out.

    Hi all ..
    I'm having a lot of problems getting any exceptions or log messages dumped from my portlet to help me debug.
    I'm currently using subclass of javax.portlet.GenericPortlet and not a sublcass of com.sun.portal.providers.jsp.JSPProvider. Does that matter? Anyone know if there are issues that I might be running into here?
    More details ..
    I've tried making nice PortletException wrappers around all sorts of other exceptions .. and even using the API call:
    GenericPortlet.getPortletContext().log(<msg>,<throwable> )
    I've tweaked every debug/log/show exception config setting I can find .. including setting logger.log.level=ALL in:
    /etc/opt/SUNWps/portlet/PDConfig.properties
    It'll mostly fail with nada .. zilch .. zero. No hint or reason why. Occasionally I'll get something useful and I'll see an exception I made .. but the other 95% of the time I get no hint.
    I've a script that searches for any file touched in /opt/SUNW*, /var/opt/SUNW* and /etc/opt/SUNW*. I regularly get the following files touched:
    /var/opt/SUNWam/debug/portletcontainer.log
    /var/opt/SUNWam/debug/<myportlet>.log
    /var/opt/SUNWam/debug/desktop.debug
    Can anyone tell me where I should expect to see PortletExceptions logged? How do I turn that feature on .. just in case I've missed the config I need to change? Has anyone had any luck using the PortletContext.log(<msg>,<throwable) API calls? Is there some config that controls where that goes? (I would've assumed it all goes in the <myportlet>.log file .. but not for me.)
    Many thanks for your time ..
    Curtis.
    p.s. Below is an example of some of the messages I do see.
    One instance I get "ERROR: Content not available" .. I get a series of
    rather unhelpful internal exceptions that (for example) complain the portlet threw an exception of some sort. If only the root cause had been printed out it would be possible to nail exactly what's going on in my code that's the issue. Unfortunately this style of "black box" debugging is taking me 10 times (literally .. honestly!) longer than it should. I have to comment out stuff and slowly add it back in again .. if only I could've seen the exception.
    (NOTE: I modifed PrefPortlet.java example .. still called the same at the minute :-) )
    From log file /var/opt/SUNWam/debug/desktop.debug ..
    06/09/2004 09:25:08:066 PM PDT: Thread[Thread-76,5,main]
    ERROR: ProviderCaller.run(): exception thrown from PrefPortlet
    com.sun.portal.providers.ProviderException: PortletWindowProvider.getContent():container exc
    eptioncom.sun.portal.container.ContainerException: PortletContainer.getMarkup():getting cont
    ent com.sun.portal.container.ContentException: PortletContainer.getMarkup(): Cannot get cont
    ent
    at com.sun.portal.providers.portletwindow.PortletWindowProvider.getContent(PortletWi
    ndowProvider.java:284)
    at com.sun.portal.desktop.context.ReusableProviderCaller.run(ReusableProviderCaller.
    java:158)
    com.sun.portal.container.ContainerException: PortletContainer.getMarkup():getting content co
    m.sun.portal.container.ContentException: PortletContainer.getMarkup(): Cannot get content
    at com.sun.portal.container.portlet.impl.PortletContainer.getMarkup(PortletContainer
    .java:201)
    [snip]
    (not much help really)
    From the file /var/opt/SUNWam/debug/<myportlet>.log (my specific portlet log) ..
    2004/06/09 21:25:08.058 PDT | Curtis First Port | SEVERE | Thread-76 | Portle
    tAppEngineServlet.HandleError()() - Error: null | LifecycleManagerImpl.getPortlet(),
    can not get portlet.
    x -----------------------------------------------------------------------------
    X javax.portlet.PortletException: LifecycleManagerImpl.getPortlet(), can not get por
    tlet.
    X at com.sun.portal.portletappengine.impl.LifecycleManagerImpl.getPortlet(Life
    cycleManagerImpl.java:163)
    X at com.sun.portal.portletappengine.PortletAppEngineServlet.service(PortletAp
    pEngineServlet.java:187)
    X at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
    [snip]
    (still not much help)
    Note .. i sometimes get useful exceptions dumped to that last file .. but
    it's rare .. I just can't seem to spot the pattern when they will and won't
    get printed.
    From file /var/opt/SUNWam/debug/portletcontainer.log
    2004/06/09 21:25:07.414 PDT | null | INFO | Thread-76 | Portle
    tContainer.invokePAE(): invoking:
    app name /<myportlet>
    portlet name PrefPortlet
    action RENDER | -
    2004/06/09 21:25:08.063 PDT | null | SEVERE | Thread-76 | Portle
    tContainer:executeAction(): Exception thrown from render() of <myportlet>|PrefPortlet
    |PrefPortlet | -
    [snip]
    (the least helpful of all!!)
    When I simply comment out the new code I added, recompile, and view the portlet again .. it works fine. If I could only see the root cause exception!!

    Ok .. weirder and weirder ...
    I left this for a while .. and then went back to my xterms where I was working .. and one of them I saw this:
    # Jun 9 21:55:14 troy server1 appservd[7440]: [ID 702911 daemon.alert] SEVERE ( 7440): hefalump - Problem setting up PAL array!
    Jun 9 21:55:14 troy java.io.FileNotFoundException: http://pie1.some.thing.com/portal/arraylist.xml
    Jun 9 21:55:14 troy at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:789)
    Jun 9 21:55:14 troy at java.net.URL.openStream(URL.java:913)
    Jun 9 21:55:14 troy at com.tarantella.portal.bell.test.WebtopHostFinder.<init>(WebtopHostFinder.java:42)
    Jun 9 21:55:14 troy at com.some.portal.test.PrefPortlet.init(PrefPortlet.java:72)
    Jun 9 21:55:14 troy at com.sun.portal.portletappengine.impl.LifecycleManagerImpl.createPortlets(LifecycleManagerImpl.java:329)
    Jun 9 21:55:14 troy at com.sun.portal.portletappengine.impl.LifecycleManagerContextListenerImpl.contextInitialized(LifecycleManagerContextListenerImpl.java:13)
    Jun 9 21:55:14 troy at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3255)
    Jun 9 21:55:14 troy at org.apache.catalina.core.StandardContext.reload(StandardContext.java:2525
    Jun 9 21:55:14 troy at com.sun.portal.portletappengine.impl.LifecycleManagerImpl.init(LifecycleManagerImpl.java:109)
    That is exactly the information I'm looking for!!!
    I've no idea how it got there .. I think the appservd process just dumped it there .. after I saw this I grep'ed the entire set of files in /opt/SUNW* /var/opt/SUNW* /etc/opt/SUNW* for "hefalump" (my unique 'log' key) and it's not in any log file.
    Anyone know what's going on?
    Curtis.

Maybe you are looking for

  • Firefox will not display Yahoo Calendar.

    Firefox will not display Yahoo Calendar (I have tried on four separate computers). When I use Internet Explorer, the Yahoo Calendar does display fine. Do you know why Yahoo Calendar will not display in Firefox? Is there any solution?

  • How to find programatically where the iView is present in page layout

    Hi all,     I have a iView (Abs Portal comp) in the page which has wideNarow layout . i have a requirement to find where the iView is loaded in the page i.e ) either in Wide column or Narrow column . Based on that i want to reduce/increase the size o

  • I have forgotten the root password

    I have forgotten the root pasword on my powerbook, how do I reset it?

  • Contracts and Services

    Hi, can anyone explain the difference between contracts and services in detail. Thanks, kiran.

  • Filters - planar tiling; kalaidescope

    I was looking to buy some filters to replace what I used to use with Kai's Power Tools. Like its planar tiling and kalaidescope filters. I found that Corel has taken over this software, and the filters listed do not appear to contain these two that w