You are viewing a plain text version of this content. The canonical link for it is here.
Posted to hdfs-issues@hadoop.apache.org by "Gokul (JIRA)" <ji...@apache.org> on 2011/05/10 07:11:03 UTC

[jira] [Created] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
----------------------------------------------------------------------------------------

                 Key: HDFS-1910
                 URL: https://issues.apache.org/jira/browse/HDFS-1910
             Project: Hadoop HDFS
          Issue Type: Bug
          Components: name-node
    Affects Versions: 0.21.0
            Reporter: Gokul
            Priority: Minor


when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Aaron T. Myers (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13180985#comment-13180985 ] 

Aaron T. Myers commented on HDFS-1910:
--------------------------------------

bq. The error is obvious and the fix equally so.

The error clearly isn't all that obvious, given that this bug existed for quite a while without being noticed/fixed.

I think we should have a test mostly to ensure that this issue doesn't regress. This is a bad habit to get into. That said, I'm certainly not going to block this fix going in for lack of test coverage.
                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>             Fix For: 0.22.1
>
>         Attachments: saveImageOnce-v0.22.patch
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Konstantin Shvachko (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13176847#comment-13176847 ] 

Konstantin Shvachko commented on HDFS-1910:
-------------------------------------------

Sorry had a bad commit day here.
I did not include a test here because this was revealed through watching log files during NN startup, which indicates to me that the condition is easily traceable. And the test would have been based either on logs analysis or some instrumentation of FSImage, which would count methods calls. Neither looks appealing to me, but feel free to file a bug if you feel strongly about it.
                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>         Attachments: saveImageOnce-v0.22.patch
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Aaron T. Myers (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13181008#comment-13181008 ] 

Aaron T. Myers commented on HDFS-1910:
--------------------------------------

bq. It's up to Konstantin to commit to 1.1 if he wants; he has a committer's +1 to do so.

I know that. Like I said - I'm not going to block it.

bq. This will be a serious pain to test in a true unit test, 

We do these sorts of tests all the time with Mockito.spy, Mockito.verify, and Mockito.times.

bq. so rather than wait for someone to write that code, I'd rather get the signficant startup time improvement in. Yeah, it'd be great to have a test - and if it were at all possible this could cause a data loss, I'd insist on it - but people's time is limited.

Sure, no objection. I just asked for a test as I do for all code I review which doesn't have test coverage. It's your prerogative if you want to ignore that request, or punt it to another JIRA.
                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>             Fix For: 0.22.1
>
>         Attachments: saveImageOnce-v0.22.patch
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Konstantin Shvachko (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Konstantin Shvachko updated HDFS-1910:
--------------------------------------

    Target Version/s: 1.1.0, 0.22.1  (was: 0.22.1, 1.1.0)
       Fix Version/s: 0.22.1
        Hadoop Flags: Reviewed

I just committed this to 0.22 branch. Leaving open pending decision on 1.1.0
                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>             Fix For: 0.22.1
>
>         Attachments: saveImageOnce-v0.22.patch
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Konstantin Shvachko (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Konstantin Shvachko updated HDFS-1910:
--------------------------------------

    Attachment: saveImageOnce-v1.1.patch
    
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>             Fix For: 0.22.1
>
>         Attachments: saveImageOnce-v0.22.patch, saveImageOnce-v1.1.patch
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Jakob Homan (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13181001#comment-13181001 ] 

Jakob Homan commented on HDFS-1910:
-----------------------------------

It's up to Konstantin to commit to 1.1 if he wants; he has a committer's +1 to do so.  This will be a serious pain to test in a true unit test, so rather than wait for someone to write that code, I'd rather get the signficant startup time improvement in.  Yeah, it'd be great to have a test - and if it were at all possible this could cause a data loss, I'd insist on it - but people's time is limited.  I'd recommend filing a JIRA to add one; it would be a good mid-level newbie issue.
                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>             Fix For: 0.22.1
>
>         Attachments: saveImageOnce-v0.22.patch
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Konstantin Shvachko (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Konstantin Shvachko updated HDFS-1910:
--------------------------------------

    Fix Version/s: 0.22.1
                   1.0.0
    
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>             Fix For: 1.0.0, 0.22.1
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Resolved] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Konstantin Shvachko (Resolved) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Konstantin Shvachko resolved HDFS-1910.
---------------------------------------

          Resolution: Fixed
       Fix Version/s: 1.1.0
    Target Version/s: 1.1.0, 0.22.1  (was: 0.22.1, 1.1.0)

I just committed this to branch 1.
                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>             Fix For: 1.1.0, 0.22.1
>
>         Attachments: saveImageOnce-v0.22.patch, saveImageOnce-v1.1.patch
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Aaron T. Myers (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13180992#comment-13180992 ] 

Aaron T. Myers commented on HDFS-1910:
--------------------------------------

@Jakob - sorry, I wasn't clear. The error in the code is indeed fairly obvious. My point was that the reintroduction of this bug would be non-obvious since, as you point out, this operation is idempotent.
                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>             Fix For: 0.22.1
>
>         Attachments: saveImageOnce-v0.22.patch
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Aaron T. Myers (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13176730#comment-13176730 ] 

Aaron T. Myers commented on HDFS-1910:
--------------------------------------

Shouldn't we include a test to ensure this issue doesn't regress?
                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>         Attachments: saveImageOnce-v0.22.patch
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Konstantin Boudnik (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13176415#comment-13176415 ] 

Konstantin Boudnik commented on HDFS-1910:
------------------------------------------

+1 patch looks good.
                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>         Attachments: saveImageOnce-v0.22.patch
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Hudson (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13177126#comment-13177126 ] 

Hudson commented on HDFS-1910:
------------------------------

Integrated in Hadoop-Hdfs-22-branch #124 (See [https://builds.apache.org/job/Hadoop-Hdfs-22-branch/124/])
    Remove erroneously added file while commit to HDFS-1910.
HDFS-1910. NameNdoe should not save fsimage twice. Contributed by Konstantin Shvachko.
Revert. Refers to wrong jira HDFS-1910.
HDFS-1910. NameNdoe should not save fsimage twice. Contributed by Konstantin Shvachko.

shv : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1225342
Files : 
* /hadoop/common/branches/branch-0.22/hdfs/bin/hadoop

shv : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1225337
Files : 
* /hadoop/common/branches/branch-0.22/hdfs/CHANGES.txt
* /hadoop/common/branches/branch-0.22/hdfs/bin/hadoop
* /hadoop/common/branches/branch-0.22/hdfs/src/java/org/apache/hadoop/hdfs/server/namenode/FSImage.java

shv : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1225336
Files : 
* /hadoop/common/branches/branch-0.22/hdfs/CHANGES.txt
* /hadoop/common/branches/branch-0.22/hdfs/src/java/org/apache/hadoop/hdfs/server/namenode/FSImage.java
* /hadoop/common/branches/branch-0.22/hdfs/src/test/hdfs/org/apache/hadoop/hdfs/server/namenode/TestBackupNode.java

shv : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1225333
Files : 
* /hadoop/common/branches/branch-0.22/hdfs/CHANGES.txt
* /hadoop/common/branches/branch-0.22/hdfs/src/java/org/apache/hadoop/hdfs/server/namenode/FSImage.java
* /hadoop/common/branches/branch-0.22/hdfs/src/test/hdfs/org/apache/hadoop/hdfs/server/namenode/TestBackupNode.java

                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>             Fix For: 0.22.1
>
>         Attachments: saveImageOnce-v0.22.patch
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Konstantin Shvachko (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13182881#comment-13182881 ] 

Konstantin Shvachko commented on HDFS-1910:
-------------------------------------------

I will commit it to 1.1 as you guys suggested.
                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>             Fix For: 0.22.1
>
>         Attachments: saveImageOnce-v0.22.patch
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Konstantin Shvachko (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13159678#comment-13159678 ] 

Konstantin Shvachko commented on HDFS-1910:
-------------------------------------------

This is indeed a critical issue, which slows down cluster start up, because the image is written twice for every storage directory, which is of type IMAGE_AND_EDITS.
I traced this problem from 0.22 all the way back to 0.20. On trunk it is not a problem as far as I can see. 
In 0.22 branch and below saveNamespace() iterates over all storage directories and updates either image or edits or both files depending on the directory type. That way if a failure occurs in the middle only one directory will need to be recovered, the rest will maintain consistent state.
The trunk differs because saveNamespace() independently updates first image directories then edits directories, which is valid because of txIds. If a failure occurs in the middle of updating the matching pair of image and edits in each directory should be found based on txIds.
                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Konstantin Shvachko (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Konstantin Shvachko updated HDFS-1910:
--------------------------------------

    Attachment: saveImageOnce-v0.22.patch

Here is a simple fix for branch 0.22.
                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>         Attachments: saveImageOnce-v0.22.patch
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Matt Foley (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Matt Foley updated HDFS-1910:
-----------------------------

    Target Version/s: 1.1.0, 0.22.1
       Fix Version/s:     (was: 0.22.1)
                          (was: 1.0.0)

Please use the "Target Versions" field, not the "Fix Version" field, to express where a bug should be fixed or where you intend to fix it.  The "Fix Version" field is for saying where it has been fixed, and should only be set after committing a fix to a branch.

Also, since 1.0.0 is already in vote, this should be targeted for 1.1.0.
                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Jakob Homan (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13180808#comment-13180808 ] 

Jakob Homan commented on HDFS-1910:
-----------------------------------

I'm fine with this going into 1.1 without a test.  The error is obvious and the fix equally so.  Konstantin, do you want to commit it there?
                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>             Fix For: 0.22.1
>
>         Attachments: saveImageOnce-v0.22.patch
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Jakob Homan (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13180991#comment-13180991 ] 

Jakob Homan commented on HDFS-1910:
-----------------------------------

bq. The error clearly isn't all that obvious, given that this bug existed for quite a while without being noticed/fixed.
Not really.  Something being done twice is easier to overlook than something not being done.  Assuming the second time overwrites the first, you end up with what you expect: one copy of the fsimage.  
                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>             Fix For: 0.22.1
>
>         Attachments: saveImageOnce-v0.22.patch
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Hudson (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13176858#comment-13176858 ] 

Hudson commented on HDFS-1910:
------------------------------

Integrated in Hadoop-Hdfs-22-branch #123 (See [https://builds.apache.org/job/Hadoop-Hdfs-22-branch/123/])
    Remove erroneously added file while commit to HDFS-1910.
HDFS-1910. NameNdoe should not save fsimage twice. Contributed by Konstantin Shvachko.
Revert. Refers to wrong jira HDFS-1910.
HDFS-1910. NameNdoe should not save fsimage twice. Contributed by Konstantin Shvachko.

shv : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1225342
Files : 
* /hadoop/common/branches/branch-0.22/hdfs/bin/hadoop

shv : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1225337
Files : 
* /hadoop/common/branches/branch-0.22/hdfs/CHANGES.txt
* /hadoop/common/branches/branch-0.22/hdfs/bin/hadoop
* /hadoop/common/branches/branch-0.22/hdfs/src/java/org/apache/hadoop/hdfs/server/namenode/FSImage.java

shv : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1225336
Files : 
* /hadoop/common/branches/branch-0.22/hdfs/CHANGES.txt
* /hadoop/common/branches/branch-0.22/hdfs/src/java/org/apache/hadoop/hdfs/server/namenode/FSImage.java
* /hadoop/common/branches/branch-0.22/hdfs/src/test/hdfs/org/apache/hadoop/hdfs/server/namenode/TestBackupNode.java

shv : http://svn.apache.org/viewcvs.cgi/?root=Apache-SVN&view=rev&rev=1225333
Files : 
* /hadoop/common/branches/branch-0.22/hdfs/CHANGES.txt
* /hadoop/common/branches/branch-0.22/hdfs/src/java/org/apache/hadoop/hdfs/server/namenode/FSImage.java
* /hadoop/common/branches/branch-0.22/hdfs/src/test/hdfs/org/apache/hadoop/hdfs/server/namenode/TestBackupNode.java

                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>             Fix For: 0.22.1
>
>         Attachments: saveImageOnce-v0.22.patch
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HDFS-1910) when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time

Posted by "Zhihong Yu (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HDFS-1910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13174482#comment-13174482 ] 

Zhihong Yu commented on HDFS-1910:
----------------------------------

Patch makes sense.
                
> when dfs.name.dir and dfs.name.edits.dir are same fsimage will be saved twice every time
> ----------------------------------------------------------------------------------------
>
>                 Key: HDFS-1910
>                 URL: https://issues.apache.org/jira/browse/HDFS-1910
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Gokul
>            Priority: Minor
>              Labels: critical-0.22.0
>         Attachments: saveImageOnce-v0.22.patch
>
>
> when image and edits dir are configured same, the fsimage flushing from memory to disk will be done twice whenever saveNamespace is done. this may impact the performance of backupnode/snn where it does a saveNamespace during every checkpointing time.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira