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-12039. Enhancements to ozone repair om commands #7662

Merged
merged 2 commits into from
Jan 9, 2025

Conversation

sarvekshayr
Copy link
Contributor

What changes were proposed in this pull request?

ozone repair om
These commands make repairs to an individual OM instance.

  • ozone repair om quota
    The new location of ozone repair quota which is an online command (requires running OM).
  • Add HDDS-11727 check to see if OM is running inozone repair om snapshot chain and ozone repair om update-transaction.

What is the link to the Apache JIRA

HDDS-12039

How was this patch tested?

Tested the patch on a docker cluster.

bash-5.1$ ozone repair om
ATTENTION: Running as user hadoop. Make sure this is the same user used to run the Ozone process. Are you sure you want to continue (y/N)? y
Run as user: hadoop
Missing required subcommand
Usage: ozone repair om [COMMAND]
Operational tool to repair OM.
Commands:
  fso-tree            Identify and repair a disconnected FSO tree by marking
                        unreferenced entries for deletion. OM should be stopped
                        while this tool is run.
  snapshot            Subcommand for all snapshot related repairs.
  update-transaction  CLI to update the highest index in transactionInfoTable.
                        Currently it is only supported for OM.
  quota               Operational tool to repair quota in OM DB.

bash-5.1$ ozone repair om quota
ATTENTION: Running as user hadoop. Make sure this is the same user used to run the Ozone process. Are you sure you want to continue (y/N)? y
Run as user: hadoop
Missing required subcommand
Usage: ozone repair om quota [COMMAND]
Operational tool to repair quota in OM DB.
Commands:
  status  CLI to get the status of last trigger quota repair if available.
  start   CLI to trigger quota repair.
bash-5.1$ ozone repair om update-transaction --db /data/metadata/om.db --term 2 --index 2
ATTENTION: Running as user hadoop. Make sure this is the same user used to run the Ozone process. Are you sure you want to continue (y/N)? y
Run as user: hadoop
Error: OM is currently running on this host with PID 7. Stop the service before running the repair tool.

Copy link
Contributor

@adoroszlai adoroszlai left a comment

Choose a reason for hiding this comment

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

Thanks @sarvekshayr for the patch.

@adoroszlai adoroszlai merged commit 80dc87a into apache:master Jan 9, 2025
42 checks passed
@adoroszlai
Copy link
Contributor

Thanks @sarvekshayr for updating the patch.

(Let's not bundle logically separate changes in the same PR. I understand that the part which adds check for running OM in two classes would have been too small in itself for a separate PR. However, also adding check for running SCM or datanode in other repair classes, it would have been large enough and still one topic.)

@sarvekshayr
Copy link
Contributor Author

Thanks @sarvekshayr for updating the patch.

(Let's not bundle logically separate changes in the same PR. I understand that the part which adds check for running OM in two classes would have been too small in itself for a separate PR. However, also adding check for running SCM or datanode in other repair classes, it would have been large enough and still one topic.)

Got it. I'll follow this for the upcoming tasks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants