Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Multiple Instances on single database

Shah Baloch
Contributor
December 14, 2020

We installed two Jira Instances on a single database. Both instances are installed on two different servers. We would like to have instance one as primary and second as secondary instances. I'm using rsync command to copy data from one server to the other like the attachments etc. by the way I'm running rsync only instance 1. 

I was expecting that issues show up in both instances since both are using the same database, however, that's not the case. if I create an issue from instance 2 it won't display in instance 1's issue tab from the project. If I enter the issue key in the search bar, I can view it but it's not in the issue tab. I have to reboot instance one to make it available in instance one.

Instance 2 is not showing up any issue that I created from instance one, even if I reboot the instance. I can search the issue by tying the issue key in the search bar but never display it in the project issue tab.

I don't have an idea of what I'm doing wrong. Appreciate your help. Thanks

 

2 answers

1 accepted

2 votes
Answer accepted
Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
December 14, 2020

I needed to get that out fast, to minimise the damage you're doing, rather than explain it.

Jira cannot be used like this.  A Jira server install needs to be run with one single database that no other Jira is trying to use.  Two Jira server installations cannot and must not share a database.

Somehow, you seem to have bypassed the sanity check Jira does on the database to make sure it is not locked by an existing Jira system - you need to remove that next, the process is there for a very good reason.  (Unless you're on a really old version of Jira that does not do the check!).

To answer "what I am doing wrong" - connecting two Jiras to one database.

Why are you doing this?

Shah Baloch
Contributor
December 15, 2020

Thank you for your response.

The reason I'm doing this, because of system failure. I mean we have a backup location, if there will be any system, internet, or power failure then the back location will be used. I don't want the end-user to see any failure. If one system goes down then the second one is up. 

You're saying two Jira won't work with a single database? or you mean it won't work at the same time? Do I have to shut down one? if only one work at a time that's fine, I just want to have data in both, if the first goes down and I shut it down and up the second one. If I restore the database do you think keeping up one is going to work?

Andrew Laden
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
December 15, 2020

So you want DataCenter, without buying DataCenter? Given that server is going away, might as well just get DataCenter,

If your backup copy comes up with the same hostname as the original, it would probably work. Same IP would be better.

We use Veeam to replicate our instance (and the database for that matter) to our backup site, and it works fine but that is because the exact same machine comes up in the new location.

Like Tom Lister likes this
Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
December 15, 2020

>You're saying two Jira won't work with a single database? or you mean it won't work at the same time?

That's an "and", not an "or".  You must not connect a second Jira to a database that is in use by another.  You will destroy your data if you do that.

You can safely have a backup install that can pick up if the main one fails - to swap application servers while keeping the same data, stop the service on server 1, start the service on server 2, and kick off a full locking re-index to get the local index updated.  Repeat that process when you want to swap server 1 back in as the main server.

But never run a second Jira pointed to a database that is in active use by an existing Jira.

1 vote
Nic Brough -Adaptavist-
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
December 14, 2020

Argh, no!

You need to shut down one of these Jira's instantly, and prepare to restore from the last good backup (you might be ok, but there's a good chance that you've corrupted your database so badly, you need to start over from before you did this)

Suggest an answer

Log in or Sign up to answer