Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
04fef19
Add arg to define thread limit - to throttle concurrent API calls whe…
monrog2 Feb 27, 2026
233359a
353 the script incorrectly detects vpc and port channel interfaces as…
monrog2 Feb 27, 2026
6d7d4d4
Update aci-preupgrade-validation-script.py
monrog2 Feb 27, 2026
e4defbf
print cleanup
monrog2 Feb 27, 2026
6a2fe7f
Merge branch 'master' of github.com:datacenter/ACI-Pre-Upgrade-Valida…
takishida Mar 7, 2026
aaee19d
Unsupported hardware check
dhaselva Mar 11, 2026
d849e8e
fix: Add cversion check for post_upgrade_cb_check (#377)
takishida Apr 3, 2026
67dab4b
added validation for CFD CSCwp64296 (#307)
psureshb Apr 3, 2026
6ccd6d9
Added pre-upgrade validation for N9K-C9408 with more than 6 N9K-X9400…
Harinadh-Saladi Apr 3, 2026
ea1e0f8
New Validation for APIC Storage Inode Usage (F4388, F4389, F4390 equi…
sanjanch Apr 3, 2026
dc09913
Add validation for multipod_modular_spine_bootscript_check - CSCwr668…
asraf-khan Apr 4, 2026
d118464
Update pytest.yml to run on vX.Y.Z branches
takishida Apr 4, 2026
07ea2db
adding of cli parameters for user and password (#335)
Thatleft Apr 4, 2026
91facd8
Merge branch 'v4.1.0-dev' of github.com:dhaselva/ACI-Pre-Upgrade-Vali…
dhaselva Apr 9, 2026
dc0b1e1
Addressed the review comments
dhaselva Apr 30, 2026
217dbcb
Added validation for CSCwd40071 (#332)
sanjanch May 8, 2026
fbf3a73
Addressed the review comments
dhaselva May 12, 2026
69d6a4b
Added validation for CSCws84232 (#334)
veenaskumar-cisco May 19, 2026
21252c6
Merge branch 'v4.1.0-dev' into dhaselva/N2k_fex
monrog2 May 19, 2026
e77b61d
Removed gen1_switch_compatibility_check
dhaselva May 20, 2026
3910c1c
pulled the latest changes
dhaselva May 20, 2026
4fc8bb9
Merge remote-tracking branch 'upstream/master' into dhaselva/N2k_fex
monrog2 May 21, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
86 changes: 71 additions & 15 deletions aci-preupgrade-validation-script.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
import os
import re

SCRIPT_VERSION = "v4.1.0"
SCRIPT_VERSION = "v4.2.0-dev"
DEFAULT_TIMEOUT = 600 # sec
# result constants
DONE = 'DONE'
Expand Down Expand Up @@ -3866,27 +3866,83 @@ def target_version_compatibility_check(cversion, tversion, **kwargs):
return Result(result=result, headers=headers, data=data, recommended_action=recommended_action, doc_url=doc_url)


@check_wrapper(check_title="Gen 1 switch compatibility")
def gen1_switch_compatibility_check(tversion, fabric_nodes, **kwargs):
@check_wrapper(check_title="Supported hardware compatibility")
Comment thread
monrog2 marked this conversation as resolved.
def supported_hardware_check(tversion, fabric_nodes, **kwargs):
result = FAIL_UF
headers = ["Target Version", "Node ID", "Model", "Warning"]
headers = ["Target Version", "Node ID", "Model", "Type", "Warning"]
data = []
unformatted_headers = ["Target Version", "DN", "Model", "Type", "Warning"]
unformatted_data = []
gen1_models = ["N9K-C9336PQ", "N9K-X9736PQ", "N9K-C9504-FM", "N9K-C9508-FM", "N9K-C9516-FM", "N9K-C9372PX-E",
"N9K-C9372TX-E", "N9K-C9332PQ", "N9K-C9372PX", "N9K-C9372TX", "N9K-C9396PX", "N9K-C9396TX",
"N9K-C93128TX"]
data = []
unsupported_6_0_1_switch_models = ["N9K-C93120TX"]
unsupported_6_1_1_switch_models = ["N9K-C93180LC-EX"]
unsupported_5_0_1_exp_module_models = ["N9K-M12PQ", "N9K-M6PQ", "N9K-M6PQ-E"]
unsupported_6_1_1_fex_models = ["N2K-C2332TQ-10GT", "N2K-C2348TQ-10GE", "N2K-C2232PP-10GE", "N2K-C2232TM-E-10GE", "N2K-C2348TQ-10G-E"]
unsupported_6_1_1_sup_models = ["N9K-SUP-A", "N9K-SUP-B"]
recommended_action = 'Select supported target version or upgrade hardware'
doc_url = 'https://datacenter.github.io/ACI-Pre-Upgrade-Validation-Script/validations/#compatibility-switch-hardware-gen1'
doc_url = 'https://datacenter.github.io/ACI-Pre-Upgrade-Validation-Script/validations/#supported-hardware-compatibility'

if not tversion:
return Result(result=MANUAL, msg=TVER_MISSING)
if tversion.newer_than("5.0(1a)"):
if not tversion.older_than("5.0(1a)"):
for node in fabric_nodes:
if node['fabricNode']['attributes']['model'] in gen1_models:
data.append([str(tversion), node['fabricNode']['attributes']['id'],
node['fabricNode']['attributes']['model'], 'Not supported on 5.x+'])
if not data:
model = node['fabricNode']['attributes']['model']
if model in gen1_models:
data.append([str(tversion), node['fabricNode']['attributes']['id'], model, 'Switch', 'Not supported on 5.x+'])

eqptLCs = icurl('class', 'eqptLC.json')
for eqptLC in eqptLCs:
model = eqptLC['eqptLC']['attributes']['model']
if model in unsupported_5_0_1_exp_module_models:
dn = re.search(node_regex, eqptLC['eqptLC']['attributes']['dn'])
if dn:
data.append([str(tversion), dn.group('node'), model, 'Expansion Module', 'Not supported on 5.x+'])
else:
unformatted_data.append([str(tversion), eqptLC['eqptLC']['attributes']['dn'], model, 'Expansion Module', 'Not supported on 5.x+'])

if not tversion.older_than("6.0(1a)"):
for node in fabric_nodes:
model = node['fabricNode']['attributes']['model']
if model in unsupported_6_0_1_switch_models:
data.append([str(tversion), node['fabricNode']['attributes']['id'], model, 'Switch', 'Deprecated from 6.0(1)+'])

if not tversion.older_than("6.1(1f)"):
for node in fabric_nodes:
model = node['fabricNode']['attributes']['model']
if model in unsupported_6_1_1_switch_models:
data.append([str(tversion), node['fabricNode']['attributes']['id'], model, 'Switch', 'Deprecated from 6.1(1)+'])

eqptExtChs = icurl('class', 'eqptExtCh.json')
for eqptExtCh in eqptExtChs:
model = eqptExtCh['eqptExtCh']['attributes']['model']
if model in unsupported_6_1_1_fex_models:
dn = re.search(node_regex, eqptExtCh['eqptExtCh']['attributes']['dn'])
if dn:
data.append([str(tversion), dn.group('node'), model, 'FEX', 'Deprecated from 6.1(1)+'])
else:
unformatted_data.append([str(tversion), eqptExtCh['eqptExtCh']['attributes']['dn'], model, 'FEX', 'Deprecated from 6.1(1)+'])

eqptSupCs = icurl('class', 'eqptSupC.json')
for eqptSupC in eqptSupCs:
model = eqptSupC['eqptSupC']['attributes']['model']
if model in unsupported_6_1_1_sup_models:
dn = re.search(node_regex, eqptSupC['eqptSupC']['attributes']['dn'])
if dn:
data.append([str(tversion), dn.group('node'), model, 'Supervisor', 'Deprecated from 6.1(1)+'])
else:
unformatted_data.append([str(tversion), eqptSupC['eqptSupC']['attributes']['dn'], model, 'Supervisor', 'Deprecated from 6.1(1)+'])

if not data and not unformatted_data:
result = PASS
return Result(result=result, headers=headers, data=data, recommended_action=recommended_action, doc_url=doc_url)
return Result(
result=result,
headers=headers,
data=data,
unformatted_headers=unformatted_headers,
unformatted_data=unformatted_data,
recommended_action=recommended_action,
doc_url=doc_url,
)


@check_wrapper(check_title="Contract Port 22 Defect")
Expand Down Expand Up @@ -6417,7 +6473,7 @@ class CheckManager:
api_checks = [
# General Checks
target_version_compatibility_check,
gen1_switch_compatibility_check,
supported_hardware_check,
r_leaf_compatibility_check,
cimc_compatibilty_check,
apic_cluster_health_check,
Expand Down
17 changes: 15 additions & 2 deletions docs/docs/validations.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@ Items | This Script
[Fabric Link Redundancy][g17] | :white_check_mark: | :no_entry_sign:
[APIC Database Size][g18] | :white_check_mark: | :no_entry_sign:
[APIC downgrade compatibility when crossing 6.2 release][g19]| :white_check_mark: | :no_entry_sign:
[Svccore Excessive Data Check][g20] | :white_check_mark: | :no_entry_sign:
[Supported Hardware Compatibility][g20] | :white_check_mark: | :no_entry_sign:
[Svccore Excessive Data Check][g21] | :white_check_mark: | :no_entry_sign:

[g1]: #compatibility-target-aci-version
[g2]: #compatibility-cimc-version
Expand All @@ -58,7 +59,8 @@ Items | This Script
[g17]: #fabric-link-redundancy
[g18]: #apic-database-size
[g19]: #apic-downgrade-compatibility-when-crossing-62-release
[g20]: #svccore-excessive-data-check
[g20]: #supported-hardware-compatibility
[g21]: #svccore-excessive-data-check

### Fault Checks
Items | Faults | This Script | APIC built-in
Expand Down Expand Up @@ -267,6 +269,17 @@ The script checks the presence of generation one switches when the upgrade is cr
Or you can check the [Release Note 15.0(1) of ACI switches][3] to see the list of generation one switches, typically the one without any suffix such as N9K-C9372PX, that are no longer supported from 15.0(1) release.


### Supported Hardware Compatibility

The script checks the presence of deprecated hardware in the fabric.

The list of supported and unsupported hardware is populated from the Release Notes across all ACI releases. This means the check covers hardware compatibility changes introduced in any version, not just the most recent release. As new release notes are published and hardware is deprecated, this list is updated accordingly.

Refer the [Release Note 15.0(1) of ACI switches][3] to see the list of unsuporrted hardware for your desired target versions. Prior upgrading to target version, replace the unsupported hardware elements in your fabric with other supported hardware.

Contact cisco TAC for further assistance.


Comment thread
dhaselva marked this conversation as resolved.
### Compatibility (Remote Leaf Switch)

The script checks the requirement to use remote leaf switches on the target version.
Expand Down

This file was deleted.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
[
{
"eqptExtCh": {
"attributes": {
"dn": "topology/pod-1/node-101/sys/ch/supslot-1/extch-101",
"model": "N2K-C2348UPQ"
}
}
}
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
[
{
"eqptExtCh": {
"attributes": {
"dn": "topology/pod-1/node-101/sys/ch/supslot-1/extch-101",
"model": "N2K-C2232PP-10GE"
}
}
},
{
"eqptExtCh": {
"attributes": {
"dn": "topology/pod-1/node-101/sys/ch/supslot-1/extch-102",
"model": "N2K-C2348UPQ"
}
}
}
]
10 changes: 10 additions & 0 deletions tests/checks/supported_hardware_check/eqptLC_supported_only.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
[
{
"eqptLC": {
"attributes": {
"dn": "topology/pod-1/node-1001/sys/ch/lcslot-1/lc",
"model": "N9K-X9732C-EX"
}
}
}
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
[
{
"eqptLC": {
"attributes": {
"dn": "sys/ch/lcslot-1/lc",
"model": "N9K-M6PQ"
}
}
}
]
18 changes: 18 additions & 0 deletions tests/checks/supported_hardware_check/eqptLC_with_unsupported.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
[
{
"eqptLC": {
"attributes": {
"dn": "topology/pod-1/node-1001/sys/ch/lcslot-1/lc",
"model": "N9K-M6PQ"
}
}
},
{
"eqptLC": {
"attributes": {
"dn": "topology/pod-1/node-1001/sys/ch/lcslot-2/lc",
"model": "N9K-X9732C-EX"
}
}
}
]
10 changes: 10 additions & 0 deletions tests/checks/supported_hardware_check/eqptSupC_supported_only.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
[
{
"eqptSupC": {
"attributes": {
"dn": "topology/pod-1/node-1001/sys/ch/supslot-1/sup",
"model": "N9K-SUP-C"
}
}
}
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
[
{
"eqptSupC": {
"attributes": {
"dn": "topology/pod-1/node-1001/sys/ch/supslot-1/sup",
"model": "N9K-SUP-B"
}
}
},
{
"eqptSupC": {
"attributes": {
"dn": "topology/pod-1/node-1001/sys/ch/supslot-2/sup",
"model": "N9K-SUP-C"
}
}
}
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
[
{
"fabricNode": {
"attributes": {
"id": "101",
"model": "N9K-C93180YC-FX",
"role": "leaf"
}
}
},
{
"fabricNode": {
"attributes": {
"id": "1001",
"model": "N9K-C9504",
"role": "spine"
}
}
}
]
Loading
Loading