8

I need to know how to migrate my Drupal 6 database from MySQL to PostgreSQL. I also like to hear first hand experience tales about actual migrations.

P.S. I found this drupal-mysql2pgsql.pl migration script which apparently does the job but I could not make use of it due to the fact that I dont' know how to make " passwordless account in both databases". There is also this guide (in Thai) which adds credentials to database connection lines in the script. But it did not help either, as I could not connect to Postgresql. I know very little about Postgresql and may have had some silly mistake. Any through explanation/tutorial on this would be much appreciated.

5

Module DBTNG Migrator will do it.

  • 2
    The module is for Drupal 7. – kiamlaluno Aug 19 '11 at 12:12
3

If you're using Drupal 7, there's a sandbox project called Portable Databse Dump that purports to allow you to dump a Drupal site from one database backend to another.

  • Unfortunately I'm using Drupal 6. – alfish Jun 15 '11 at 18:47
3

I have an experience with both postgres and mysql sites under high load, and I don't think migration can be done for performance reasons. Both engines are good, and final success depends on ability of your DB admins to tune up DB installation for specific site. Another point: to boost performance, you choose tools to minimize need in DB queries (boost/memcache/varnish), so you end up with relatively low weight of DB processing.

1

Check all of the modules that you use or ever may want to use on your site. Not all contrib modules are database agnostic. I can't think of any off the top of my head, but I have run into modules that use MySQL-only functions.

  • Do you think the effort to migrate to Postgresql worth at all? – alfish Jun 15 '11 at 18:48
  • I don't consider the risk of a module not working with PostgreSQL worth taking when working on projects for a client. – mpdonadio Jun 15 '11 at 20:00
  • Assuming that all modules work in Postgresql, will you suggest the migration, performance-wise? – alfish Jun 15 '11 at 20:45
  • Because of this complication, we don't deploy it, so I don't have real-world metrics to compare to. – mpdonadio Jun 16 '11 at 13:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.