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
0301 optimize boot failure logs #10052
Merged
Merged
Conversation
This file contains 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
Rory-Z
previously approved these changes
Mar 2, 2023
id
reviewed
Mar 2, 2023
id
reviewed
Mar 2, 2023
id
reviewed
Mar 2, 2023
id
reviewed
Mar 2, 2023
thalesmg
previously approved these changes
Mar 2, 2023
zmstone
force-pushed
the
0301-optimize-boot-error-log
branch
from
March 2, 2023 13:32
aa45e59
to
5c7d936
Compare
Prior to this change, when EMQX daemon mode failed to start it's not quite easy for users to understand what went wrong. All the know is the node did not start in time and then instructed to boot the node in 'console' mode wishing for some logs. However, the node might actuay be running, causing 'console' mode to fail with a different reason. With this change, after a filure of daemon mode boot, we issue a diagnosis. 1. if node can not be found from ps -ef, instruct the user to find information in erlang.log.N 2. if the node is found running, but not responding to pings instruct the user to check if the node name is resolvable and reachable 3. if the node is responding to pings but emqx app is not running, then it's likely a bug. so the user is advised to report a github issue.
zmstone
force-pushed
the
0301-optimize-boot-error-log
branch
from
March 2, 2023 13:50
5c7d936
to
4eb9a69
Compare
thalesmg
approved these changes
Mar 3, 2023
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.
Fixes EMQX-9052
Improve daemon mode startup failure logs.
Before this change, it was difficult for users to understand the reason for EMQX 'start' command failed to boot the node.
The only information they received was that the node did not start within the expected time frame,
and they were instructed to boot the node with 'console' command in the hope of obtaining some logs.
However, the node might actually be running, which could cause 'console' mode to fail for a different reason.
With this new change, when daemon mode fails to boot, a diagnosis is issued. Here are the possible scenarios:
ps -ef
, the user is instructed to find information in log fileserlang.log.*
.PR Checklist
Please convert it to a draft if any of the following conditions are not met. Reviewers may skip over until all the items are checked:
changes/{ce,ee}/(feat|perf|fix)-<PR-id>.en.md
and.zh.md
files