Skip to content

Commit 9376276

Browse files
committed
[#26552]yugabyted: Making changes to not delete the universe key after enabling EAR
Summary: `yugabyted`, while enabling EAR, 1. Creates a universe key 2. Copies the key to masters 3. Then rotates that key in masters. 4. The universe key is then deleted from the machine assuming that it would not be used again (as the key in now in masters memory). This should not be deleted as it is needed in case when all masters are down or while restoring a backup of encrypted data to another cluster. Jira: DB-15919 Test Plan: ./yb_build.sh --java-test 'org.yb.yugabyted.*' Reviewers: nikhil Reviewed By: nikhil Subscribers: yugabyted-dev, sgarg-yb Differential Revision: https://phorge.dev.yugabyte.com/D42781
1 parent 809936f commit 9376276

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

bin/yugabyted

+3-4
Original file line numberDiff line numberDiff line change
@@ -2655,11 +2655,10 @@ class ControlScript(object):
26552655
Output.log(out)
26562656
status_details = [
26572657
(Output.make_yellow("Status"), out),
2658+
(Output.make_yellow("Key Location"), f"The Encryption key is " +
2659+
f"stored at {key_path}. Moving the encryption key to a " +
2660+
"secure location is strongly advised. "),
26582661
]
2659-
2660-
Output.log("Deleting the universe key generated for encryption at rest.")
2661-
if os.path.isdir(key_dir):
2662-
shutil.rmtree(key_dir)
26632662
# Disabling encryption at rest
26642663
else:
26652664
Output.log("Trying to disable encryption at rest.")

0 commit comments

Comments
 (0)