Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HDDS-6614. EC: Fix Datanode block file INCONSISTENCY during heavy load. #3323

Merged
merged 3 commits into from Apr 24, 2022

Conversation

guihecheng
Copy link
Contributor

What changes were proposed in this pull request?

EC: Fix Datanode block file INCONSISTENCY during heavy load.
Problem descriptions and analysis in the JIRA below.
In brief, we should get the file size by using the fileChannel instead of the file.

What is the link to the Apache JIRA

https://issues.apache.org/jira/browse/HDDS-6614

How was this patch tested?

Manual test with experiment programs, seen in the JIRA above.

@kaijchen
Copy link
Contributor

https://docs.oracle.com/javase/7/docs/api/java/io/File.html#length()

public long length()

Returns:
The length, in bytes, of the file denoted by this abstract pathname, or 0L if the file does not exist. Some operating systems may return 0L for pathnames denoting system-dependent entities such as devices or pipes.

@guihecheng
Copy link
Contributor Author

https://issues.apache.org/jira/browse/HDDS-6614

Yes I've read this, you could read the descriptions in the JIRA and try the provided small program for some hints.

@kerneltime
Copy link
Contributor

This makes sense. Thanks for catching this. LGTM.

Copy link
Contributor

@kerneltime kerneltime left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor nit

@umamaheswararao
Copy link
Contributor

Thanks @guihecheng for reporting this. This issue looks very similar to https://issues.apache.org/jira/browse/HDDS-6356
I think it was consistently reproduced in @cchenax environment which was basically starting all DNs in same machine. That time we could not reproduce in actual cluster, so we did not really dig further.

So, to make sure this issue is fixed, how about @cchenax help to reproduce with his env and try this fix there?

@guihecheng
Copy link
Contributor Author

Thanks @guihecheng for reporting this. This issue looks very similar to https://issues.apache.org/jira/browse/HDDS-6356 I think it was consistently reproduced in @cchenax environment which was basically starting all DNs in same machine. That time we could not reproduce in actual cluster, so we did not really dig further.

So, to make sure this issue is fixed, how about @cchenax help to reproduce with his env and try this fix there?

Oh, yes, may be this problem is similar to that one, but I'm not sure, I'll fix the failed tests and ping cchenax then.

@guihecheng guihecheng changed the base branch from HDDS-3816-ec to master April 21, 2022 02:45
@guihecheng
Copy link
Contributor Author

Hi @kerneltime @umamaheswararao , thanks for reviewing , test failures addressed and Exception refined.

@cchenax
Copy link
Contributor

cchenax commented Apr 21, 2022

Thanks @guihecheng for reporting this. This issue looks very similar to https://issues.apache.org/jira/browse/HDDS-6356 I think it was consistently reproduced in @cchenax environment which was basically starting all DNs in same machine. That time we could not reproduce in actual cluster, so we did not really dig further.

So, to make sure this issue is fixed, how about @cchenax help to reproduce with his env and try this fix there?

ok,I will test it.

@cchenax
Copy link
Contributor

cchenax commented Apr 21, 2022

Thanks @guihecheng for reporting this. This issue looks very similar to https://issues.apache.org/jira/browse/HDDS-6356 I think it was consistently reproduced in @cchenax environment which was basically starting all DNs in same machine. That time we could not reproduce in actual cluster, so we did not really dig further.

So, to make sure this issue is fixed, how about @cchenax help to reproduce with his env and try this fix there?

it may be not the same problem.

@guihecheng guihecheng merged commit 9ac8fbc into apache:master Apr 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
5 participants