You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-dev@hadoop.apache.org by "Pete Wyckoff (JIRA)" <ji...@apache.org> on 2008/05/27 22:54:59 UTC

[jira] Created: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

fsck exit code would be better if non-zero when FS corrupt
----------------------------------------------------------

                 Key: HADOOP-3452
                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
             Project: Hadoop Core
          Issue Type: Improvement
            Reporter: Pete Wyckoff
            Priority: Minor


fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Updated: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

Chris Douglas updated HADOOP-3452:
----------------------------------

      Resolution: Fixed
    Hadoop Flags: [Incompatible change, Reviewed]  (was: [Incompatible change])
          Status: Resolved  (was: Patch Available)

I just committed this. Thanks, Lohit

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Assignee: Lohit Vijayarenu
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch, HADOOP-3452-2.patch, HADOOP-3452-3.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Commented: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

Hadoop QA commented on HADOOP-3452:
-----------------------------------

+1 overall.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12383356/HADOOP-3452-3.patch
  against trunk revision 663079.

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

    +1 tests included.  The patch appears to include 3 new or modified tests.

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

    +1 javac.  The applied patch does not increase the total number of javac compiler warnings.

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

    +1 release audit.  The applied patch does not increase the total number of release audit warnings.

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

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

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

This message is automatically generated.

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch, HADOOP-3452-2.patch, HADOOP-3452-3.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Updated: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

Lohit Vijayarenu updated HADOOP-3452:
-------------------------------------

    Attachment: HADOOP-3452-3.patch

Thanks for reviewing this Dhruba. The reason I scan for "is CORRUPT" is because, fsck now also reports CORRUPT blocks. And also, if a filename contains CORRUPT, we do not want to report filesystem to be corrupt. As I mentioned, this is a temporary fix. I have updated the patch comments as you suggested. 

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch, HADOOP-3452-2.patch, HADOOP-3452-3.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Commented: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

Posted by "Pete Wyckoff (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-3452?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12600330#action_12600330 ] 

Pete Wyckoff commented on HADOOP-3452:
--------------------------------------

Yes, that's my current work around, but was hoping to have fsck itself include that.


> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Commented: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

Posted by "dhruba borthakur (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-3452?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12600329#action_12600329 ] 

dhruba borthakur commented on HADOOP-3452:
------------------------------------------

One simple approach is for the client to look for the string "CORRUPT" and then exit with either 0 or 1.

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Updated: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

lohit vijayarenu updated HADOOP-3452:
-------------------------------------

    Status: Open  (was: Patch Available)

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch, HADOOP-3452-2.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Assigned: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

Robert Chansler reassigned HADOOP-3452:
---------------------------------------

    Assignee: Lohit Vijayarenu

Assigning to whomever submitted a patch so as to better manage committing things that are ready for prime time.

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Assignee: Lohit Vijayarenu
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch, HADOOP-3452-2.patch, HADOOP-3452-3.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Updated: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

lohit vijayarenu updated HADOOP-3452:
-------------------------------------

    Status: Patch Available  (was: Open)

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch, HADOOP-3452-2.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Updated: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

lohit vijayarenu updated HADOOP-3452:
-------------------------------------

    Status: Patch Available  (was: Open)

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch, HADOOP-3452-2.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Updated: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

lohit vijayarenu updated HADOOP-3452:
-------------------------------------

    Attachment: HADOOP-3452-2.patch

I am attaching a patch with comments about this for now. Have another small line change for flushing output. This is a temporary solution, until we plan a different approach to do this.

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch, HADOOP-3452-2.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Commented: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

Posted by "Steve Loughran (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-3452?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12600760#action_12600760 ] 

Steve Loughran commented on HADOOP-3452:
----------------------------------------

-Error codes could be something added as an option. They are reliable, except that proxy servers like to interfere.

-moving to constants should be easy.

It would be extra impressive if the result was hidden in a <span> with a specific name, so you could XPATH/regexp on the response and look for <span class="status" >SUCCESS</span> through some Xpath like

/span[@class="status"]


>Do you have another mechanism in mind (other than using a servlet) to run fsck?

Possibly. In SVN we have the code to bring up any of the name/data/tracker/jobtracker nodes and execute operations on the filesystem,  though many more tests are needed. adding an FSCK check component would round things off. Right now, I'd consider generating an httpclient request with all the parameters and do a regexp search on the result. 

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Updated: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

Lohit Vijayarenu updated HADOOP-3452:
-------------------------------------

    Status: Open  (was: Patch Available)

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch, HADOOP-3452-2.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Commented: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

Hadoop QA commented on HADOOP-3452:
-----------------------------------

-1 overall.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12383268/HADOOP-3452-2.patch
  against trunk revision 662913.

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

    +1 tests included.  The patch appears to include 3 new or modified tests.

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

Console output: http://hudson.zones.apache.org/hudson/job/Hadoop-Patch/2552/console

This message is automatically generated.

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch, HADOOP-3452-2.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Updated: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

Lohit Vijayarenu updated HADOOP-3452:
-------------------------------------

    Status: Patch Available  (was: Open)

looks like hudson had problem, the failure is not related to the patch. Re-submitting.

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch, HADOOP-3452-2.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Commented: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

Hadoop QA commented on HADOOP-3452:
-----------------------------------

+1 overall.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12382904/HADOOP-3452-1.patch
  against trunk revision 659405.

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

    +1 tests included.  The patch appears to include 3 new or modified tests.

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

    +1 javac.  The applied patch does not increase the total number of javac compiler warnings.

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

    +1 release audit.  The applied patch does not increase the total number of release audit warnings.

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

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

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

