cisco.catalystcenter.switches_configs_intended_network_settings_update module -- Resource module for Switches Configs Intended Network Settings Update

Note

This module is part of the cisco.catalystcenter collection (version 2.12.0).

To install it, use: ansible-galaxy collection install cisco.catalystcenter. You need further requirements to be able to use this module, see Requirements for details.

To use it in a playbook, specify: cisco.catalystcenter.switches_configs_intended_network_settings_update.

New in cisco.catalystcenter 2.11.0

Synopsis

  • Manage operation update of the resource Switches Configs Intended Network Settings Update. - > This API updates the configurations for an intended feature on a switch. Updates to other intended features can be done over several iterations. Once all the updates to intended features are complete, they can be deployed to a device using the API /api/v1/switches/{id}/configs/intended/deploy. When the intended features are deployed, they are applied on top of the existing configurations on the device. Any existing configurations on the device which are not included in the intended features, are retained on the device.

Note

This module has a corresponding action plugin.

Requirements

The below requirements are needed on the host that executes this module.

  • catalystcentersdk >= 3.2.3.0.0

  • python >= 3.12

Parameters

Parameter

Comments

catalystcenter_debug

aliases: dnac_debug

boolean

Flag for Cisco Catalyst Center SDK to enable debugging.

Choices:

catalystcenter_host

aliases: dnac_host

string / required

The Cisco Catalyst Center hostname.

catalystcenter_password

aliases: dnac_password

string

The Cisco Catalyst Center password to authenticate.

catalystcenter_port

aliases: dnac_port, catalystcenter_api_port

integer

The Cisco Catalyst Center port.

Default: :ansible-option-default:`443`

catalystcenter_username

aliases: dnac_username, user

string

The Cisco Catalyst Center username to authenticate.

Default: :ansible-option-default:`"admin"`

catalystcenter_verify

aliases: dnac_verify

boolean

Flag to enable or disable SSL certificate verification.

Choices:

catalystcenter_version

aliases: dnac_version

string

Informs the SDK which version of Cisco Catalyst Center to use.

Default: :ansible-option-default:`"3.1.6.0"`

dhcpExcludedAddressConfig

dictionary

Feature configures mapping to Excluded addresses, both excluded low-address IP and excluded low-high IP ranges.

items

list / elements=dictionary

List of intended DHCP excluded address configuration entries.

configType

string

Either a excluded low address or an excluded low high address range.

ipDhcpExcludedLowAddressConfig

dictionary

Contains a list of low-address configurations.

items

list / elements=dictionary

List of low-address configurations.

configType

string

The operation and management of a list of low IP addresses available for Dynamic Host Configuration Protocol (DHCP) allocation.

excludedAddressLow

string

Lowest IP address to exclude from DHCP assignment. Use this to reserve addresses that should not be assigned to clients.

ipDhcpExcludedLowHighAddressConfig

dictionary

Contains a list of low-high address configurations.

items

list / elements=dictionary

List of low-high address configurations.

configType

string

Configures lists of addresses with specified lower and upper limits in the network settings.

excludedAddressHigh

string

Highest IP address to exclude from DHCP assignment. Use this to define the upper end of an exclusion range for reserved addresses.

excludedAddressLow

string

Lowest IP address in the exclusion range for DHCP assignment. This marks the start of a block of addresses that will not be assigned by DHCP.

dhcpGeneralConfig

dictionary

This feature is for configuring DHCP BOOTP protocol.

items

list / elements=dictionary

List of intended DHCP BOOTP configuration entries.

configType

string

Lease parameters and settings for IP address allocation using DHCP or BOOTP within a network.

isBootpIgnoreEnabled

boolean

Ignores BOOTP packets in DHCP processing. Enable this to prevent BOOTP requests from being processed by the DHCP server, reducing unnecessary traffic. Unconfigure Value - use false to revert to default settings.

Choices:

domainConfig

dictionary

This feature is for configuring IP domain.

items

list / elements=dictionary

List of intended IP domain configuration entries.

configType

string

Type of network functionality under a feature. Config type IP_DOMAIN_CONFIG is for configuring domain generation algorithm parameters used for dynamic domain name generation.

domainName

string

Default domain name for DNS resolution. This domain name is appended to unqualified hostnames during DNS lookups, facilitating proper name resolution within the specified domain. Supported IOS-XE versions - This property is viewable only (read-only) on Cisco switches running IOS version earlier than 17.15.1. Since IOS version 17.15.1 or later, configuration for this property is supported. Unconfigure Value - use "" to unconfigure.

ipDomainList

dictionary

Container for additional IP domain list entries.

configType

string

Type of IP domain list.

