Cannot delete existing Trusted Applications after upgrade

Runing confluence 3.5.16

I am trying to remove existing trusted applications after upgrading from 2.10.x. Receive this message Failed to delete orphaned trust certificate: Incorrect result size: expected 1, actual 2

I followed the knowledgebase https://confluence.atlassian.com/pages/viewpage.action?pageId=158107208.

Ran the command on the database SELECT * FROM KEYSTORE;

Received the output.

123011073 jira:4494498 public RSA
124551169 jira:4494498 public RSA
151846913 confluence:1995330 public RSA
151846914 confluence:1995330 private RSA
I can remove the confluence records but cannot remove the jira records
I tried delete command on the database DELETE FROM keystore WHERE alias LIKE '%jira%'

But received this error message

Error starting at line 4 in command:
DELETE FROM keystore WHERE alias LIKE '%jira%'
Error report:
SQL Error: ORA-02292: integrity constraint (CONFL_OWNER.FKDDB119CA9C85ADB1) violated - child record found
02292. 00000 - "integrity constraint (%s.%s) violated - child record found"
*Cause: attempted to delete a parent key value that had a foreign
dependency.
*Action: delete dependencies first then parent or disable constraint.

Does anybody have a solution removing the existing trutsted application.

I need to removed them as they conflicting when I am trying to created new trusted relationship with jira.

If anybody could provide any assistance would be greatly appreicated

Thanks

Regards

Jaime


2 answers

1 accepted

5 votes
Accepted answer

Shutdown Confluence

1. First, back up the database, just in case

2. Then run these commands against the database in this order:

3.  delete from trustedapprestriction;
4.  delete from trustedapp;
delete from keystore where alias like 'jira%';
 
Hopefully you can now make a trusted application with Jira

Hi Jaime,

I'm not keen on Oracle, but the error is pretty clear, you need to find out the parent record that is preventing you from completing the delete statement. Also, if you're confident enough on database manipulation, you might as well drop the constraint that is being reported in the stack trace ((CONFL_OWNER.FKDDB119CA9C85ADB1), I found some instructions here: http://www.java2s.com/Code/Oracle/Constraints/Drop-Constraint.htm

Just bear in mind to create a database backup prior to any changes.

Hope it helps.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Oct 24, 2018 in Confluence

Atlassian Research opportunity with Confluence templates

Do you use templates with Confluence? Take part in a remote 1-hr workshop. You'll receive USD $100 for your time!   We're looking for people to participate in a   remote 1-hr workshop...

1,177 views 20 14
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you