You are reading an unmaintained version of the Ansible documentation. Unmaintained Ansible versions can contain unfixed security vulnerabilities (CVE). Please upgrade to a maintained version. See the latest Ansible documentation .
nxos_logging - Manage logging on network devices
This module provides declarative management of logging on Cisco NX-OS devices.
parameter
required
default
choices
comments
aggregate
no
List of logging definitions.
dest
no
console logfile module monitor
Destination of the logs.
dest_level
no
Set logging severity levels. alias level
.
facility
no
Facility name for logging.
facility_level
no
Set logging serverity levels for facility based log messages.
name
no
If value of dest
is logfile it indicates file-name.
purge
no
Purge logging not defined in the aggregate parameter.
state
no
present
State of the logging configuration.
- name : configure console logging with level
nxos_logging :
dest : console
level : 2
state : present
- name : remove console logging configuration
nxos_logging :
dest : console
level : 2
state : absent
- name : configure file logging with level
nxos_logging :
dest : logfile
name : testfile
dest_level : 3
state : present
- name : configure facility level logging
nxos_logging :
facility : daemon
facility_level : 0
state : present
- name : remove facility level logging
nxos_logging :
facility : daemon
facility_level : 0
state : absent
Common return values are documented here Return Values , the following are the fields unique to this module:
name
description
returned
type
sample
commands
The list of configuration mode commands to send to the device
always
list
['logging console 2', 'logging logfile testfile 3', 'logging level daemon 0']
This module is flagged as preview which means that it is not guaranteed to have a backwards compatible interface.
For more information about Red Hat’s this support of this module, please
refer to this knowledge base article<https://access.redhat.com/articles/rhel-top-support-policies>
For help in developing on modules, should you be so inclined, please read Community Information & Contributing , Testing Ansible and Developing Modules .
Copyright © 2017 Red Hat, Inc.
Last updated on Nov 15, 2022.
Ansible docs are generated from GitHub sources using Sphinx using a theme provided by Read the Docs . . Module documentation is not edited directly, but is generated from the source code for the modules. To submit an update to module docs, edit the 'DOCUMENTATION' metadata in the modules directory of the core source code repository .