items

list / elements=dictionary

List of IP domain list entries.

configType

string

Configurable lists of IP domains that are utilized for setting domain-based parameters and policies within a network.

domainNameList

string

Name of the domain for DNS resolution. Assign a domain name to be used for DNS lookups and network identification. Unconfigure Value - use "" to unconfigure.

ipDomainName

dictionary

Container for IP domain name entries associated with VRFs.

configType

string

Type of IP domain name.

items

list / elements=dictionary

List of IP domain name entries.

configType

string

Resolving and assigning IP domain names to network devices and interfaces.

domainWithVrf

dictionary

Container for IP domain entries scoped to specific VRFs.

configType

string

Type of IP domain VRF configs.

items

list / elements=dictionary

List of VRF-scoped IP domain entries.

configType

string

Configurations related to IP domain and virtual routing and forwarding settings.

domainName

string

Name of the domain container for a specific VRF. Use this to configure DNS settings for a particular VRF instance. Unconfigure Value - use "" to unconfigure.

vrfName

string

VRF name for the domain container. Specify the VRF to associate with the domain container for segmented DNS resolution. Derived From - The available VRF names include both VRF Definition and IPv4 VRF configurations from the device.

isLookupEnabled

boolean

Enable IP Domain Name System hostname translation. Unconfigure Value - use true to revert to default settings.

Choices:

sourceLoopbackInterface

integer

Loopback interface used as the source for domain name system packets. Specify which loopback interface should be used for outgoing DNS messages, helping with source address consistency and security. Derived From - The available loopback interface numbers include those defined in the current profile and those configured on the device. Unconfigure Value - use -1 to unconfigure.

timeout

integer

Timeout value in seconds for DNS domain name resolution attempts. This setting determines how long the device waits for a DNS response before considering the attempt failed. Adjusting this value can help optimize DNS performance and reliability in your network. Unconfigure Value - use 5 to revert to default settings.

feature

string

Feature path parameter. Name of the feature to configure.

id

string

Id path parameter. Network device id of the switch to configure. The Network device id is identified from the GET network device API /dna/intent/api/v1/network-device response.

ipV4DhcpPoolConfig

dictionary

This feature is for configuring IP DHCP pools.

items

list / elements=dictionary

List of intended IPv4 DHCP pool configuration entries.

configType

string

Type of network functionality under a feature. Config type IPV4_DHCP_POOL_CONFIG is for configuring resource allocation and management within a dynamically generated pool architecture.

defaultRouterList

string

List of default router IP addresses for DHCP clients. Specify one or more gateway addresses that will be provided to DHCP clients for network routing. Unconfigure Value - use "" to unconfigure.

dnsServerList

string

List of DNS server IP addresses for DHCP clients. Enter the DNS servers that DHCP clients should use for name resolution. Unconfigure Value - use "" to unconfigure.

domainName

string

Domain name assigned to DHCP clients. This value is provided to clients for DNS search domains and network identification. Unconfigure Value - use "" to unconfigure.

leaseDays

integer

Number of days for DHCP lease duration. Set how long a DHCP client can keep its assigned IP address before renewal is required. Unconfigure Value - use 1 to revert to default settings.

leaseHours

integer

Number of hours for DHCP lease duration. Use this to fine-tune the lease period for DHCP clients. Unconfigure Value - use 0 to revert to default settings.

leaseMinutes

integer

Number of minutes for DHCP lease duration. Specify the lease time in minutes for more granular control. Unconfigure Value - use 0 to revert to default settings.

optionCode

dictionary

Custom DHCP options for advanced configuration. Use this to define additional DHCP options such as vendor-specific settings.

configType

string

Type of option range.

items

list / elements=dictionary

List of DHCP option code entries for the IPv4 DHCP pool.

asciiString

string

ASCII string for DHCP option configuration. Use this to set custom DHCP options using text values. Unconfigure Value - use "" to unconfigure.

configType

string

Type of network functionality under a feature. Config type OPTION_RANGE_CONFIG is for configuring options within a specified range for generating feasible network settings.

hexadecimalString

string

Hexadecimal string for DHCP option configuration. Enter custom DHCP options in hexadecimal format for advanced settings. Unconfigure Value - use "" to unconfigure.

ipAddresses

string

Ordered list of IP addresses for DHCP option configuration. Provide multiple IP addresses in a specific order for DHCP options. Supported IOS-XE versions - This property is viewable only (read-only) on Cisco switches running IOS version earlier than 17.15.1. Since IOS version 17.15.1 or later, configuration for this property is supported. Unconfigure Value - use "" to unconfigure.

ipAddressString

string

