community.network.cnos_reload – Perform switch restart on devices running Lenovo CNOS¶
Note
This plugin is part of the community.network collection (version 2.1.1).
To install it use: ansible-galaxy collection install community.network
.
To use it in a playbook, specify: community.network.cnos_reload
.
Synopsis¶
This module allows you to restart the switch using the current startup configuration. The module is usually invoked after the running configuration has been saved over the startup configuration. This module uses SSH to manage network device configuration. The results of the operation can be viewed in results directory.
Parameters¶
Notes¶
Note
For more information on using Ansible to manage Lenovo Network devices see https://www.ansible.com/ansible-lenovo.
Examples¶
Tasks : The following are examples of using the module cnos_reload. These are
written in the main.yml file of the tasks directory.
---
- name: Test Reload
community.network.cnos_reload:
deviceType: "{{ hostvars[inventory_hostname]['deviceType'] }}"
outputfile: "./results/test_reload_{{ inventory_hostname }}_output.txt"
Return Values¶
Common return values are documented here, the following are the fields unique to this module:
Key | Returned | Description |
---|---|---|
msg
string
|
always |
Success or failure message
Sample:
Device is Reloading. Please wait...
|
Authors¶
Anil Kumar Muraleedharan (@amuraleedhar)