Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RAID Status check #59

Open
genesyswave opened this issue Jun 5, 2023 · 6 comments
Open

RAID Status check #59

genesyswave opened this issue Jun 5, 2023 · 6 comments
Labels
codebase Code related issues enhancement New feature or request

Comments

@genesyswave
Copy link

Feature Request
Adding a status check for RAID status on a device. Panorama and certain physical firewalls will do RAID rebuilds after an upgrade and this can cause delays in the autocommit after the upgrade
https://knowledgebase.paloaltonetworks.com/KCSArticleDetail?id=kA14u000000wkxPCAQ
Warnings:
Details: configured traffic quota of 0 MB is less than the minimum 32 MB.
Invalid configuration. Please fix errors and try again.
Failed to commit policy to device

Checking and reporting on the status of the system RAID before and after an upgrade provides both visibility when the RAID rebuild is in progress and the option for a delay in checking the readiness of a firewall.

CLI check is 'show system raid detail'

@genesyswave genesyswave added the enhancement New feature or request label Jun 5, 2023
@welcome-to-palo-alto-networks
Copy link

🎉 Thanks for opening your first issue here! Welcome to the community!

@FoSix
Copy link
Contributor

FoSix commented Jun 7, 2023

Thanks @genesyswave, we'll look into that.

@FoSix FoSix added the codebase Code related issues label Jun 12, 2023
@FoSix FoSix self-assigned this Jun 21, 2023
@FoSix
Copy link
Contributor

FoSix commented Jun 27, 2023

I'm thinking should we implement this at all. Couple of reasons:

  • this wouldn't be a generic test
    • applicable only to two types of physical devices (5200 and 7000)
    • applicable only for PanOS 10.1.4 and higher
    • implementation would require some hardcoding, which we try to avoid as much as possible
  • implementation would be problematic, according to this note we don't have to wait until the rebuild is done, we could return True earlier, but that could give false positives.

But the main argument would be, that the package should be generic. All corner cases (like this one) can be handled through pan-os-python (in case of python scripts) or PanOS Ansible collection (for Ansible playbooks).

@horiagunica , @alperenkose , @adambaumeister - your thoughts?

@adambaumeister
Copy link
Collaborator

I think it's worth writing a readiness test to ensure that the system isn't currently in the process of rebuilding the spare - or the RAID at all. There might be edge cases where you do an upgrade to 10.1.4 then immediately want to upgrade to 10.2 (for example) and having a readiness check in place would raise the issue and stop the process. It might be ok to upgrade while the spare is rebuilding but you wouldn't want to attempt an upgrade when the RAID is in another degraded state, so a check that just makes sure the state is not abornmal would be good enough.

@FoSix
Copy link
Contributor

FoSix commented Jul 17, 2023

fair enough, but should this be a test included in the test suit? meaning when you run all tests, should we run it as well? Or should we implement this as a helper test? Reason I'm asking is that it would be limited just to some devices and versions.

If we include it as a regular test, how to report a result if the device/versions is not applicable to run it?

  • As SUCCESS? We didn't run anything, so no success here ;)
  • As SKIPPED? but this translates to false
  • hardcode the PanOS version and device type and skip the test if no match? I do not like the idea of hardcoding anything TBH

@adambaumeister
Copy link
Collaborator

No hardcoding. I think "is the RAID rebuilding?" returning passing if there's no RAID because of the version/model is fine, which would make it suitable to run in the test suite (suite-able?). You shouldn't need to code the check based on the model and version, just run the show system raid detail command and if there's no RAID, the test passes.

@FoSix FoSix removed their assignment Nov 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
codebase Code related issues enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants