Skip to content

Commit

Permalink
Update version to 2.2.2 (#511)
Browse files Browse the repository at this point in the history
* logging update

* updating version for testing

* updating version to 2.2.2
  • Loading branch information
hglkrijger authored Dec 12, 2016
1 parent edba18b commit 515415a
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 7 deletions.
2 changes: 1 addition & 1 deletion azurelinuxagent/common/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ def get_distro():

AGENT_NAME = "WALinuxAgent"
AGENT_LONG_NAME = "Azure Linux Agent"
AGENT_VERSION = '2.2.1'
AGENT_VERSION = '2.2.2'
AGENT_LONG_VERSION = "{0}-{1}".format(AGENT_NAME, AGENT_VERSION)
AGENT_DESCRIPTION = """\
The Azure Linux Agent supports the provisioning and running of Linux
Expand Down
15 changes: 9 additions & 6 deletions azurelinuxagent/daemon/resourcedisk/default.py
Original file line number Diff line number Diff line change
Expand Up @@ -182,20 +182,23 @@ def change_partition_type(self, suppress_message, option_str):

command_to_use = '--part-type'
input = "sfdisk {0} {1} {2}".format(command_to_use, '-f' if suppress_message else '', option_str)
err_code, output = shellutil.run_get_output(input, chk_err=False)
err_code, output = shellutil.run_get_output(input, chk_err=False, log_cmd=True)

# fall back to -c
if err_code != 0:
logger.info("sfdisk with --part-type failed with error_code {0}. Retry with -c.", err_code)
logger.info("sfdisk with --part-type failed [{0}], retrying with -c", err_code)
command_to_use = '-c'
input = "sfdisk {0} {1} {2}".format(command_to_use, '-f' if suppress_message else '', option_str)
err_code, output = shellutil.run_get_output(input)
err_code, output = shellutil.run_get_output(input, log_cmd=True)

log_message = "sfdisk {0} with return code {1} and output {2}"
if err_code == 0:
logger.info(log_message, 'succeeded', err_code, output)
logger.info('{0} succeeded',
input)
else:
logger.error(log_message, 'failed', err_code, output)
logger.error('{0} failed [{1}: {2}]',
input,
err_code,
output)

return err_code, output

Expand Down

0 comments on commit 515415a

Please sign in to comment.