Topic: Upgrade from 2.3.25 to 2.42: DB upgrade not working

I have copied all 2.42 source files over my existing installation (on a copied system) and can log in as admin. I get the warning
"System is blocked after source upgrade until database is updated on System/Software Upgrade page".
So I went to Setup -> Software Upgrade.
After clicking, the browser just sits there and spins till after about 2 minutes later I get:
"Request Timeout
This request takes too long to process, it is timed out by the server. If it should not be timed out, please contact administrator of this web site to increase 'Connection Timeout'. "
Any ideas?

Re: Upgrade from 2.3.25 to 2.42: DB upgrade not working

Any upgrade will require the first login to be admin on the default company. Thereafter, a login as admin for each company will be in order. The value of the version_id in the sys_prefs table must be 2.4.1 as of now - that is the current database schema version.

1. Take a backup of the database for all companies individually before any upgrade.
2. All v2.3.x installations must first upgrade to the v2.3.26 version even if there is no db change necessary.
3. Take a backup of each company individually again now.
4. Then make sure all is well by checking out the various company instances.
5. Take note of non FA tables and tables belonging to various FA Extensions and the changes in the tables some extensions may have made.
6. Make a clean FA 2.4 installation and use it in the following steps.
7. Create each company manually with the standard en_US.sql in the FA 2.4.x install.
8. Import the FA 2.3.26 backup from step 3 above for every non default company (assuming your default company is just a dummy one)
9. Login as admin into each upgraded company and verify that the software upgrade shows as having been done.
10. Copy over the company folder image and custom reports assets into the new installation.
11. Now install your extensions and verify they work and tweak their tables and changes as needed.
12. Any custom code / tables / schema mods you may have done in 2.3.x must then be ported professionally.

Re: Upgrade from 2.3.25 to 2.42: DB upgrade not working

FA 2.3 and FA 2.4 has  more changes in its functionality and added asset module and the reference method also changed. So its good to keep the 2.3.25 and manually install FA 2.4 for the further new things. If you wish to upgrade, You should digg more into many core files and also many changes in the database tables. If you have more data's in the existing table. You better go with separate installations.

Re: Upgrade from 2.3.25 to 2.42: DB upgrade not working

Thanks. I have upgraded to 2.3.26 without problems.
I have installed a separate version of 2.4.2 with all latest patches and a default company.
I have create my own company (db set 1) and uploaded the database backup from 2.3.26 (same company prefix).
I have started the DB upgrade - but does not finish... how long can it take to upgrade a DB when it's size is about 11MB?
I might need to change timeout values for PHP or MySQL accordingly?

Upgrade log reports:
[07-Sep-2017 04:19:44 Europe/Berlin] [Info] Upgrade started for company 1.
[07-Sep-2017 04:19:51 Europe/Berlin] [Info] Security backup in file ../company/1/backup/frontac_1_20170907_0419.sql done.
[07-Sep-2017 04:20:58 Europe/Berlin] [Info] Switching database to utf8 encoding from latin1

After that the screen just returns to a blank screen. It takes about 60-90 seconds. I have set PHP timeout to 300 sec.

When I try it again it will report many already existing or missing fields due to partly converted DB:
Last log entry before it stops is: 308:Unknown column 'counter' in '1_budget_trans'

What I don't understand is the statement "switching DB to utf8 from latin1" as the DB is already in utf8.

Remark: I run these tests currently on a local machine with XAMPP PHP 5.6 and Maria SQL Server 10.1

Last edited by incocare (09/07/2017 02:37:35 am)

Re: Upgrade from 2.3.25 to 2.42: DB upgrade not working

@joe: change line 23 in sql/alter2.4.php:

        $this->description = _('Upgrade from version 2.3 to 2.4RC1');

to

        $this->description = _('Upgrade from version 2.3 to 2.4.1');

Also line 158 in the same file needs to be conditionally acquired:

        $old_encoding = 'latin1'; // default client encoding

Looks like your db schema needs 900 secs time out instead of 300. Also check the attached schema differences between FA 2.3 and 2.4.

Post's attachments

FA_23_to_24_budget_trans.png 21.08 kb, file has never been downloaded. 

You don't have the permssions to download the attachments of this post.