Direct link to fix
APAR status
Closed as fixed if next.
Error description
The root cause occurred in import_heat.sh script included in ICO 2.5.0.2 media. File contains: update_sequence ${SCHEMA} RAW_TEMPLATE ID update_sequence ${SCHEMA} USER_CREDS ID update_sequence ${SCHEMA} RESOURCE ID but update_sequence ${SCHEMA} EVENT ID is missing. That is why the issue occurred only after data migration. What happened in my option: 1. Stack creation begins and openstack is trying to store first event in database with event.py: try: new_ev = event_object.Event.create(self.context, ev) 2. Exception occurs as sequence was not reseted after data migration and it ID conflicts with existing one. Error: "INSERT statement, UPDATE statement, or foreign key update caused by a DELETE statement are not valid because the primary key, unique constraint or unique index identified by "1" constrains table "HEAT.EVENT" from having duplicate values for the index key. SQLSTATE=23505 SQLCODE=-803 'INSERT INTO event...". I have noticed the error when I pass my own value to resource_properties in event.py Openstack does not care why event_object.Event.create fails. It just assume that resouce_properties was to large: except oslo_db.exception.DBError: # Attempt do drop the largest key and re-store as we expect # This to mostly happen with one large config blob property max_key, max_val = max(ev['resource_properties'].items(), key=lambda i: len(repr(i[1]))) err = 'Resource properties are too large to store' ev['resource_properties'].update({'Error': err}) ev['resource_properties'][max_key] = '<Deleted, too large>' try: new_ev = event_object.Event.create(self.context, ev) 3. Unfortunately first event is "Stack CREATE started" which has resource_properties empty, so openstack fails on: max_key, max_val = max(ev['resource_properties'].items(), key=lambda i: len(repr(i[1]))) with error: Create_Failed: max() arg is an empty sequence In my case issue solved command: db2 "alter table HEAT.EVENT alter column ID restart with 7503" where 7503 is next free ID. Should the import_heat.sh and event.py scripts be corrected as to better handle and communicate exceptions?
Local fix
no workaround
Problem summary
Issue will be fixed in 2.5 FP4
Problem conclusion
Temporary fix
Comments
APAR Information
APAR number
ZZ00593
Reported component name
SMRTCLOUD ORCHS
Reported component ID
5725H2800
Reported release
240
Status
CLOSED FIN
PE
NoPE
HIPER
NoHIPER
Special Attention
NoSpecatt / Xsystem
Submitted date
2016-08-10
Closed date
2017-04-03
Last modified date
2017-04-03
APAR is sysrouted FROM one or more of the following:
APAR is sysrouted TO one or more of the following:
Fix information
Applicable component levels
R250 PSY
UP
[{"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Product":{"code":"SS4KMC","label":"IBM SmartCloud Orchestrator"},"Component":"","ARM Category":[],"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"240","Edition":"","Line of Business":{"code":"LOB45","label":"Automation"}}]
Document Information
Modified date:
03 April 2017