ansible / ansible.builtin / v2.9.17 / module / _net_logging
Removed in 2.13
Reason:Updated modules released with more functionality | Alternative:Use platform-specific "[netos]_logging" module
Manage logging on network devices
| "added in version" 2.4 of ansible.builtin"
Authors: Ganesh Nalawade (@ganeshrn)
deprecated | supported by network
pip
Install with pip install ansible==2.9.17
This module provides declarative management of logging on network devices.
- name: configure console logging net_logging: dest: console facility: any level: critical
- name: remove console logging configuration net_logging: dest: console state: absent
- name: configure host logging net_logging: dest: host name: 192.0.2.1 facility: kernel level: critical
- name: Configure file logging using aggregate net_logging: dest: file aggregate: - name: test-1 facility: pfe level: critical - name: test-2 facility: kernel level: emergency
- name: Delete file logging using aggregate net_logging: dest: file aggregate: - name: test-1 facility: pfe level: critical - name: test-2 facility: kernel level: emergency state: absent
dest: choices: - console - host description: - Destination of the logs. name: description: - If value of C(dest) is I(host) it indicates file-name the host name to be notified. level: description: - Set logging severity levels. purge: default: false description: - Purge logging not defined in the I(aggregate) parameter. state: choices: - present - absent default: present description: - State of the logging configuration. facility: description: - Set logging facility. aggregate: description: List of logging definitions.
commands: description: The list of configuration mode commands to send to the device returned: always, except for the platforms that use Netconf transport to manage the device. sample: - logging console critical type: list