Application links not working on different servers for JIRA and Confluence
Asked by Hassan Akhtar:

We had the jira and confluence servers running before (both within the same server and using https scheme). Since the instances were old, so we considered upgrading, but using a different server to host the JIRA instance. Confluence was using the JIRA userbase and so the authentication was done using JIRA.

Now I am unable to login in to Confluence anymore (not even admin account). One of the user was using *Remember me*check and so he can still use confluence but no one else.

Please help us out with the issue, on how to add authentication. I read and tried different forums, but nothing applied.


Answers:
author: Hassan Akhtar
body: I ended up by creating local accounts on confluence with the same usernames and so the users can see their personal spaces and feels like they're using the old accounts. The only thing that differs was the password, I set the generic password 'admin' whose hash was already available on documentation and then every user resets the password to whatever they wished.

Its pity that there was no other cleaner way to do that.


author: AnnWorley
body: Hi Hassan,

It sounds like the Confluence User Directory connected to Jira cannot reach the Jira server for User Management. If you changed the Jira URL, the application links will also be broken, but the application links do not control logging into Confluence.

You may recover access to your Confluence instance by using recovery mode if you are using Confluence 6.5.1 or above. Otherwise you will need to directly modify the database. For instructions on logging in with a user from the internal directory, please see: [Restore Passwords To Recover Admin User Rights](https://confluence.atlassian.com/doc/restore-passwords-to-recover-admin-user-rights-158390.html) You will need to choose your Confluence version from the pulldown as shown in the screen shot:

![Screen Shot 2018-03-19 at 9.15.16 AM.png](https://community.atlassian.com/t5/image/serverpage/image-id/17378i3B946AA0D186CF5B/image-dimensions/740x312?v=v2 "Screen Shot 2018-03-19 at 9.15.16 AM.png")

After logging in as an admin from the internal directory, please go to the Confluence Admin console and edit the Jira User Directory to reflect the Jira URL change. Please see [Jira Settings in Confluence](https://confluence.atlassian.com/doc/connecting-to-crowd-or-jira-for-user-management-229838465.html#ConnectingtoCrowdorJiraforUserManagement-JiraSettingsinConfluence) for details on these settings.

You may also need to recreate or edit your [application links](https://confluence.atlassian.com/doc/linking-to-another-application-360677690.html) at Confluence Admin\>Application Links.

Thanks,

Ann

comments: author: Hassan Akhtar
body: Since I mentioned earlier, the confluence (5.7) and JIRA(4.x) were quite old. Right now, JIRA = 7.6.2 and same confluence (5.7).. And so the confluence version is not listed. Above that, I don't want to play with the database stuff (unless it is the only option).

JIRA and confluence URLs are not changed, they're as before (jira.domain.com and confluence.domain.com). But the server machines (and so IPs) are changed.. I personally feel that I have to somehow grant the private/public key access between the machines (or somehow a way to communicate) since the confluence logs show the exception with HTTP 403. I was trying to search in this direction but didn't found anything helpful.


author: AnnWorley
body: Hi Hassan,

Here is the document to restore the admin in Confluence 5.7: [Restoring Passwords To Recover Admin User Rights](https://confluence.atlassian.com/display/CONF57/Restoring+Passwords+To+Recover+Admin+User+Rights)

Please check the causes listed on this doc for possible reasons you cannot connect to Jira for User Management: [Unable to connect to JIRA for authentication - Forbidden 403](https://confluence.atlassian.com/confkb/unable-to-connect-to-jira-for-authentication-forbidden-403-728139630.html)

If you think SSL is the issue, please see [Unable to Connect to SSL Services due to PKIX Path Building Failed](https://confluence.atlassian.com/kb/unable-to-connect-to-ssl-services-due-to-pkix-path-building-failed-779355358.html)

Thanks,

Ann


author: Hassan Akhtar
body: Thanks for quick response. But this didn't helped.

Hint: If I write the confluence URL on whitelist of jira administrator. It shows green tick on Incoming and outgoing. Does it mean there is nothing wrong with networking?

Secondly, Can it be something related to adding application within *JIRA user server*? There is already an entry there with an IP address 192.168.x.x Someone else configured that before. Should I tried to add an IP 148.x.x.x to a new line within this. but that didn't helped either.


author: AnnWorley
body: Hi Hassan,

[Configuring the whitelist](https://confluence.atlassian.com/adminjiraserver073/configuring-the-whitelist-861254007.html) indicates that the test you are describing means connectivity is ok.

After logging in with an internal admin, please edit the Jira User Directory in Confluence and try the test at the bottom of the page. The UI should then show a helpful error message.

If the existing User Directory still won't work, you may log into Confluence via Jira again by creating a new Jira User Directory, using the application you configured in Jira User Server, by following [Connecting to Crowd or Jira for User Management](https://confluence.atlassian.com/doc/connecting-to-crowd-or-jira-for-user-management-229838465.html). After you make sure everyone can log in with the new User Directory you may disable and remove the old one.

Thanks,

Ann


author: Hassan Akhtar
body: Sorry to write after a long time. I have recovered the admin account on confluence instance, now the problem is that I can't link JIRA and confluence both. If I add application link on jira (for confluence) selecting the option that I have same usernames on both instances but unchecking the option that I am admin on both, it adds the application link on jira and gives me a url to run as admin on confluence, if I do that I got an error. And on the other way round, if I create application link on confluence (for jira) selecting the same options as mentioned above, it simply throws the error (see screenshot) but on refreshing the page, I can see the application link but I think that is of no use.![Screenshot from 2018-04-18 14-36-20.png](https://community.atlassian.com/t5/image/serverpage/image-id/19998iD2C576E7A6503F45/image-size/large?v=v2&px=999 "Screenshot from 2018-04-18 14-36-20.png")


Tags: application-link

jira-software