Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

mysqldump

Razeen Brown May 25, 2016

Good day

 

I have a mysqldump file created from a Confluence 5.1.73 database which I want to import into a running confluence 5.1.5.

Is this possible?  If so how would I go about doing that?

 

Regards

Rijk obo Razeen Brown

1 answer

0 votes
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 25, 2016

There's a lot wrong with that...

  • A mysqldump is a block of text you can use for recreating a database.  It's in no fit state to be merged with any other database, it's for creating copies of a database.  It'll trash the database it's restored into
  • You should never never never write to a running Confluence with SQL
  • Generally, you should never write to Confluence with SQL at all
  • The data for 5.1.7 may not even be backward compatible to 5.1.5 (it probably is, as they're both 5.1, but don't bet on it)

What you should do is restore the database, point a clean 5.1.7 at it, export the space(s) you need to xml and then import them in your 5.1.5 separately.

Razeen Brown May 25, 2016

Thanks for the answer.. I was afraid that was the case sad

A database restore is out of the question though, so I am a little stuck.  Any pointers and/or hacks just to get the data to a point where I can copy-and-paste or export would be appreciated though.

Could I create a clean DB from that SQL and then just reconfigure a Confluence 5.1.x to use it?  In theory I could then XML export the content I want and import it into my new Confluence.

Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 25, 2016

That's what a mysqldump file is for - recreating a database.

I'd install a clean Confluence 5.1 hooked up to an empty database to start with, just so that you know it works without data, and you don't have to manually deal with any config.  Then stop it, and edit the dbconfig.xml file in the confluence-home directory so that it points to the restored database, and restart it.  It would be a good idea to re-index it straight away.

IF it looks healthy at this point, that's a good time to get the xml out of it!

Razeen Brown May 26, 2016

Ok, update on my adventures in Confluence land.

Twiddled the mysql dump to use latin1 in stead of utf-8.

Imported that into a fresh MySQL database instance.

Pointed a new Confluence 5.9.7 at that (yes, I was wrong on the version number initially)

Started Confluence.

Did a backup with Confluence's own backup tools.

Restored that in a fresh Confluence 5.9.7.

So far so good smile

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events