06-02-2022 12:15 AM
Hi Folks,
How do you monitor disk usage in APIC using REST API? Found the below mentioned request, but I am not sure which values I need to monitor. Need to get the values general size, used size and free size of the disk space/RAID in APIC.
https://{{apic}}/api/class/eqptStorage.xml
Thanks,
Amal
Solved! Go to Solution.
06-02-2022 10:59 PM
What you are looking for is:
https://{{apic_ip}}/api/class/eqptFlash.json
You will get the a response like this:
{ "totalCount": "1", "imdata": [ { "eqptFlash": { "attributes": { "acc": "read-write", "cap": "122099", "childAction": "", "cimcVersion": "", "deltape": "0", "descr": "flash", "dn": "topology/pod-1/node-201/sys/ch/supslot-1/sup/flash", "gbb": "0", "id": "1", "lba": "0", "lifetime": "0", "majorAlarm": "no", "mfgTm": "2022-06-03T08:35:42.248+03:00", "minorAlarm": "no", "modTs": "2022-06-03T08:35:42.346+03:00", "model": "X", "monPolDn": "uni/fabric/monfab-default", "operSt": "ok", "peCycles": "0", "readErr": "0", "rev": "X", "ser": "X", "status": "", "tbw": "2.876587", "type": "flash", "vendor": "Intel", "warning": "no", "wlc": "100" } } } ] }
The important SSD monitoring parameters:
Parameter |
Description |
---|---|
P/E |
Overrides the SSD lifetime's default program erase cycles threshold. The possible values are between 3000 and 10000, inclusive. The default value is 5000. The value is in cycles. The Cisco Application Policy Infrastructure Controller (APIC) raises a minor fault when the drive reaches 80% of the specified value and raises a major fault when the drive reaches 90% of the specified value. |
GBB |
Overrides the SSD lifetime's default grown bad block threshold. The possible values are between 4 and 15, inclusive. The default value is 5. The value is in blocks. The APIC raises a minor fault when the drive reaches 80% of the specified value and raises a major fault when the drive reaches 90% of the specified value. |
RRE |
Overrides the SSD lifetime's default raw read errors threshold. The possible values are between 500 and 2000, inclusive. The default value is 1000. The value is in blocks. The APIC raises a minor fault when the drive reaches 80% of the specified value and raises a major fault when the drive reaches 90% of the specified value. |
Delta P/E |
Overrides the SSD lifetime's default delta of the program erase cycles threshold. The delta of the program erase cycles is equal to:
Possible values are between 21 to 40, inclusive. The default value is 21. The value is in cycles. If the P/E increases by equal to or greater than the specified value in the last 7 days, the APIC raises a warning to indicate excessive SSD writes. The window resets after 24 hours and delta P/E (as tracked by the APIC, not the parameter value) is set to 0. The warning is cleared after 24 hours. |
Ofc, you can also use the minor/major alarms: a minor fault is raised when the drive approaches 80% of its lifetime and a major fault is raised when it exceeds 90% of its lifetime.
Stay safe,
Sergiu
06-02-2022 10:59 PM
What you are looking for is:
https://{{apic_ip}}/api/class/eqptFlash.json
You will get the a response like this:
{ "totalCount": "1", "imdata": [ { "eqptFlash": { "attributes": { "acc": "read-write", "cap": "122099", "childAction": "", "cimcVersion": "", "deltape": "0", "descr": "flash", "dn": "topology/pod-1/node-201/sys/ch/supslot-1/sup/flash", "gbb": "0", "id": "1", "lba": "0", "lifetime": "0", "majorAlarm": "no", "mfgTm": "2022-06-03T08:35:42.248+03:00", "minorAlarm": "no", "modTs": "2022-06-03T08:35:42.346+03:00", "model": "X", "monPolDn": "uni/fabric/monfab-default", "operSt": "ok", "peCycles": "0", "readErr": "0", "rev": "X", "ser": "X", "status": "", "tbw": "2.876587", "type": "flash", "vendor": "Intel", "warning": "no", "wlc": "100" } } } ] }
The important SSD monitoring parameters:
Parameter |
Description |
---|---|
P/E |
Overrides the SSD lifetime's default program erase cycles threshold. The possible values are between 3000 and 10000, inclusive. The default value is 5000. The value is in cycles. The Cisco Application Policy Infrastructure Controller (APIC) raises a minor fault when the drive reaches 80% of the specified value and raises a major fault when the drive reaches 90% of the specified value. |
GBB |
Overrides the SSD lifetime's default grown bad block threshold. The possible values are between 4 and 15, inclusive. The default value is 5. The value is in blocks. The APIC raises a minor fault when the drive reaches 80% of the specified value and raises a major fault when the drive reaches 90% of the specified value. |
RRE |
Overrides the SSD lifetime's default raw read errors threshold. The possible values are between 500 and 2000, inclusive. The default value is 1000. The value is in blocks. The APIC raises a minor fault when the drive reaches 80% of the specified value and raises a major fault when the drive reaches 90% of the specified value. |
Delta P/E |
Overrides the SSD lifetime's default delta of the program erase cycles threshold. The delta of the program erase cycles is equal to:
Possible values are between 21 to 40, inclusive. The default value is 21. The value is in cycles. If the P/E increases by equal to or greater than the specified value in the last 7 days, the APIC raises a warning to indicate excessive SSD writes. The window resets after 24 hours and delta P/E (as tracked by the APIC, not the parameter value) is set to 0. The warning is cleared after 24 hours. |
Ofc, you can also use the minor/major alarms: a minor fault is raised when the drive approaches 80% of its lifetime and a major fault is raised when it exceeds 90% of its lifetime.
Stay safe,
Sergiu
06-07-2022 02:20 AM - edited 06-07-2022 04:29 AM
Hi Sergiu,
Thank you very much for your help. It works for Leaves and Spines. https://{{apic}}/api/class/eqptStorage.xml is for APIC. But too many values in the reply. I would like to know which values I should monitor regarding disk space in general, used and free disk space.
Take care and stay safe!
Regards,
Amal
Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: