diff options
author | Jacob Vosmaer <contact@jacobvosmaer.nl> | 2014-05-19 18:28:45 +0200 |
---|---|---|
committer | Jacob Vosmaer <contact@jacobvosmaer.nl> | 2014-05-19 18:28:45 +0200 |
commit | 8ee3299cc451898b7072383dab7d54601b8bd479 (patch) | |
tree | a61b92b095c1ea179339088d8719d70f9a1503ca /doc/update/mysql_to_postgresql.md | |
parent | f08cb264878b4051b07f773586994290117296a5 (diff) | |
download | gitlab-ce-8ee3299cc451898b7072383dab7d54601b8bd479.tar.gz |
Import the database as the `git` user
This ensures that all tables created during the import belong to `git`.
If you import as a different user, such as the `postgres` superuser, you
may encounter issues where the GitLab database user cannot access tables
in gitlabhq_production, _even if_ `git` is the owner of
gitlabhq_production at the time of import.
Diffstat (limited to 'doc/update/mysql_to_postgresql.md')
-rw-r--r-- | doc/update/mysql_to_postgresql.md | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/doc/update/mysql_to_postgresql.md b/doc/update/mysql_to_postgresql.md index 5b9209d7df4..ac66be31073 100644 --- a/doc/update/mysql_to_postgresql.md +++ b/doc/update/mysql_to_postgresql.md @@ -19,7 +19,9 @@ git clone https://github.com/lanyrd/mysql-postgresql-converter.git cd mysql-postgresql-converter mysqldump --compatible=postgresql --default-character-set=utf8 -r databasename.mysql -u root gitlabhq_production python db_converter.py databasename.mysql databasename.psql -psql -f databasename.psql -d gitlabhq_production + +# Import the database dump as the application database user +sudo -u git psql -f databasename.psql -d gitlabhq_production sudo service gitlab start ``` |