Cisco ACI - Configure NTP with Fabric-Wide Policy¶
Introduction¶
In a traditional device-centered operating model, infrastructure-wide services such as NTP, DNS, SNMP, and logging are often configured through repeated device-level workflows. As the number of devices grows, maintaining consistent configuration across the environment becomes increasingly important.
Cisco ACI demonstrates a different operational model. This lab uses NTP as a simple example: the policy is defined centrally on the Application Policy Infrastructure Controller (APIC), associated with the fabric, and then applied across the relevant nodes. The goal is not only to configure time synchronization, but to understand what intent-based networking changed about the way engineers express and apply network intent.

Software-defined networking introduced the controller as a central control point. Intent-based networking built on it by capturing intent as policy that the controller translates and applies. Network as Code takes it a step further with declarative models, where intent is described as code. Configuration entered through the APIC GUI is not automatically captured in a Git-based source-of-truth workflow, so it is not reviewed or validated before it reaches the controller. With Network as Code, the intent is stored in Git, reviewed, and validated before it is pushed to the controller. This lab builds the NTP policy in the APIC GUI and then shows the equivalent as Network as Code.
The Network Time Protocol (NTP) synchronizes the time of day among a set of distributed time servers and clients. NTP uses the User Datagram Protocol (UDP) as its transport protocol.
In this scenario, NTP is used to synchronize the Cisco Application Policy Infrastructure Controller (APIC) and the fabric to an NTP daemon running in the lab (NTP daemon configuration is out of scope for this document). NTP will start working after out-of-band (OOB) management IP addresses are configured on the fabric switches.
The Bigger Idea: From Device Configuration to Policy¶
The important shift is the unit of operation. Instead of treating every switch as an isolated configuration target, the engineer defines a fabric-level policy and lets the controller apply that intent to the appropriate infrastructure. NTP makes this easy to see because the desired configuration is common across multiple fabric nodes.
Instead of asking: "How do I configure every individual switch?"
We start asking: "What is the desired policy for the fabric?"
| Device-Centered | Intent-Based | Network as Code |
|---|---|---|
| Configuration is centered on individual network devices and repeated device-level workflows. | Intent is defined centrally as policy and associated with the fabric or selected infrastructure. | Intent is expressed declaratively, version-controlled, validated, reviewed, and automated through APIs/controllers. |
Configure NTP in Fabric Policy¶
Time synchronization is a crucial capability upon which many of the monitoring, operational, and troubleshooting tasks depend. Time synchronization is required for Cisco Application Centric Infrastructure (ACI) atomic counters. Clock synchronization is important for proper analysis of traffic flows and for correlating debug and fault time stamps across multiple fabric nodes. NTP is the most widely adopted method for synchronizing a device clock.
NTP communication can use the in-band or OOB management network. In this scenario, you will implement NTP using OOB management.
Go to Fabric > Fabric Policies > Policies > Pod > Date and Time. Right-click the menu and select Create Date and Time Policy.

Name the policy NTP, leave the states unchanged (administrative state enabled, server state disabled, authentication state disabled) and click Next.

Click the plus sign (+) in the table to add an NTP server with the settings below.
- Name: 192.168.10.15
- Management EPG: default (Out-of-Band).

Leave other settings at their default values, then click OK and Finish.

In Fabric > Fabric Policies > Pods, right-click Policy Groups to Create Pod Policy Group.

Configure the pod policy group name Pod_PG and choose the Date Time policy NTP. Click Submit.

Go to Fabric > Fabric Policies > Pods > Profiles > Pod Profile default > default. Choose the pod selector default and select the Pod_PG policy from the Fabric Policy Group drop-down. Click Update and Continue.


Assigning the fabric policy group (Pod_PG) to the default pod selector applies the NTP configuration to all fabric switches and Cisco APIC controllers in your fabric.
Why this matters
The engineer is not entering the same NTP configuration separately on leaf-a, leaf-b, spine-201, and the APIC controllers. The NTP policy is defined centrally and associated with the fabric so that APIC can apply the intended policy across the relevant nodes.
Return to the NTP server configuration in Fabric > Fabric Policies > Policies > Pod > Date and Time > Policy NTP > NTP Server 192.168.10.15, select the Operational tab and examine the Sync Status.

The NTP server is not selected for sync because out-of-band management is not configured yet.
Centralized policy does not replace connectivity
The policy can be defined centrally, but the fabric nodes still need network reachability to the NTP server. In this lab, synchronization is not possible until out-of-band management connectivity is configured. For out-of-band NTP, the NTP server must also be reachable from the management addresses of the nodes, and the OOB management EPG and contracts must allow UDP port 123. The controller changes how intent is expressed and distributed; the underlying network still has to work.
Log in to the APIC and verify the NTP status using the ntpstat command.

Note
The Stratum describes the distance in NTP hops from the highest NTP hierarchy (Stratum 0).
Log in to an ACI leaf from the APIC and examine the NTP peer status using the show ntp peer-status command.

The NTP peer status information will be missing because the switch does not have connectivity to the NTP server, neither OOB nor in-band.
Configure Out-of-Band Management¶
OOB management addresses on the fabric switches are configured by defining Static Node Management Addresses for the node ranges. First, configure the addresses for the leaf range (node IDs 101-102), verify the results and finally configure the address of the single spine.
Go to the Tenants menu, select the mgmt tenant, navigate to Node Management Addresses > Static Node Management Addresses and right-click the menu to Create Static Node Management Addresses.
Configure the OOB management addresses for nodes 101–102 (leaf-a and leaf-b) with the settings below. Then click Submit and Yes to confirm the configuration.
- Node Range: 101-102
- Config: Select Out-Of-Band Addresses
- Out-Of-Band management EPG: default
- Out-Of-Band IPv4 address (include the mask): 192.168.10.211/24
- Out-Of-Band IPv4 gateway: 192.168.10.254


The defined IP address is assigned to node 101, the next incremented IP address is assigned to node 102.
Configure the OOB management address for node 201 (spine) with the settings below. Then click Submit and Yes to confirm the configuration.
- Node Range: 201-201
- Config: Select Out-Of-Band Addresses
- Out-Of-Band management EPG: default
- Out-Of-Band IPv4 address (include the mask): 192.168.10.213/24
- Out-Of-Band IPv4 gateway: 192.168.10.254

Use PuTTY to connect via SSH to leaf-a IP address 192.168.10.211

This connection verifies the OOB access to leaf-a.
On leaf-a, view the IP interfaces in the management VRF.

The Static Node Management Address assigned to the node has been applied to the mgmt0 in the management VRF.
Verify the management IP addresses in the APIC user interface. Go to Fabric > Inventory > Pod 1, select a switch and choose the General tab.

The OOB management IP addresses are shown in the General tab.
You can also examine the OOB management IP address by expanding the switch and selecting Interfaces > Management Interfaces > mgmt0, as shown below:

Go to Fabric > Fabric Policies > Policies > Pod > Date and Time > Policy NTP and choose your NTP server. Examine the information in the Operational tab.

Optionally you may verify the NTP status in the switch CLI. Use PuTTY to connect to the switches through SSH. The show ntp peer-status command would first show the status as "polled in client mode" and then as "selected for sync."

From Intent-Based Networking to Network as Code¶
Intent-based networking changed where network intent can be defined. In ACI, APIC provides a centralized policy model for the fabric. Network as Code takes the same direction further by expressing intended state in declarative files and integrating that intent with source control, review, validation, and automated deployment workflows.
The progression is important: intent-based networking reduces the need to think only in terms of individual devices, while Network as Code makes the intended configuration easier to reproduce, review, test, and automate. The controller remains a critical execution point, but the source of intent can now live in a governed software workflow.
| Device-Centered Operations | Intent-Based Networking | Network as Code |
|---|---|---|
| Configuration and troubleshooting are centered on individual devices and device-level workflows. | Policy is defined centrally on a controller and associated with the fabric or selected nodes. | Intent is defined declaratively, stored in version control, validated, reviewed, and automated through APIs/controllers. |
The same policy as code¶
The NTP policy built in this lab can also be written as declarative data. The Network as Code data model for ACI describes the same objects that the GUI created, and each one maps to a key in a YAML file.
apic:
fabric_policies:
pod_policies:
date_time_policies:
- name: NTP
ntp_servers:
- hostname_ip: 192.168.10.15
mgmt_epg: oob
preferred: false
pod_policy_groups:
- name: Pod_PG
date_time_policy: NTP
pod_profiles:
- name: default
selectors:
- name: default
type: all
policy: Pod_PG
Notice that the YAML sets mgmt_epg: oob and preferred: false explicitly. The data model defaults are inb and true, while the settings used in this lab give Out-of-Band and Preferred False. In code, intent is stated rather than inherited from defaults.
The out-of-band node addresses configured later in the lab follow the same pattern. The data model also requires the role of each node:
apic:
node_policies:
oob_endpoint_group: default
nodes:
- id: 101
role: leaf
oob_address: 192.168.10.211/24
oob_gateway: 192.168.10.254
- id: 102
role: leaf
oob_address: 192.168.10.212/24
oob_gateway: 192.168.10.254
- id: 201
role: spine
oob_address: 192.168.10.213/24
oob_gateway: 192.168.10.254
Each GUI step in this lab has a direct equivalent in the data model:
| GUI step in this lab | Network as Code data model |
|---|---|
| Date and Time policy NTP | apic.fabric_policies.pod_policies.date_time_policies |
| NTP server 192.168.10.15 on the out-of-band EPG | ntp_servers: hostname_ip, mgmt_epg |
| Pod Policy Group Pod_PG using the Date Time policy NTP | apic.fabric_policies.pod_policy_groups: date_time_policy |
| Pod selector default assigned the Pod_PG policy group | apic.fabric_policies.pod_profiles: selectors: type, policy |
| Static Node Management Addresses for nodes 101, 102 and 201 | apic.node_policies.nodes: oob_address, oob_gateway |
The intent is the same as in the GUI workflow, expressed as code instead of clicks, but the way it is governed is different. Intent-based networking changed where intent is defined; Network as Code changes how it is governed. Because the policy lives in a YAML file, every change is visible in Git as a record of why, when and by whom it was made. It can be reviewed before it is merged, validated before it ever reaches the APIC, deployed through an automated pipeline, and tested afterwards to confirm that the fabric reached the intended state. The objective is not simply to configure ACI faster, but to give every network change a disciplined and repeatable engineering lifecycle.
Reference: netascode.cisco.com/docs/data_models/apic (Date and Time Policy, Pod Policy Group, Fabric Pod Profile and OOB Node Address).
Conclusion¶
This lab configured NTP, but NTP was only the vehicle for demonstrating a broader architectural change. A single policy was defined centrally, associated with the ACI fabric, and applied across multiple nodes. Verification at the APIC and switch CLI then confirmed the resulting state. That combination - centralized intent, fabric-wide application, and independent verification - is one of the clearest ways to see how networking evolved beyond repetitive device-by-device configuration.
Key takeaway
NTP is the example. The real lesson is the evolution from configuring devices, to defining centralized policy, to expressing and governing network intent as code.
For more labs visit my GitHub repo: https://github.com/TitusM/Cisco-Data-Center
References¶
- Configure NTP in ACI Fabric Solution: https://www.cisco.com/c/en/us/support/docs/cloud-systems-management/application-policy-infrastructure-controller-apic/200128-Configuring-NTP-in-ACI-Fabric-Solution.html
- Troubleshoot NTP in a Cisco ACI Fabric: https://www.cisco.com/c/en/us/support/docs/cloud-systems-management/application-policy-infrastructure-controller-apic/225710-troubleshoot-ntp-in-a-cisco-aci-fabric.html
- Network as Code: https://netascode.cisco.com
- Intent-Based Networking: https://www.cisco.com/site/us/en/solutions/intent-based-networking/index.html
- What is a Network Controller: https://www.cisco.com/site/us/en/learn/topics/networking/what-is-a-network-controller.html