HDDS-15986. Report ozone local startup failures - #10934
Open
henrybear327 wants to merge 1 commit into
Open
Conversation
henrybear327
force-pushed
the
HDDS-15986
branch
from
August 3, 2026 19:25
c0e39cb to
7668c00
Compare
Contributor
Author
|
@chungen0126 PTAL if this is what you meant in #10757 (review), thanks. |
henrybear327
force-pushed
the
HDDS-15986
branch
from
August 5, 2026 07:51
7668c00 to
b338b2d
Compare
Contributor
Author
|
@peterxcli PTAL, thanks. |
chungen0126
reviewed
Aug 6, 2026
chungen0126
left a comment
Contributor
There was a problem hiding this comment.
Thanks @henrybear327 for working on this.
Comment on lines
+220
to
+222
| throw new IOException("Local Ozone failed to start: " + failureMessage(ex) | ||
| + " Re-run with `ozone --loglevel INFO local run` for service logs," | ||
| + " or add --verbose for the full stack trace.", ex); |
Contributor
There was a problem hiding this comment.
I don't think we need the failureMessage extraction here. Since we are already passing ex as the cause in new IOException("...", ex).
| private StorageContainerManager scm; | ||
| private OzoneManager om; | ||
| private final List<HddsDatanodeService> datanodes = new ArrayList<>(); | ||
| private final List<String> discardedUserConfigKeys = new ArrayList<>(); |
Contributor
There was a problem hiding this comment.
I am not entirely sure about the purpose of discardedUserConfigKeys. In my opinion, if a user specifies a parameter and it's invalid/incompatible, we should fail-fast and throw an error message, rather than silently modifying it.
`ozone local run` swallowed every failure it hit: shutdown and start() rollback errors went to IOUtils.closeQuietly with a null logger, the readiness wait collapsed its conditions into a single boolean, and the CLI converters rejected a value without naming it. The launcher sets OZONE_LOGLEVEL=OFF for ozone-tools, so logging on its own would stay invisible. A failed start now reports a message the user can act on, pointing at `ozone --loglevel INFO local run` for the service logs and --verbose for the stack trace. Local defaults that replace a user-configured value are now recorded and repeated on stderr by the CLI, so a discarded override stays visible even when it is the very setting the user is debugging. The datanode-count limit is checked before the format step so that format mode ALWAYS cannot delete the data dir for a run that can never start. Naming the unmet safe mode rules reads them as commons-lang3 Pair values, a use that leaves no import behind, so ozone-tools declares commons-lang3 for the dependency analyzer.
henrybear327
force-pushed
the
HDDS-15986
branch
from
August 6, 2026 13:48
b338b2d to
7ab65a2
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changes were proposed in this pull request?
This PR improves the error reporting and handling.
ozone local runswallowed every failure it hit: shutdown and start() rollback errors went to IOUtils.closeQuietly with a null logger, the readiness wait collapsed its conditions into a single boolean, and the CLI converters rejected a value without naming it.What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-15986
How was this patch tested?
https://github.com/apache/ozone/actions/runs/30844781369