Can multiple instances of TeamCity share an external database?

I'm managing several teamCity instances that are not backed by an external database.  I was wondering if I could provision a single sql*server database that can be utilised by all TeamCity instances.   Granted, recovery at a database level would impact all TeamCity instances.  However, the expectation of database failure is very low and there is no requirement to recover a specific TeamCity instance's data.  Many thanks in advance.

7 comments
Comment actions Permalink

Hi Cameron

I have a similar setup, we have a "production" TeamCity server which run TC3.1 backed by a mysql instance.
I'm testing the brand new TC4.5 which runs on my machine and it point to the same mysql instance but on a different database. That's just a command to run on the database server :
"CREATE DATABASE TeamCity4x DEFAULT CHARACTER SET utf8"



Gilles

0
Comment actions Permalink

thanks Gilles,  so you have one instance, two separate databases and so you have isolation, separation at the database level.  Could two teamcity instances utilise the same database and therefore share tables?

0
Comment actions Permalink

I never tried this, and honestly I don't see the value added to do this. If you feel the need to separate the Integration servers, the same thing should apply to the databases...
Why would you need to share a single database ?
So at this point only TeamCity developer could answer this question

Gilles

0
Comment actions Permalink

Gilles, your right & make a good point    Unfortunately, I've yet to get 'buy-in' to consolidating our build servers to utilise a single instance of TeamCity backed up by a single database.  I wondered if we could create a single database to support x TeamCity instances then over time reduce x to 1.  Creating x databases from the outset that are only going to exist in the short/medium term seems like overkill.  I prefer your approach and agree separation at the database or even schema level is better.

0
Comment actions Permalink

Hello Cameron,

  A single database cannot be shared between several TeamCity instances.

  Regards,
  KIR

0
Comment actions Permalink

ok, thks for answer to this KIR.

0
Comment actions Permalink

Of course that doesn't mean you have to install two different instances of a database server. Just create a TeamCity1 and TeamCity2 database in MySQL or Oracle or what ever database server your using.

-Rob

0

Please sign in to leave a comment.