Skip to content

AMBARI-26029: Oozie upgrade fails with incorrect result output #3762

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

Closed
wants to merge 2 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,9 @@ def prepare_war(params):

# DON'T CHANGE THE VALUE SINCE IT'S USED TO DETERMINE WHETHER TO RUN THE COMMAND OR NOT BY READING THE MARKER FILE.
# Oozie tmp dir should be /var/tmp/oozie and is already created by a function above.
command = format(
"cd {oozie_tmp_dir} && {oozie_setup_sh} prepare-war {oozie_secure}"
).strip()
command = format("cd {oozie_tmp_dir} && {oozie_setup_sh} {oozie_secure}").strip()
# oozie_setup_sh and oozie_setup_sh_current are different during Ambaripreupload
command_to_file = format(
"cd {oozie_tmp_dir} && {oozie_setup_sh_current} prepare-war {oozie_secure}"
).strip()
command_to_file = format("cd {oozie_tmp_dir} && {oozie_setup_sh_current} {oozie_secure}").strip()

run_prepare_war = False
if os.path.exists(prepare_war_cmd_file):
Expand Down Expand Up @@ -106,10 +102,8 @@ def prepare_war(params):
if output is None:
output = ""

if (
return_code != 0 or "New Oozie WAR file with added".lower() not in output.lower()
):
message = f"Unexpected Oozie WAR preparation output {output}"
if return_code != 0:
message = "Non zero Oozie setup return code {0}".format(output)
Logger.error(message)
raise Fail(message)

Expand Down