You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-issues@hadoop.apache.org by "Andrew Ryan (JIRA)" <ji...@apache.org> on 2010/07/13 23:07:49 UTC

[jira] Created: (HADOOP-6858) Enable rotateable JVM garbage collection logs for Hadoop daemons

Enable rotateable JVM garbage collection logs for Hadoop daemons
----------------------------------------------------------------

                 Key: HADOOP-6858
                 URL: https://issues.apache.org/jira/browse/HADOOP-6858
             Project: Hadoop Common
          Issue Type: New Feature
          Components: scripts
    Affects Versions: 0.22.0
            Reporter: Andrew Ryan


The purpose of this enhancement is to make it easier to collect garbage collection logs and insure that they persist across restarts in the same way that the standard output files of Hadoop daemon JVM's currently does.

Garbage collection logs are a vital debugging tool for administrators and developers. In our production environments, at some point or another, every single type of Hadoop daemon has OOM'ed or experienced other significant issues related to GC and/or lack of heap memory. For the longest time, we have put in garbage collection logs in our HADOOP_NAMENODE_OPTS, HADOOP_JOBTRACKER_OPTS, etc. by using options like "-XX:+PrintGCDateStamps -XX:+PrintGCDetails -Xloggc:$HADOOP_LOG_DIR/jobtracker.gc.log".

Unfortunately, these logs don't survive a restart of the node, so if a node OOM's and then is restarted automatically, or manually by someone who is unaware, we lose the GC logs forever. We also have to manually add GC log options to each daemon. This patch:
1) Creates a single, optional, off by default, parameter for specifying GC logging.
2) If that parameter is set, automatically enables GC logging for all daemons in the cluster. The parameter is flexible enough to allow for the different ways various vendor's JVM's require garbage collection logging to be specified. 
3) If GC logging is on, insures that the GC log files for each daemon are rotated with up to 5 copies kept, same as the .out files currently.

We are currently running a variation of this patch in our 0.20 install. This patch actually includes changes to common, mapred, and hdfs, so it obviously cannot be applied as-is, but is included here for review and comments.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (HADOOP-6858) Enable rotateable JVM garbage collection logs for Hadoop daemons

Posted by "Andrew Ryan (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-6858?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12888105#action_12888105 ] 

Andrew Ryan commented on HADOOP-6858:
-------------------------------------

We chose not to go that route, because date stamping in that way would address the "logs get blown away on startup" problem, but then it creates a "gc logs are never cleaned up automatically by hadoop" problem. But there are certainly many ways to solve this problem. We're hoping to reach some kind of consensus.

> Enable rotateable JVM garbage collection logs for Hadoop daemons
> ----------------------------------------------------------------
>
>                 Key: HADOOP-6858
>                 URL: https://issues.apache.org/jira/browse/HADOOP-6858
>             Project: Hadoop Common
>          Issue Type: New Feature
>          Components: scripts
>    Affects Versions: 0.22.0
>            Reporter: Andrew Ryan
>         Attachments: HADOOP-6858.patch
>
>
> The purpose of this enhancement is to make it easier to collect garbage collection logs and insure that they persist across restarts in the same way that the standard output files of Hadoop daemon JVM's currently does.
> Garbage collection logs are a vital debugging tool for administrators and developers. In our production environments, at some point or another, every single type of Hadoop daemon has OOM'ed or experienced other significant issues related to GC and/or lack of heap memory. For the longest time, we have put in garbage collection logs in our HADOOP_NAMENODE_OPTS, HADOOP_JOBTRACKER_OPTS, etc. by using options like "-XX:+PrintGCDateStamps -XX:+PrintGCDetails -Xloggc:$HADOOP_LOG_DIR/jobtracker.gc.log".
> Unfortunately, these logs don't survive a restart of the node, so if a node OOM's and then is restarted automatically, or manually by someone who is unaware, we lose the GC logs forever. We also have to manually add GC log options to each daemon. This patch:
> 1) Creates a single, optional, off by default, parameter for specifying GC logging.
> 2) If that parameter is set, automatically enables GC logging for all daemons in the cluster. The parameter is flexible enough to allow for the different ways various vendor's JVM's require garbage collection logging to be specified. 
> 3) If GC logging is on, insures that the GC log files for each daemon are rotated with up to 5 copies kept, same as the .out files currently.
> We are currently running a variation of this patch in our 0.20 install. This patch actually includes changes to common, mapred, and hdfs, so it obviously cannot be applied as-is, but is included here for review and comments.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (HADOOP-6858) Enable rotateable JVM garbage collection logs for Hadoop daemons

Posted by "Hadoop QA (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-6858?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12928497#action_12928497 ] 

Hadoop QA commented on HADOOP-6858:
-----------------------------------

-1 overall.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12449386/HADOOP-6858.patch
  against trunk revision 1031422.

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

    -1 tests included.  The patch doesn't appear to include any new or modified tests.
                        Please justify why no new tests are needed for this patch.
                        Also please list what manual steps were performed to verify this patch.

    -1 patch.  The patch command could not apply the patch.

Console output: https://hudson.apache.org/hudson/job/PreCommit-HADOOP-Build/30//console

This message is automatically generated.

> Enable rotateable JVM garbage collection logs for Hadoop daemons
> ----------------------------------------------------------------
>
>                 Key: HADOOP-6858
>                 URL: https://issues.apache.org/jira/browse/HADOOP-6858
>             Project: Hadoop Common
>          Issue Type: New Feature
>          Components: scripts
>    Affects Versions: 0.22.0
>            Reporter: Andrew Ryan
>         Attachments: HADOOP-6858.patch
>
>
> The purpose of this enhancement is to make it easier to collect garbage collection logs and insure that they persist across restarts in the same way that the standard output files of Hadoop daemon JVM's currently does.
> Garbage collection logs are a vital debugging tool for administrators and developers. In our production environments, at some point or another, every single type of Hadoop daemon has OOM'ed or experienced other significant issues related to GC and/or lack of heap memory. For the longest time, we have put in garbage collection logs in our HADOOP_NAMENODE_OPTS, HADOOP_JOBTRACKER_OPTS, etc. by using options like "-XX:+PrintGCDateStamps -XX:+PrintGCDetails -Xloggc:$HADOOP_LOG_DIR/jobtracker.gc.log".
> Unfortunately, these logs don't survive a restart of the node, so if a node OOM's and then is restarted automatically, or manually by someone who is unaware, we lose the GC logs forever. We also have to manually add GC log options to each daemon. This patch:
> 1) Creates a single, optional, off by default, parameter for specifying GC logging.
> 2) If that parameter is set, automatically enables GC logging for all daemons in the cluster. The parameter is flexible enough to allow for the different ways various vendor's JVM's require garbage collection logging to be specified. 
> 3) If GC logging is on, insures that the GC log files for each daemon are rotated with up to 5 copies kept, same as the .out files currently.
> We are currently running a variation of this patch in our 0.20 install. This patch actually includes changes to common, mapred, and hdfs, so it obviously cannot be applied as-is, but is included here for review and comments.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (HADOOP-6858) Enable rotateable JVM garbage collection logs for Hadoop daemons

Posted by "Allen Wittenauer (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-6858?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12888061#action_12888061 ] 

Allen Wittenauer commented on HADOOP-6858:
------------------------------------------

We just put a date on our logs.

i.e., gc.log.`date +blahblah`.



> Enable rotateable JVM garbage collection logs for Hadoop daemons
> ----------------------------------------------------------------
>
>                 Key: HADOOP-6858
>                 URL: https://issues.apache.org/jira/browse/HADOOP-6858
>             Project: Hadoop Common
>          Issue Type: New Feature
>          Components: scripts
>    Affects Versions: 0.22.0
>            Reporter: Andrew Ryan
>         Attachments: HADOOP-6858.patch
>
>
> The purpose of this enhancement is to make it easier to collect garbage collection logs and insure that they persist across restarts in the same way that the standard output files of Hadoop daemon JVM's currently does.
> Garbage collection logs are a vital debugging tool for administrators and developers. In our production environments, at some point or another, every single type of Hadoop daemon has OOM'ed or experienced other significant issues related to GC and/or lack of heap memory. For the longest time, we have put in garbage collection logs in our HADOOP_NAMENODE_OPTS, HADOOP_JOBTRACKER_OPTS, etc. by using options like "-XX:+PrintGCDateStamps -XX:+PrintGCDetails -Xloggc:$HADOOP_LOG_DIR/jobtracker.gc.log".
> Unfortunately, these logs don't survive a restart of the node, so if a node OOM's and then is restarted automatically, or manually by someone who is unaware, we lose the GC logs forever. We also have to manually add GC log options to each daemon. This patch:
> 1) Creates a single, optional, off by default, parameter for specifying GC logging.
> 2) If that parameter is set, automatically enables GC logging for all daemons in the cluster. The parameter is flexible enough to allow for the different ways various vendor's JVM's require garbage collection logging to be specified. 
> 3) If GC logging is on, insures that the GC log files for each daemon are rotated with up to 5 copies kept, same as the .out files currently.
> We are currently running a variation of this patch in our 0.20 install. This patch actually includes changes to common, mapred, and hdfs, so it obviously cannot be applied as-is, but is included here for review and comments.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (HADOOP-6858) Enable rotateable JVM garbage collection logs for Hadoop daemons

Posted by "Andrew Ryan (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HADOOP-6858?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrew Ryan updated HADOOP-6858:
--------------------------------

    Attachment: HADOOP-6858.patch

This patch requires changes in common, mapred, and hdfs. So this patch will not actually apply to Hudson yet.

> Enable rotateable JVM garbage collection logs for Hadoop daemons
> ----------------------------------------------------------------
>
>                 Key: HADOOP-6858
>                 URL: https://issues.apache.org/jira/browse/HADOOP-6858
>             Project: Hadoop Common
>          Issue Type: New Feature
>          Components: scripts
>    Affects Versions: 0.22.0
>            Reporter: Andrew Ryan
>         Attachments: HADOOP-6858.patch
>
>
> The purpose of this enhancement is to make it easier to collect garbage collection logs and insure that they persist across restarts in the same way that the standard output files of Hadoop daemon JVM's currently does.
> Garbage collection logs are a vital debugging tool for administrators and developers. In our production environments, at some point or another, every single type of Hadoop daemon has OOM'ed or experienced other significant issues related to GC and/or lack of heap memory. For the longest time, we have put in garbage collection logs in our HADOOP_NAMENODE_OPTS, HADOOP_JOBTRACKER_OPTS, etc. by using options like "-XX:+PrintGCDateStamps -XX:+PrintGCDetails -Xloggc:$HADOOP_LOG_DIR/jobtracker.gc.log".
> Unfortunately, these logs don't survive a restart of the node, so if a node OOM's and then is restarted automatically, or manually by someone who is unaware, we lose the GC logs forever. We also have to manually add GC log options to each daemon. This patch:
> 1) Creates a single, optional, off by default, parameter for specifying GC logging.
> 2) If that parameter is set, automatically enables GC logging for all daemons in the cluster. The parameter is flexible enough to allow for the different ways various vendor's JVM's require garbage collection logging to be specified. 
> 3) If GC logging is on, insures that the GC log files for each daemon are rotated with up to 5 copies kept, same as the .out files currently.
> We are currently running a variation of this patch in our 0.20 install. This patch actually includes changes to common, mapred, and hdfs, so it obviously cannot be applied as-is, but is included here for review and comments.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (HADOOP-6858) Enable rotateable JVM garbage collection logs for Hadoop daemons

Posted by "Hadoop QA (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-6858?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12888025#action_12888025 ] 

Hadoop QA commented on HADOOP-6858:
-----------------------------------

-1 overall.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12449386/HADOOP-6858.patch
  against trunk revision 963593.

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

    -1 tests included.  The patch doesn't appear to include any new or modified tests.
                        Please justify why no new tests are needed for this patch.
                        Also please list what manual steps were performed to verify this patch.

    -1 patch.  The patch command could not apply the patch.

Console output: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch-h4.grid.sp2.yahoo.net/611/console

This message is automatically generated.

