You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Below are the snippets in playbook yaml values taken from inventory file
value of state is backup
- name: Trigger an on-demand backup for {{ vm_name }}
azure.azcollection.azure_rm_backupazurevm:
resource_group: '{{ resource_group }}'
recovery_vault_name: '{{ vault_name }}'
resource_id: '{{ vm_id }}'
backup_policy_id: '{{ policy_id }}'
recovery_point_expiry_time: '{{ backup_expiry_time }}'
state: '{{ state }}'
register: backup_creation
EXPECTED RESULTS
As per ansible documentation of the azure_rm_backupazurevm moduel, It should trigger ondemand backup of azure vm if state provided as backup
ACTUAL RESULTS
Wednesday 28 August 2024 12:12:01 +0000 (0:00:00.026) 0:00:05.047 ******
[WARNING]: Azure API profile latest does not define an entry for GenericRestClient
fatal: [<vm_name>]: FAILED! => changed=false
msg: 'Error while taking on-demand backup: (<RequestsTransportResponse: 400 Bad Request, Content-Type: application/json>, 400)'
The text was updated successfully, but these errors were encountered:
@SrinivasanSelvam From the error code you returned, it appears that you have a problem in submitting the request parameters. Can you help provide the following information? Because I followed the script below to create, update, stop, and delete azure VM backups without any problems.
First: detailed error information
Second: You back up the status of the virtual machine, the version of aze.azcollection you installed.
SUMMARY
On-demand backup of azure vm using ansible module provides 400 Bad Request
ISSUE TYPE
COMPONENT NAME
azure.azcollection.azure_rm_backupazurevm
ANSIBLE VERSION
COLLECTION VERSION
STEPS TO REPRODUCE
EXPECTED RESULTS
As per ansible documentation of the azure_rm_backupazurevm moduel, It should trigger ondemand backup of azure vm if state provided as backup
ACTUAL RESULTS
The text was updated successfully, but these errors were encountered: