Uploaded image for project: 'Hadoop Common'
  1. Hadoop Common
  2. HADOOP-2809

[HOD] Syslog configuration, syslog-address, does not work in HOD 0.4

Details

    • Bug
    • Status: Closed
    • Critical
    • Resolution: Fixed
    • 0.16.0
    • 0.16.1
    • contrib/hod
    • None

    Description

      Specify the parameter syslog-address as host:port in the ringmaster or hodring sections in a hod configuration file. Run a hod allocation. It fails with error code 5/6. The ringmaster fails to start. No logs are created.

      The problem seems to be that we are passing in the syslog-address in a format different from what is expected to the hodLogger object.

      Attachments

        1. patch_2809.3
          14 kB
          Hemanth Yamijala
        2. patch_2809.2
          14 kB
          Hemanth Yamijala
        3. patch_2809.1
          13 kB
          Vinod Kumar Vavilapalli
        4. patch_2809
          5 kB
          Vinod Kumar Vavilapalli

        Activity

          Patch attached. Tested by a basic allocation, enabling logging to syslog, ran hadoop wordcount job, checked that messages are getting logged through syslog and finally done a deallocation.

          Currently HOD uses syslog cron facility( LOG_CRON, 9 ). So all messages reach syslog under cron facility. Default SysLogLevel is 3 and the format is "(%(process)d) %(levelname)s/%(levelno)s %(module)s:%(lineno)s - %(message)s"

          vinodkv Vinod Kumar Vavilapalli added a comment - Patch attached. Tested by a basic allocation, enabling logging to syslog, ran hadoop wordcount job, checked that messages are getting logged through syslog and finally done a deallocation. Currently HOD uses syslog cron facility( LOG_CRON, 9 ). So all messages reach syslog under cron facility. Default SysLogLevel is 3 and the format is "(%(process)d) %(levelname)s/%(levelno)s %(module)s:%(lineno)s - %(message)s"

          Just one minor comment. Please remove the print statements in getLogger which display what is installed.

          Other than this, +1

          yhemanth Hemanth Yamijala added a comment - Just one minor comment. Please remove the print statements in getLogger which display what is installed. Other than this, +1

          some changes to be made in the patch. Discovered previously unknown bug.

          vinodkv Vinod Kumar Vavilapalli added a comment - some changes to be made in the patch. Discovered previously unknown bug.
          • Removed the print statements that crept in.
          • Fixed in hodring, a bug related to syslog address. This seems not to have been found earler due to a possible non-usage so far of logging to syslog on hodring.
          • Forcing syslog addresses to be validated, to catch invalid addresses(e.g 'host', 'host:' etc) on the client side and avoiding failures on compute nodes.
          • Changes done to ringmaster w.r.t the bug had to done in ringmaster and hodcleanup too. Done that now.
          • Rest of the changes involve refactoring the code, with respect to the changes mentioned in the point immediately above.

          Tested with ringmaster and hodring pointed to syslogd and syslogng, by allocating nodes, running hadoop wordcount and deallocating. hodcleanup uses the same log as hodring, so no special tests here. Currently, logging to syslogd/syslog-ng can be only via udp ports, and not tcp ports; this is because of the way python built-in sylog module is written.

          vinodkv Vinod Kumar Vavilapalli added a comment - Removed the print statements that crept in. Fixed in hodring, a bug related to syslog address. This seems not to have been found earler due to a possible non-usage so far of logging to syslog on hodring. Forcing syslog addresses to be validated, to catch invalid addresses(e.g 'host', 'host:' etc) on the client side and avoiding failures on compute nodes. Changes done to ringmaster w.r.t the bug had to done in ringmaster and hodcleanup too. Done that now. Rest of the changes involve refactoring the code, with respect to the changes mentioned in the point immediately above. Tested with ringmaster and hodring pointed to syslogd and syslogng, by allocating nodes, running hadoop wordcount and deallocating. hodcleanup uses the same log as hodring, so no special tests here. Currently, logging to syslogd/syslog-ng can be only via udp ports, and not tcp ports; this is because of the way python built-in sylog module is written.

          Attached patch is a minor modification over Vinod's which basically prints out a nice error message for an invalid format syslog-address. Other than that +1 for Vinod's patch.

          yhemanth Hemanth Yamijala added a comment - Attached patch is a minor modification over Vinod's which basically prints out a nice error message for an invalid format syslog-address. Other than that +1 for Vinod's patch.

          +1 for Hemanth's change.

          Submitting now.

          vinodkv Vinod Kumar Vavilapalli added a comment - +1 for Hemanth's change. Submitting now.
          hadoopqa Hadoop QA added a comment -

          -1 overall. Here are the results of testing the latest attachment
          http://issues.apache.org/jira/secure/attachment/12376710/patch_2809.2
          against trunk revision 619744.

          @author +1. The patch does not contain any @author tags.

          tests included -1. The patch doesn't appear to include any new or modified tests.
          Please justify why no tests are needed for this patch.

          javadoc +1. The javadoc tool did not generate any warning messages.

          javac +1. The applied patch does not generate any new javac compiler warnings.

          release audit +1. The applied patch does not generate any new release audit warnings.

          findbugs +1. The patch does not introduce any new Findbugs warnings.

          core tests +1. The patch passed core unit tests.

          contrib tests +1. The patch passed contrib unit tests.

          Test results: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/1860/testReport/
          Findbugs warnings: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/1860/artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html
          Checkstyle results: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/1860/artifact/trunk/build/test/checkstyle-errors.html
          Console output: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/1860/console

          This message is automatically generated.

          hadoopqa Hadoop QA added a comment - -1 overall. Here are the results of testing the latest attachment http://issues.apache.org/jira/secure/attachment/12376710/patch_2809.2 against trunk revision 619744. @author +1. The patch does not contain any @author tags. tests included -1. The patch doesn't appear to include any new or modified tests. Please justify why no tests are needed for this patch. javadoc +1. The javadoc tool did not generate any warning messages. javac +1. The applied patch does not generate any new javac compiler warnings. release audit +1. The applied patch does not generate any new release audit warnings. findbugs +1. The patch does not introduce any new Findbugs warnings. core tests +1. The patch passed core unit tests. contrib tests +1. The patch passed contrib unit tests. Test results: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/1860/testReport/ Findbugs warnings: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/1860/artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html Checkstyle results: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/1860/artifact/trunk/build/test/checkstyle-errors.html Console output: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/1860/console This message is automatically generated.

          This bug is jinxed. I found another minor issue in my earlier patch. Uploading a new one, after canceling this.

          yhemanth Hemanth Yamijala added a comment - This bug is jinxed. I found another minor issue in my earlier patch. Uploading a new one, after canceling this.

          Minor change to previous patch. There was a bug in hodcleanup, where if syslog address is not specified, hodcleanup wasn't working. Fixed that in this patch.

          yhemanth Hemanth Yamijala added a comment - Minor change to previous patch. There was a bug in hodcleanup, where if syslog address is not specified, hodcleanup wasn't working. Fixed that in this patch.

          Run by Hudson.

          No automated unit tests until Hadoop 2775 is resolved.

          yhemanth Hemanth Yamijala added a comment - Run by Hudson. No automated unit tests until Hadoop 2775 is resolved.
          hadoopqa Hadoop QA added a comment -

          -1 overall. Here are the results of testing the latest attachment
          http://issues.apache.org/jira/secure/attachment/12376747/patch_2809.3
          against trunk revision 619744.

          @author +1. The patch does not contain any @author tags.

          tests included -1. The patch doesn't appear to include any new or modified tests.
          Please justify why no tests are needed for this patch.

          javadoc +1. The javadoc tool did not generate any warning messages.

          javac +1. The applied patch does not generate any new javac compiler warnings.

          release audit +1. The applied patch does not generate any new release audit warnings.

          findbugs +1. The patch does not introduce any new Findbugs warnings.

          core tests +1. The patch passed core unit tests.

          contrib tests +1. The patch passed contrib unit tests.

          Test results: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/1863/testReport/
          Findbugs warnings: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/1863/artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html
          Checkstyle results: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/1863/artifact/trunk/build/test/checkstyle-errors.html
          Console output: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/1863/console

          This message is automatically generated.

          hadoopqa Hadoop QA added a comment - -1 overall. Here are the results of testing the latest attachment http://issues.apache.org/jira/secure/attachment/12376747/patch_2809.3 against trunk revision 619744. @author +1. The patch does not contain any @author tags. tests included -1. The patch doesn't appear to include any new or modified tests. Please justify why no tests are needed for this patch. javadoc +1. The javadoc tool did not generate any warning messages. javac +1. The applied patch does not generate any new javac compiler warnings. release audit +1. The applied patch does not generate any new release audit warnings. findbugs +1. The patch does not introduce any new Findbugs warnings. core tests +1. The patch passed core unit tests. contrib tests +1. The patch passed contrib unit tests. Test results: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/1863/testReport/ Findbugs warnings: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/1863/artifact/trunk/build/test/findbugs/newPatchFindbugsWarnings.html Checkstyle results: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/1863/artifact/trunk/build/test/checkstyle-errors.html Console output: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/1863/console This message is automatically generated.
          nidaley Nigel Daley added a comment -

          I just committed this. Thanks Vinod!

          nidaley Nigel Daley added a comment - I just committed this. Thanks Vinod!
          hudson Hudson added a comment -
          hudson Hudson added a comment - Integrated in Hadoop-trunk #419 (See http://hudson.zones.apache.org/hudson/job/Hadoop-trunk/419/ )
          karams Karam Singh added a comment -

          Checked found that when ringmaster section syslog address then only ringmaster log is going to that log. If hodring section contains syslog address then hodring and hodcleanup log is going to syslog. If syslog address is provided to ringmaster and hodring section then their log is going to syslog.

          karams Karam Singh added a comment - Checked found that when ringmaster section syslog address then only ringmaster log is going to that log. If hodring section contains syslog address then hodring and hodcleanup log is going to syslog. If syslog address is provided to ringmaster and hodring section then their log is going to syslog.

          People

            vinodkv Vinod Kumar Vavilapalli
            yhemanth Hemanth Yamijala
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: