Firewall snapshot after upgrade not generated
Closed this issue · 4 comments
Describe the bug
Firewall snapshot after upgrade not generated, and therefore the reports are not generated either (standalone firewall). The script returns after "LabFW1: Waiting for the device to become ready for the post upgrade snapshot.". This happens when using settings.yaml file.
I assume that the issue lies in code "upgrade.py" line 716 ->
# Load settings if the file exists
if settings_file_path.exists():
This seems to check if the settings file exists and whether snapshots are enabled or not. In this case when snapshots are enabled it skips the snapshots due to the snapshot and reporting part being included in the else statement (which is never reached due to constuction of the if/else statement).
To Reproduce
Steps to reproduce the behavior:
- Generate settings.yaml file
- Run the script (using: "pan-os-upgrade firewall")
- Post-upgrade snapshot not generated
Expected behavior
Post upgrade snapshots and reports to be generated.
Log output
LabFW1: Upgrade completed successfully
LabFW1: Rebooting the target device.
LabFW1: Retry attempt 1 due to error: URLError: reason: [Errno 110] Connection timed out
LabFW1: Retry attempt 2 due to error: URLError: reason: [Errno 111] Connection refused
LabFW1: Current device version: 11.0.1-h2
LabFW1: Device rebooted to the target version successfully.
LabFW1: Performing backup of configuration to local filesystem.
LabFW1: Waiting for the device to become ready for the post upgrade snapshot.
Script exits here.
Environment
- Ubuntu 20.04
- Python 3.11
Yes, I'm running the latest:
pan-os-upgrade 1.3.3
You are correct, this issue wasn't solved by the previously mentioned Issue, it was in fact created by it. Thanks for the report, I'll work on getting a hotfix out
the fix is in 1.3.4
, currently working on a new pytest to catch the issue in the future and will keep the branch open until it's finished.
Thanks again for reporting this!