IP address for DHCP option configuration. Specify an IP address for custom DHCP options. Unconfigure Value - use "" to unconfigure.

optionCode

integer

Range of values for DHCP option configuration. Use this to define a set of possible values for a DHCP option. Derived From - The available DHCP option codes are determined by the device's IOS-XE software version, providing options 43, 60, 66, 67, and 150 for version 17.15.1 or later, and only options 43, 60, and 67 for earlier versions.

poolName

string

Unique identifier for the DHCP pool. Assign a name or ID to distinguish different DHCP pools for various network segments.

primaryNetworkMask

string

Subnet mask for the primary DHCP pool network. Define the network mask to specify the size of the DHCP pool. Unconfigure Value - use "" to unconfigure.

primaryNetworkNumber

string

Network number for the primary DHCP pool. Enter the base network address for the DHCP pool. Unconfigure Value - use "" to unconfigure.

vrfName

string

VRF name for DHCP pool, enabling logical network segmentation. Assign a VRF to the DHCP pool to support multi-tenant or segmented networks. Unconfigure Value - use "" to unconfigure.

ipV6DhcpPoolConfig

dictionary

This feature is for configuring IPv6 DHCP pools.

items

list / elements=dictionary

List of intended IPv6 DHCP pool configuration entries.

configType

string

Type of network functionality under a feature. Config type IPV6_DHCP_POOL_CONFIG is for configuring IPv6 DHCP address pools and related settings for automated network address management.

dnsServer

string

List of DNS server IPv6 addresses for DHCPv6 clients. Specify one or more DNS servers to be provided to clients for IPv6 name resolution. Unconfigure Value - use "" to unconfigure.

domainNames

string

List of domain names assigned to DHCPv6 clients. These domains are provided to clients for DNS search and network identification. Unconfigure Value - use "" to unconfigure.

poolName

string

Name of the DHCPv6 pool. Assign a unique name to identify and manage the pool for IPv6 address assignments.

prefix

dictionary

Container for IPv6 DHCP pool prefix entries.

configType

string

Ipv6 prefix for DHCP.

items

list / elements=dictionary

List of IPv6 DHCP pool prefix entries.

configType

string

Global IPv6 address prefixes for general use within the network.

ipV6Prefix

string

IPv6 address prefix for DHCPv6 pool assignment. This prefix defines the range of IPv6 addresses that can be dynamically assigned to clients from the pool. Unconfigure Value - use "" to unconfigure.

poolName

string

Name of the DHCPv6 pool. Assign a unique name to identify and manage the pool for IPv6 address assignments. Unconfigure Value - use "" to unconfigure.

preferredLifetime

integer

Preferred lifetime in seconds for the DHCPv6 pool prefix. This value sets how long an IPv6 address is preferred for use before renewal is recommended. Unconfigure Value - use 86400 to revert to default settings.

validLifetime

integer

Valid lifetime in seconds for the DHCPv6 pool prefix. This value determines how long an IPv6 address remains valid before it must be released or renewed. Unconfigure Value - use 172800 to revert to default settings.

nameServerConfig

dictionary

This feature is for configuring name server.

items

list / elements=dictionary

List of intended name server configuration entries.

configType

string

Type of network functionality under a feature. Config type NAME_SERVER_CONFIG is for configuring DNS server generation parameters.

nameServers

string

List of DNS server IP addresses used for global name resolution. Enter up to 6 IPv4 or IPv6 addresses separated by spaces or commas. These servers resolve hostnames for all traffic not associated with a VRF. Unconfigure Value - use "" to unconfigure.

nameServerWithVrf

dictionary

Container for name server entries associated with specific VRFs.

configType

string

Type of name servers with vrf.

items

list / elements=dictionary

List of VRF-specific name server entries.

configType

string

DNS settings across the entire network.

nameServers

string

List of DNS server IP addresses for name resolution within a specific VRF. This allows different DNS servers for different network segments, supporting multi-tenancy. Unconfigure Value - use "" to unconfigure.

vrfName

string

Name of the VRF instance for which DNS servers are configured. VRF provides logical network segmentation and isolation for enhanced security. Derived From - The available VRF names include both VRF Definition and IPv4 VRF configurations from the device.

ntpAuthenticationKeyConfig

dictionary

This feature is for configuring NTP which synchronizes the system clock with network time servers to ensure accurate timekeeping.

items

list / elements=dictionary

List of intended NTP authentication key configuration entries.

configType

string

Type of network functionality configured for NTP. Config type NTP_AUTH_KEY_CONFIG is for configuring NTP authentication key.

encryptionType

integer

Encryption type for NTP authentication key. Choose the algorithm used to secure NTP authentication keys, enhancing security for time synchronization.

keyNumber

integer

Key number for NTP authentication. Assign a unique number to each authentication key for NTP, allowing multiple keys to be managed and referenced.

md5

string

MD5 authentication. Unconfigure Value - use "" to unconfigure.

md5Config

string

MD5 configuration string for NTP authentication key. Enter the MD5 hash or string used for authenticating NTP messages, ensuring only trusted sources are accepted. Unconfigure Value - use "" to unconfigure.

ntpGeneralConfig

dictionary

This feature is for configuring NTP which synchronizes the system clock with network time servers to ensure accurate timekeeping.

items

list / elements=dictionary

List of intended NTP global configuration entries.

configType

string

Type of network functionality configured for NTP. Config type NTP_GENERAL_CONFIG is for configuring settings for NTP.

isAuthenticateEnabled

boolean

Enables NTP authentication. When enabled, the device will verify NTP messages using authentication keys to ensure time synchronization is secure and trusted. Unconfigure Value - use false to revert to default settings.

Choices:

isLoggingEnabled

boolean

Enables logging for NTP events. When enabled, the system records NTP synchronization events and errors, aiding in troubleshooting and auditing time-related issues. Unconfigure Value - use false to revert to default settings.

Choices:

sourceLoopbackInterface

integer

Loopback interface used as the source for NTP packets. Specify which loopback interface should be used for outgoing NTP messages, helping with source address consistency and security. Derived From - The available loopback interface numbers include those defined in the current profile and those configured on the device. Unconfigure Value - use -1 to unconfigure. Restrictions – Source Loopback Interface must exist in the Layer 3 profile or on the device before it can be used as this configuration.

stratum

integer

Stratum number for NTP authoritative source configuration. Set the stratum level to define the device's position in the NTP hierarchy, affecting how other devices prioritize it as a time source. Unconfigure Value - use 8 to revert to default settings.

ntpPerVrfServerConfig

dictionary

This feature is for configuring NTP which synchronizes the system clock with network time servers to ensure accurate timekeeping.

items

list / elements=dictionary

List of intended per-VRF NTP server configuration entries.

configType

string

The network time protocol server within a virtual routing and forwarding instance.

ntpVrfServerList

dictionary

Container for NTP server entries associated with the specified VRF.

configType

string

Type of name servers with vrf.

items

list / elements=dictionary

List of NTP server entries for the specified VRF.

configType

string

ConfigType NTP_VRF_SERVER_LIST_CONFIG is for configuring NTP servers within a specified VRF server list for network operations.

ipAddress

string

IP address of the NTP server in the VRF. Specify the server address used for time synchronization within a particular VRF context.

isPreferred

boolean

Marks the NTP server in the VRF as preferred. This prioritizes the server for time synchronization within the VRF. Unconfigure Value - use false to revert to default settings.

Choices:

peerAuthenticationKey

integer

Authentication key number for the NTP server in the VRF. Enter the key number for secure NTP communication within the VRF. Unconfigure Value - use 0 to unconfigure.

vrfName

string

Name of the VRF for NTP server configuration. Assign a VRF to the NTP server to support network segmentation and multi-tenancy for time services. Derived From - The available VRF names include both VRF Definition and IPv4 VRF configurations from the device, sorted alphabetically.

ntpServerConfig

dictionary

This feature is for configuring NTP which synchronizes the system clock with network time servers to ensure accurate timekeeping.

items

list / elements=dictionary

List of intended NTP server configuration entries.

configType

string

Type of network functionality under a feature. Config type NTP_SERVER_LIST_CONFIG is for configuring a comprehensive list of NTP servers that can be accessed globally across the network.

ipAddress

string

The NTP Server is the network device or service that provides accurate time synchronization using the Network Time Protocol. It can be identified by a hostname or an IPv4/IPv6 address.

isPreferred

boolean

Marks the NTP server as preferred. When enabled, this server is prioritized for time synchronization over others in the list. Unconfigure Value - use false to revert to default settings.

Choices:

peerAuthenticationKey

integer

Authentication key number for the NTP server. Enter the key number used to authenticate NTP messages from this server, ensuring secure time synchronization. Unconfigure Value - use 0 to unconfigure.

sourceInterface

string

Interface for source address. Unconfigure Value - use "" to unconfigure.

ntpTrustedKeyConfig

dictionary

This feature is for configuring NTP which synchronizes the system clock with network time servers to ensure accurate timekeeping.

items

list / elements=dictionary

List of intended NTP trusted key configuration entries.

configType

string

A set of trusted keys for secure NTP communications.

trustedKey

integer

