Moving data from IN 3.7.0 to IN 4.2.2

Ok, After several failed attempts to update my install (3.7.0) to the latest I decided to do a new install on a new server. What would be the best way to move data to new install? I have white label self hosting and would like to move to a new server and bring my lic over for white label. Also I’d like to bring over all data like clients, invoices, etc.

You can use mysqldump to transfer the database and then copy over the .env file.

What errors did you see when upgrading? You may see the same problem after copying over the database.

I was using the update script and ended up getting nowhere. I’ll do some reading on doing an SQL dump and I can handle moving the env file. I didn’t know if I could use the export / import function to move everything. I let you know how it goes.

Ok, copied over the database, env file and made changes to the env file to reflect the changes. (IP address, DB login,etc)

Now I get to the login page and it works but as soon as I log in it displays “Whoops, looks like something went wrong.”

Can’t get any further. Any suggestions?

Please check for details about the error in storage/logs/laravel-error.log

here is what it shows.

[2018-03-21 16:11:00] production.ERROR: Doctrine\DBAL\Driver\PDOException [1045] : /var/www/html/ninja/vendor/doctrine/dbal/lib/Doctrine/DBAL/Driver/PDOConnection.php [Line 47] => SQLSTATE[HY000] [1045] Access denied for user ‘ninja’@‘localhost’ (using password: YES) {“context”:“PHP”,“user_id”:0,“account_id”:0,“user_name”:"",“method”:“GET”,“url”:“https://.../dashboard”,“previous”:“https://.../settings/import_export”,“user_agent”:“Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.167 Safari/537.36”,“ip”:“...”,“count”:1,“is_console”:“no”,“is_api”:“no”,“db_server”:“mysql”}

Are the database credentials in the .env file correct?

yes. everything looks good. I imported the DB from my old install to my new install, made sure user “ninja” had full permission, made sure password was good, made sure the .env file settings matched. Like I said, it lets me login but goes to the error.

Sorry, I don’t have any advice besides checking the database credentials.

Looks like the PHP database driver might be missing. Check php -m and see if pdo_mysql is listed. If not, you can do apt install php-mysql, then restart your webserver (might also want to restart php-fpm if you’re using nginx).

If that doesn’t work, what version of PHP got installed when you set everything up? 7.0 and 7.1 should be fine, but if it installed 7.2, I don’t think IN supports that until 4.3 comes out.