Added in version 1.8
Activate a new current-running config in realtime
parameter | required | default | choices | comments |
---|---|---|---|---|
config_file | yes | File that will be sent to the device. Relative path is location of Ansible playbook. Recommended to use absolute path. | ||
commit_changes | yes |
|
Used to determine the action to take after transferring the config to the switch. Either activate using the rollback feature or load on next-reboot. | |
diff_file | no | File that will be used to store the diffs. Relative path is location of ansible playbook. If not set, no diffs are saved. | ||
port | no | 830 | NETCONF port number | |
hostname | yes | IP Address or hostname of the Comware 7 device that has NETCONF enabled | ||
username | yes | Username used to login to the switch | ||
password | yes | Password used to login to the switch | ||
look_for_keys | no | False | Whether searching for discoverable private key files in ~/.ssh/ |
# install config file that will be the new running config - comware_install_config: config_file='/root/ansible-hpe-cw7-master/gqy/123.cfg' diff_file='/root/ansible-hpe-cw7-master/gqy/diffs.diff' commit_changes=true username={{ username }} password={{ password }} hostname={{ inventory_hostname }}
Note
Check mode copies config file to device and still generates diffsdiff_file must be specified to write diffs to a file, otherwise,only summarized diffs are returned from the modulecommit_changes must be true to apply changesthis module does an automatic backup of the existing configto the filename flash:/safety_file.cfgthis module does an auto save to flash:/startup.cfg upon completionconfig_file MUST be a valid FULL config file for a given device.