This message is automatically generated.

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Commented: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

Posted by "dhruba borthakur (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-3452?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12600539#action_12600539 ] 

dhruba borthakur commented on HADOOP-3452:
------------------------------------------

I like the idea of using as compile time constant NameNodeFsck.STATUS_HEALTHY variable to determine that return status of fsck. Also, it would be nice to not depend on Http error error codes. 

Do you have another mechanism in mind (other than using a servlet) to run fsck?

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Updated: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

Robert Chansler updated HADOOP-3452:
------------------------------------

    Release Note: Changed exit status of fsck to report whether the files system is healthy or corrupt.  (was: fsck now reports exit status depending on the status of filesystem, (HEALTHY/CORRUPT))
    Hadoop Flags: [Incompatible change, Reviewed]  (was: [Reviewed, Incompatible change])

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Assignee: Lohit Vijayarenu
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch, HADOOP-3452-2.patch, HADOOP-3452-3.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Updated: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

lohit vijayarenu updated HADOOP-3452:
-------------------------------------

    Status: Open  (was: Patch Available)

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Commented: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

Posted by "lohit vijayarenu (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-3452?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12601777#action_12601777 ] 

lohit vijayarenu commented on HADOOP-3452:
------------------------------------------

Thanks Steve, Dhruba for looking into this. If we consider  the current implmentation, fsck was implemented as servlet so that we do not use RPC. The client opens up URL connection and reads the output from FSCK servlet. We might not be able to set new headers/response code at the end of fsck executiong since the fsck in itself take a while to complete. And the status is not know prior to executing fsck. Could you brief me as to how we could get the response other than scanning this stream?

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Commented: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

Posted by "Steve Loughran (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-3452?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12600436#action_12600436 ] 

Steve Loughran commented on HADOOP-3452:
----------------------------------------

Scanning for strings is very, very brittle, and not a good way to do system management. The fact that it is the only way to verify that rpm and yum are working are design errors on the part of those tools, not an example of good programming to follow. 

- At the very least NameNodeFsck should offer public constants for the status strings, rather than this:

replace "Status: " + (isHealthy() ? "HEALTHY" : "CORRUPT"))



The client could then look for NameNodeFsck.STATUS_HEALTHY, a string that would (currently) be "Status: HEALTHY" when all was well.

-it would be better for the servlet response to include an HTTP error code (500?) on corruption, though that leads to two problems
 -you need to buffer the output if you want to change the error code
 -java.net is atrocious at accessing the contents of error pages

Looking at NameNodeFsck, I think it would be good to remove all knowledge of the fact it is running under a servlet from its code -that is "view", not "model. This would give us the option of using alternate ways to invoke filesystem checks than http requests.

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Commented: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

Hadoop QA commented on HADOOP-3452:
-----------------------------------

-1 overall.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12383268/HADOOP-3452-2.patch
  against trunk revision 662634.

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

    +1 tests included.  The patch appears to include 3 new or modified tests.

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

    +1 javac.  The applied patch does not increase the total number of javac compiler warnings.

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

    +1 release audit.  The applied patch does not increase the total number of release audit warnings.

    -1 core tests.  The patch failed core unit tests.

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

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

This message is automatically generated.

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch, HADOOP-3452-2.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Updated: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

lohit vijayarenu updated HADOOP-3452:
-------------------------------------

    Attachment: HADOOP-3452-1.patch

Attached patch scans for the string "is CORRUPT". Have updated the test cases, so that tomorrow in someone changes the output, tests reflect them. 

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>         Attachments: HADOOP-3452-1.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Commented: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

Posted by "dhruba borthakur (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-3452?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12602195#action_12602195 ] 

dhruba borthakur commented on HADOOP-3452:
------------------------------------------

+1. Code looks good.

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch, HADOOP-3452-2.patch, HADOOP-3452-3.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Commented: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

Posted by "dhruba borthakur (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HADOOP-3452?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12602181#action_12602181 ] 

dhruba borthakur commented on HADOOP-3452:
------------------------------------------

+1 code looks good. Is there a reason why we match the string "is CORRUPT" and not just "CORRUPT"? If we are doing this on purpose, then the comment in the DFSck.java should mention that "is CORRUPT" is the precise string that is being used.

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch, HADOOP-3452-2.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Updated: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

dhruba borthakur updated HADOOP-3452:
-------------------------------------

    Component/s: dfs

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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


[jira] Updated: (HADOOP-3452) fsck exit code would be better if non-zero when FS corrupt

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

lohit vijayarenu updated HADOOP-3452:
-------------------------------------

    Fix Version/s: 0.18.0
     Release Note: fsck now reports exit status depending on the status of filesystem, (HEALTHY/CORRUPT)
     Hadoop Flags: [Incompatible change]
           Status: Patch Available  (was: Open)

> fsck exit code would be better if non-zero when FS corrupt
> ----------------------------------------------------------
>
>                 Key: HADOOP-3452
>                 URL: https://issues.apache.org/jira/browse/HADOOP-3452
>             Project: Hadoop Core
>          Issue Type: Improvement
>          Components: dfs
>            Reporter: Pete Wyckoff
>            Priority: Minor
>             Fix For: 0.18.0
>
>         Attachments: HADOOP-3452-1.patch
>
>
> fsck exit code would be better if behaved like other sys admin tools and exit code indicated healthy/corrupt or other  errors.

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