glassfish
  1. glassfish
  2. GLASSFISH-20718

Write to System Log option do not send log on localhost udp port 514

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Critical Critical
    • Resolution: Unresolved
    • Affects Version/s: 4.0_b89_RC5
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Environment:

      Linuw Debian 7 64 bits, kernel 3.8.13, Java(TM) SE Runtime Environment (build 1.7.0_25-b15)

      Description

      When I check the box "Write to System Log" in the "server-config/Logger Settings" page of the admin GUI and I restart the domain I don't have anything on syslog.
      I used this option on Glassfish 3.1.1 (build 12) with no problem.

      Rsyslog is well configured and listening on port udp 514 :
      netstat -putwln | grep rsyslog
      udp 0 0 0.0.0.0:514 0.0.0.0:* 19488/rsyslogd
      udp6 0 0 :::514 :::* 19488/rsyslogd

      I have used tcpdump to see if anything coming in :
      tcpdump udp port 514 -vv -i lo

      But I see nothing when I do stuff like restarting the domain, etc.

        Activity

        Hide
        amais33 added a comment -

        I forget to say that port UDP 514 is open for localhost

        Show
        amais33 added a comment - I forget to say that port UDP 514 is open for localhost
        Hide
        obfischer added a comment -

        Same problem here with Glassfish 4.0.1-SNAPSHOT. So it is reproduceable.

        Show
        obfischer added a comment - Same problem here with Glassfish 4.0.1-SNAPSHOT. So it is reproduceable.
        Hide
        dbcjbn added a comment -

        Also reproducible on GlassFish 4.1

        To fix just change
        handlerServices=com.sun.enterprise.server.logging.GFFileHandler
        into
        handlerServices=com.sun.enterprise.server.logging.GFFileHandler,com.sun.enterprise.server.logging.SyslogHandler
        in logging.properties file under domain config. This omission still seems like a bug to me though.

        Show
        dbcjbn added a comment - Also reproducible on GlassFish 4.1 To fix just change handlerServices=com.sun.enterprise.server.logging.GFFileHandler into handlerServices=com.sun.enterprise.server.logging.GFFileHandler,com.sun.enterprise.server.logging.SyslogHandler in logging.properties file under domain config. This omission still seems like a bug to me though.
        Hide
        smillidge-c2b2 added a comment -

        Source Patch is
        ----------------------

        From 77e3fecc204f5891645657bd1369f39e353b1d25 Mon Sep 17 00:00:00 2001
        From: Steve Millidge <smillidge-AT-c2b2.co.uk>
        Date: 13-Sep-2014 22:57:06

        Fix SysLogger configuration

        diff --git a/nucleus/admin/template/src/main/resources/config/logging.properties b/nucleus/admin/template/src/main/resources/config/logging.properties
        index 5e01339..34ecb43 100644
        — a/nucleus/admin/template/src/main/resources/config/logging.properties
        +++ b/nucleus/admin/template/src/main/resources/config/logging.properties
        @@ -42,7 +42,7 @@
        #Update Thurs Oct 18 2012
        #All attributes details
        handlers=java.util.logging.ConsoleHandler
        -handlerServices=com.sun.enterprise.server.logging.GFFileHandler
        +handlerServices=com.sun.enterprise.server.logging.GFFileHandler,com.sun.enterprise.server.logging.SyslogHandler
        java.util.logging.ConsoleHandler.formatter=com.sun.enterprise.server.logging.UniformLogFormatter
        com.sun.enterprise.server.logging.GFFileHandler.formatter=com.sun.enterprise.server.logging.ODLLogFormatter
        com.sun.enterprise.server.logging.GFFileHandler.file=$

        {com.sun.aas.instanceRoot}

        /logs/server.log
        @@ -64,6 +64,7 @@

        #All log level details
        com.sun.enterprise.server.logging.GFFileHandler.level=ALL
        +com.sun.enterprise.server.logging.SyslogHandler.level=ALL
        javax.enterprise.system.tools.admin.level=INFO
        org.apache.jasper.level=INFO
        javax.enterprise.system.core.level=INFO

        Show
        smillidge-c2b2 added a comment - Source Patch is ---------------------- From 77e3fecc204f5891645657bd1369f39e353b1d25 Mon Sep 17 00:00:00 2001 From: Steve Millidge <smillidge-AT-c2b2.co.uk> Date: 13-Sep-2014 22:57:06 Fix SysLogger configuration diff --git a/nucleus/admin/template/src/main/resources/config/logging.properties b/nucleus/admin/template/src/main/resources/config/logging.properties index 5e01339..34ecb43 100644 — a/nucleus/admin/template/src/main/resources/config/logging.properties +++ b/nucleus/admin/template/src/main/resources/config/logging.properties @@ -42,7 +42,7 @@ #Update Thurs Oct 18 2012 #All attributes details handlers=java.util.logging.ConsoleHandler -handlerServices=com.sun.enterprise.server.logging.GFFileHandler +handlerServices=com.sun.enterprise.server.logging.GFFileHandler,com.sun.enterprise.server.logging.SyslogHandler java.util.logging.ConsoleHandler.formatter=com.sun.enterprise.server.logging.UniformLogFormatter com.sun.enterprise.server.logging.GFFileHandler.formatter=com.sun.enterprise.server.logging.ODLLogFormatter com.sun.enterprise.server.logging.GFFileHandler.file=$ {com.sun.aas.instanceRoot} /logs/server.log @@ -64,6 +64,7 @@ #All log level details com.sun.enterprise.server.logging.GFFileHandler.level=ALL +com.sun.enterprise.server.logging.SyslogHandler.level=ALL javax.enterprise.system.tools.admin.level=INFO org.apache.jasper.level=INFO javax.enterprise.system.core.level=INFO

          People

          • Assignee:
            michael.y.chen
            Reporter:
            amais33
          • Votes:
            2 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

            • Created:
              Updated: