Bug 2000726 - ZTP PolicyGen failed to create CRs during synchronization of 1 site
Summary: ZTP PolicyGen failed to create CRs during synchronization of 1 site
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Unknown
Version: 4.9
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
: 4.9.0
Assignee: Vitaly Grinberg
QA Contact: Jianwei Hou
URL:
Whiteboard:
Depends On:
Blocks: 2006035
TreeView+ depends on / blocked
 
Reported: 2021-09-02 18:44 UTC by Ian Miller
Modified: 2021-10-18 17:51 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-10-18 17:51:04 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Script used to generate the 100 CRs (2.35 KB, application/x-shellscript)
2021-09-02 18:44 UTC, Ian Miller
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Github openshift-kni cnf-features-deploy pull 681 0 None None None 2021-09-05 09:18:20 UTC
Red Hat Product Errata RHSA-2021:3759 0 None None None 2021-10-18 17:51:19 UTC

Description Ian Miller 2021-09-02 18:44:42 UTC
Created attachment 1820124 [details]
Script used to generate the 100 CRs

Description of problem:
When synchronizing 100 PolicyGenTemplate CRs from git to the hub cluster, the PolicyGen container failed to generate and apply the CRs.


Version-Release number of selected component (if applicable): 4.9


How reproducible: Unknown


Steps to Reproduce:
1. Create 100 PolicyGenTemplate CRs (one per file)
2. Upload generated CRs to ZTP monitored GIT repository
3. Monitor state of post-sync hook in ArgoCD application. Errored state with logs as below

Actual results:

Logs from the post-sync container:
# oc logs policygentemplates-post-v72s8 -n policies-sub
ztp-hooks.postsync Thu, 02 Sep 2021 18:32:53 +0000 INFO [post-sync-entrypoint] Retrieved RAN sites resourceVersion 80281453
ztp-hooks.watcher 2021-09-02 18:32:54 UTC [DEBUG]             [watcher:217]: 80281453, policygentemplates
ztp-hooks.watcher 2021-09-02 18:32:54 UTC [DEBUG]             [watcher:180]: {'type': 'ERROR', 'object': {'kind': 'Status', 'apiVersion': 'v1', 'metadata': {}, 'status': 'Failure', 'message': 'too old resource version: 80281453 (80288125)', 'reason': 'Expired', 'code': 410}}
ztp-hooks.watcher 2021-09-02 18:32:54 UTC [DEBUG]             [watcher:135]: Objects to delete are: []
ztp-hooks.watcher 2021-09-02 18:32:54 UTC [DEBUG]             [watcher:137]: Objects to create/update are: [None]
ztp-hooks.watcher 2021-09-02 18:32:54 UTC [ERROR]             [watcher:85]: PolicyGenWrapper failed: Manifest conversion failed: 2021/09/02 18:32:54 Not_supported_template  {Status}
Traceback (most recent call last):
  File "watcher.py", line 83, in __init__
    raise Exception(f"Manifest conversion failed: {output[1].decode()}")
Exception: Manifest conversion failed: 2021/09/02 18:32:54 Not_supported_template  {Status}



Expected results:
Generation and application to the hub cluster of the policy wrapped CRs.


Additional info:
Script used to generate the 100 CRs:
/gen_crs.sh hundred 100

Comment 4 Marius Cornea 2021-09-28 06:53:51 UTC
*** Bug 2006035 has been marked as a duplicate of this bug. ***

Comment 7 errata-xmlrpc 2021-10-18 17:51:04 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Moderate: OpenShift Container Platform 4.9.0 bug fix and security update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2021:3759


Note You need to log in before you can comment on or make changes to this bug.