Content
You are here:
Migrating from MySQL to Postgres: Unexpected EOF
Added by Tero Ollikainen over 5 years ago
Hi,
I'm following the guide for migrating from MySQL to Postgres database and I'm at the step where I have to set the database to point to the new Postgres, so I'm using these command from the guide:
openproject config:set MYSQL_DATABASE_URL="$(openproject config:get DATABASE_URL)"
openproject config:get MYSQL_DATABASE_URL
My console then outputs:
etc/openproject/conf.d/other: line 19: unexpected EOF while looking for matching "' etc/openproject/conf.d/other: line 19: unexpected EOF while looking for matching
"'
Any idea what could be causing this? I have followed the guide to the letter. Should I just go poking around the file to overcome this?
I'm running the commands as root, and I'm using Ubuntu 18.04. I just upgraded Openproject from 8.3 to the latest before beginning the migration.
Thank you for your help,
_tero
Replies (3)
Hi Tero,
What is line 19 of the
/etc/openproject/conf.d/other
file? It could be that yourDATABASE_URL
was not set which leaves your file with something like thisexport MYSQL_DATABASE_URL=
which will result in an error. This file is bascially an env file that gets parsed by bash and now contains a syntax error.Could you attach the
other
file here while redacting all passwords from it?Best,
Oliver
Hello Oliver,
Well thank you for the tip to look into the file. You know, I have no idea how this got there ( I must have done something silly in the console), but on line 18 there was:
Either log in as 'openproject', root, use sudo, or add sudo privileges for running openproject with your current user."
which I figured had no place in there. So I deleted it, and I have now completed the steps for the migration, and everything looks to be working great.
Thanks for your help!
Best regards,
Tero
Ciao Oliver,
I use the same thread as it is similar issue but with SMTP file which u can find copied below and the error is:
/etc/openproject/conf.d/smtp: line 9: unexpected EOF while looking for matching `"'
SMTP file.
Cheers