[ALF-2545] Cannot upgrade from 2.1.2a (b 209) to the 3.1.2 (.a3 458) on Oracle Created: 22-Apr-10  Updated: 03-Jun-10  Resolved: 18-May-10

Status: Closed
Project: Alfresco
Component/s: Installer
Affects Version/s: 3.1 A Community
Fix Version/s: 3.1 A Community
Security Level: external (External user)

Type: Bug Priority: Blocker
Reporter: Alfresco QA Team (Inactive) Assignee: Closed Bugs (Inactive)
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: File AlfrescoSchemaUpdate-2.1-A--to--2.2-ACL.sql     File AlfrescoSchemaUpdate-2.2-ACL.sql     Text File SystemOut-28April2010.log     File alf-2545-logs.rar.rar     Text File alfresco.log     Text File upgrade-2.1.4.a.222-to-3.2.1.2.3_CLEAN_oracle10.log     Text File upgrade-2.1.4.a.222-to-3.2.1.2.3_CLEAN_oracle11.log     Text File upgrade-2.1.4a.222-to-3.1.2.6.16_oracle10.log     Text File upgrade-2.1.4a.222-to-3.1.2.6.16_oracle10_CLEAN.log     Text File upgrade-2.1.4a.222-to-3.1.2.6.16_oracle11_CLEAN.log     Zip Archive upgrade-2.1.4a.222-to-3.1.2.a4.462.zip     File upgrade-from-2.1.sql    
Issue Links:
Cloners
is cloned by MNT-3676 CLONE - Cannot upgrade from 2.1.2a (b... Closed
Dependency
Depended on by MNT-1705 Oracle upgrade scripts need enhanceme... Closed
Related
relates to MNT-8296 3.1.2.a4 retests Closed
relates to MNT-8369 3.1.2.a3 retests Closed
Resource:
External
Escalation level: Service Pack
Date of First Response:

 Description   

ALF-2351 has a requirement to test the following upgrade on oracle:
2.1a -> 3.1 latest (high priority)
But it fails on the clean db with the following error:
java.sql.SQLException: ORA-02431: cannot disable constraint (FK_ATTRIBUTES_N_ACL) - no such constraint
Please, see full log attached (upgrade only).

AntonRy



 Comments   
Comment by Alfresco QA Team (Inactive) [ 22-Apr-10 ]

Note, that upgrade from 2.1.2a (b 209) to the 3.2.1 (b 495) succeeds.

Comment by Ashutosh Dandavate (Inactive) [ 23-Apr-10 ]

dobe is testing this upgrade from 2.1.a to 3.1.2.a3. and reported following error,

While applying the patch, we are facing this

[4/22/10 11:41:22:563 IST] 0000001a SchemaBootstr E org.alfresco.util.LogUtil error Statement execution failed:
SQL: alter table "ALF_ATTRIBUTES" disable constraint "FK_ATTRIBUTES_N_ACL"
Error: ORA-02431: cannot disable constraint (FK_ATTRIBUTES_N_ACL) - no such constraint

File: C:\Users\ADMINI~1\AppData\Local\Temp\1\Alfresco\AlfrescoSchema-AlfrescoOracle9Dialect-Update-2773935969724598448.sql
Line: 38
[4/22/10 11:41:22:563 IST] 0000001a SchemaBootstr E org.alfresco.util.LogUtil error Schema auto-update failed
java.sql.SQLException: ORA-02431: cannot disable constraint (FK_ATTRIBUTES_N_ACL) - no such constraint

======= Adobe made above contraints optional and tetsed further, following error was reported after that,

FK_ATTR_N_ACL is the constraint. Your script mentions that as FK_ATTRIBUTES_N_ACL. In addition we got one more error

[4/22/10 16:40:14:580 IST] 0000001b SchemaBootstr E org.alfresco.util.LogUtil error Statement execution failed:
SQL: INSERT INTO alf_access_control_entry SELECT * FROM NSI_ACE_TEMP
Error: ORA-01438: value larger than specified precision allowed for this column

File: C:\Users\ADMINI~1\AppData\Local\Temp\1\Alfresco\AlfrescoSchema-AlfrescoOracle9Dialect-Update-6103548449230263441.sql
Line: 208
[4/22/10 16:40:14:580 IST] 0000001b SchemaBootstr E org.alfresco.util.LogUtil error Schema auto-update failed
java.sql.SQLDataException: ORA-01438: value larger than specified precision allowed for this column

at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:79)
at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:112)

Comment by Derek Hulley [X] (Inactive) [ 26-Apr-10 ]

r19983 | derekh | 2010-04-26 11:52:42 +0100 (Mon, 26 Apr 2010) | 7 lines

Changes for ALF-2545: Cannot upgrade from 2.1.2a (b 209) to the 3.1.2 (.a3 458) on Oracle

  • Examined client-supplied scripts, which made some fixes but also reversed the upgrade-from-2.1.sql
  • Took changes for the ACL scripts
  • Alternate constraint enable/disable with appropriate optionals
  • CAST function for temp table
  • Column ordering for 'alf_access_control_entry'

This should be the QA-raised "value larger than specified precision allowed for this column" and constraint naming issues.

Comment by Alfresco QA Team (Inactive) [ 27-Apr-10 ]

Issue appears during upgrade from 2.1a (builds 209/220/222) to 3.2.1.499 although doesn't appear during upgrade to 3.2.1.495.

Comment by Paul Holmes-Higgin [X] (Inactive) [ 30-Apr-10 ]

We need to validate whether the upgrade was successful. The null pointer on restart is most likely to be due to a problem in overridden code (e.g. overridden bean missing some injection). To check that a schema and data upgrade was successful, starting a standard Alfresco WAR against the data will indicate whether the null pointer issue is schema+data upgrade related.

Comment by Alfresco QA Team (Inactive) [ 13-May-10 ]

Still reproducible with 3.2 SP1 HF2 during upgrade from 2.1.4a (b 222) to the 3.2.1 (.2 3) both on Oracle 10g and 11g.
(upgrade logs attached)

Comment by Alfresco QA Team (Inactive) [ 14-May-10 ]

Issue was actually submitted during testing upgrade to 3.1.2.a3.458 - the last 3.1.2.ax build available currently on FTP: ftp://ftp.alfresco.com/qa/Enterprise%203.1/.
As well issue is still actual for this branch.

Will be tested against 3.1.2.6 (build 16) in scope of ALF-2806 testing.

Comment by Alfresco QA Team (Inactive) [ 17-May-10 ]

Successfully validated for 3.1 SP2 HF6 (build 16) upgraded from 2.1.4a (b 222) both on Oracle 10g and 11g, with clean db and with generated template data.
(upgrade logs attached)

But still reproducible with 3.2 SP1 HF2 during upgrade from 2.1.4a (b 222) to the 3.2.1 (.2 3) both on Oracle 10g and 11g.

Comment by Alfresco QA Team (Inactive) [ 27-May-10 ]

Not reproducible during upgrade 2.1.4a (b 222) -> 3.3.0 (b 64) on Oracle 10g (both clean installation and upgrade data template).

Comment by Alfresco QA Team (Inactive) [ 01-Jun-10 ]

Successfully validated for 3.1.2.a4 (build 462) upgraded from 2.1.4a (b 222) both on Oracle 10g and 11g, both with clean db and generated template data.
(upgrade logs attached)

Generated at Tue Jan 26 05:42:34 GMT 2021 using Jira 7.13.15#713015-sha1:7c5ddd2c3e1709974ae9c48c17df8edd3919fe2c.