> Enable rotateable JVM garbage collection logs for Hadoop daemons
> ----------------------------------------------------------------
>
>                 Key: HADOOP-6858
>                 URL: https://issues.apache.org/jira/browse/HADOOP-6858
>             Project: Hadoop Common
>          Issue Type: New Feature
>          Components: scripts
>    Affects Versions: 0.22.0
>            Reporter: Andrew Ryan
>         Attachments: HADOOP-6858.patch
>
>
> The purpose of this enhancement is to make it easier to collect garbage collection logs and insure that they persist across restarts in the same way that the standard output files of Hadoop daemon JVM's currently does.
> Garbage collection logs are a vital debugging tool for administrators and developers. In our production environments, at some point or another, every single type of Hadoop daemon has OOM'ed or experienced other significant issues related to GC and/or lack of heap memory. For the longest time, we have put in garbage collection logs in our HADOOP_NAMENODE_OPTS, HADOOP_JOBTRACKER_OPTS, etc. by using options like "-XX:+PrintGCDateStamps -XX:+PrintGCDetails -Xloggc:$HADOOP_LOG_DIR/jobtracker.gc.log".
> Unfortunately, these logs don't survive a restart of the node, so if a node OOM's and then is restarted automatically, or manually by someone who is unaware, we lose the GC logs forever. We also have to manually add GC log options to each daemon. This patch:
> 1) Creates a single, optional, off by default, parameter for specifying GC logging.
> 2) If that parameter is set, automatically enables GC logging for all daemons in the cluster. The parameter is flexible enough to allow for the different ways various vendor's JVM's require garbage collection logging to be specified. 
> 3) If GC logging is on, insures that the GC log files for each daemon are rotated with up to 5 copies kept, same as the .out files currently.
> We are currently running a variation of this patch in our 0.20 install. This patch actually includes changes to common, mapred, and hdfs, so it obviously cannot be applied as-is, but is included here for review and comments.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (HADOOP-6858) Enable rotateable JVM garbage collection logs for Hadoop daemons

Posted by "Andrew Ryan (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HADOOP-6858?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrew Ryan updated HADOOP-6858:
--------------------------------

    Status: Patch Available  (was: Open)

Patch submitted for review. This won't apply, because it needs patching common, mapred, and hdfs. If there is agreement on how to move forward, I can regenerate different patches for each.

> Enable rotateable JVM garbage collection logs for Hadoop daemons
> ----------------------------------------------------------------
>
>                 Key: HADOOP-6858
>                 URL: https://issues.apache.org/jira/browse/HADOOP-6858
>             Project: Hadoop Common
>          Issue Type: New Feature
>          Components: scripts
>    Affects Versions: 0.22.0
>            Reporter: Andrew Ryan
>         Attachments: HADOOP-6858.patch
>
>
> The purpose of this enhancement is to make it easier to collect garbage collection logs and insure that they persist across restarts in the same way that the standard output files of Hadoop daemon JVM's currently does.
> Garbage collection logs are a vital debugging tool for administrators and developers. In our production environments, at some point or another, every single type of Hadoop daemon has OOM'ed or experienced other significant issues related to GC and/or lack of heap memory. For the longest time, we have put in garbage collection logs in our HADOOP_NAMENODE_OPTS, HADOOP_JOBTRACKER_OPTS, etc. by using options like "-XX:+PrintGCDateStamps -XX:+PrintGCDetails -Xloggc:$HADOOP_LOG_DIR/jobtracker.gc.log".
> Unfortunately, these logs don't survive a restart of the node, so if a node OOM's and then is restarted automatically, or manually by someone who is unaware, we lose the GC logs forever. We also have to manually add GC log options to each daemon. This patch:
> 1) Creates a single, optional, off by default, parameter for specifying GC logging.
> 2) If that parameter is set, automatically enables GC logging for all daemons in the cluster. The parameter is flexible enough to allow for the different ways various vendor's JVM's require garbage collection logging to be specified. 
> 3) If GC logging is on, insures that the GC log files for each daemon are rotated with up to 5 copies kept, same as the .out files currently.
> We are currently running a variation of this patch in our 0.20 install. This patch actually includes changes to common, mapred, and hdfs, so it obviously cannot be applied as-is, but is included here for review and comments.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.