sarvekshayr opened a new pull request, #8902: URL: https://github.com/apache/ozone/pull/8902
## What changes were proposed in this pull request? Moved `ozone debug ratislogparser` under `ozone debug ratis parse` command. The parse subcommand supports parsing different Ratis files. A `--role`=[om, scm, datanode, generic] flag is added to specify which schema should be used when parsing the logs. ## What is the link to the Apache JIRA [HDDS-13518](https://issues.apache.org/jira/browse/HDDS-13518) ## How was this patch tested? Tested on a docker cluster and through existing tests. Before: ``` Usage: ozone debug ratislogparser [-hV] [--verbose] [COMMAND] Shell of printing Ratis Log in understandable text -h, --help Show this help message and exit. -V, --version Print version information and exit. --verbose More verbose output. Show the stack trace of the errors. Commands: datanode dump datanode segment file generic dump generic ratis segment file om dump om ratis segment file scm dump scm ratis segment file ``` Now: ``` Usage: ozone debug ratis parse [-hV] [--verbose] --role=<role> -s=<segmentFile> Shell for printing Ratis Log in understandable text -h, --help Show this help message and exit. --role=<role> Dump the specified role ratis segment file. Format: [om, scm, datanode, generic] -s, --segmentPath, --segment-path=<segmentFile> Path of the segment file -V, --version Print version information and exit. --verbose More verbose output. Show the stack trace of the errors. bash-5.1$ ozone debug ratis parse --role om -s /data/metadata/ratis/bf265839-605b-3f16-9796-c5ba1605619e/current/log_inprogress_0 Dumping OM Ratis Log Processing Raft Log file: /data/metadata/ratis/bf265839-605b-3f16-9796-c5ba1605619e/current/log_inprogress_0 size:4194304 (t:1, i:0), CONFIGURATIONENTRY(current:id:"om1"address:"om:9872"startupRole:FOLLOWER, old:) Num Total Entries: 1 Num Conf Entries: 1 Num Metadata Entries: 0 Num StateMachineEntries Entries: 0 Num Invalid Entries: 0 ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