Trusted key number for NTP authentication. Enter the key number that is considered trusted for authenticating NTP messages, ensuring only authorized sources are accepted.

validate_response_schema

boolean

Flag for Cisco Catalyst Center SDK to enable the validation of request bodies against a JSON schema.

Choices:

Notes

Note

  • SDK Method used are wired.Wired.update_intended_network_settings_configurations,

  • Paths used are put /dna/campus/api/v1/switches/{id}/configs/intended/networkSettings/{feature},

  • Does not support check_mode

  • The plugin runs on the control node and does not use any ansible connection plugins,

  • but instead uses the embedded connection manager from Cisco CATALYST SDK

  • Requires Python >= 3.10, matching the controller Python versions supported by the collection's minimum ansible-core version (see the collection README for the current ansible-core / Python compatibility range)

See Also

See also

Cisco Catalyst Center documentation for Wired UpdateIntendedNetworkSettingsConfigurations

Complete reference of the UpdateIntendedNetworkSettingsConfigurations API.

Examples

---
- name: Update by id
  cisco.catalystcenter.switches_configs_intended_network_settings_update:
    catalystcenter_host: "{{catalystcenter_host}}"
    catalystcenter_username: "{{catalystcenter_username}}"
    catalystcenter_password: "{{catalystcenter_password}}"
    catalystcenter_verify: "{{catalystcenter_verify}}"
    catalystcenter_port: "{{catalystcenter_port}}"
    catalystcenter_version: "{{catalystcenter_version}}"
    catalystcenter_debug: "{{catalystcenter_debug}}"
    dhcpExcludedAddressConfig:
      items:
        - configType: string
          ipDhcpExcludedLowAddressConfig:
            items:
              - configType: string
                excludedAddressLow: string
          ipDhcpExcludedLowHighAddressConfig:
            items:
              - configType: string
                excludedAddressHigh: string
                excludedAddressLow: string
    dhcpGeneralConfig:
      items:
        - configType: string
          isBootpIgnoreEnabled: true
    domainConfig:
      items:
        - configType: string
          domainName: string
          ipDomainList:
            configType: string
            items:
              - configType: string
                domainNameList: string
          ipDomainName:
            configType: string
            items:
              - configType: string
                domainWithVrf:
                  configType: string
                  items:
                    - configType: string
                      domainName: string
                      vrfName: string
          isLookupEnabled: true
          sourceLoopbackInterface: 0
          timeout: 0
    feature: string
    id: string
    ipV4DhcpPoolConfig:
      items:
        - configType: string
          defaultRouterList: string
          dnsServerList: string
          domainName: string
          leaseDays: 0
          leaseHours: 0
          leaseMinutes: 0
          optionCode:
            configType: string
            items:
              - asciiString: string
                configType: string
                hexadecimalString: string
                ipAddressString: string
                ipAddresses: string
                optionCode: 0
          poolName: string
          primaryNetworkMask: string
          primaryNetworkNumber: string
          vrfName: string
    ipV6DhcpPoolConfig:
      items:
        - configType: string
          dnsServer: string
          domainNames: string
          poolName: string
          prefix:
            configType: string
            items:
              - configType: string
                ipV6Prefix: string
                poolName: string
                preferredLifetime: 0
                validLifetime: 0
    nameServerConfig:
      items:
        - configType: string
          nameServerWithVrf:
            configType: string
            items:
              - configType: string
                nameServers: string
                vrfName: string
          nameServers: string
    ntpAuthenticationKeyConfig:
      items:
        - configType: string
          encryptionType: 0
          keyNumber: 0
          md5: string
          md5Config: string
    ntpGeneralConfig:
      items:
        - configType: string
          isAuthenticateEnabled: true
          isLoggingEnabled: true
          sourceLoopbackInterface: 0
          stratum: 0
    ntpPerVrfServerConfig:
      items:
        - configType: string
          ntpVrfServerList:
            configType: string
            items:
              - configType: string
                ipAddress: string
                isPreferred: true
                peerAuthenticationKey: 0
          vrfName: string
    ntpServerConfig:
      items:
        - configType: string
          ipAddress: string
          isPreferred: true
          peerAuthenticationKey: 0
          sourceInterface: string
    ntpTrustedKeyConfig:
      items:
        - configType: string
          trustedKey: 0

Return Values

Common return values are documented here, the following are the fields unique to this module:

Key

Description

catalystcenter_response

dictionary

A dictionary or list with the response returned by the Cisco Catalyst Center Python SDK

Returned: always

Sample: :ansible-rv-sample-value:`{"response": {"taskId": "string", "url": "string"}, "version": "string"}`

Authors

  • Bryan Vargas (@bvargasre)