Author Topic: Problem avter migrating from 3.4.0.17 to 3.4.1  (Read 6722 times)

etienne

  • Newbie
  • *
  • Posts: 3
    • View Profile
Problem avter migrating from 3.4.0.17 to 3.4.1
« on: March 26, 2016, 08:35:13 PM »
Hi everybody

I upgraded from 3.4.0.17 to 3.4.1 today with Softaculous. After that, I had only the header visible. There ws a JS error : "og.preferences is undefined" in the layout.js file. Moreover, when I activated the debug mode, this MYSQL error was displayed: "Unknown column 'get_read_state_from_server' in 'field list'".

I immediately restored my previous installation.

simonwenger

  • Freshman
  • *
  • Posts: 32
    • View Profile
Re: Problem avter migrating from 3.4.0.17 to 3.4.1
« Reply #1 on: March 29, 2016, 08:41:48 AM »
I can confirm problems updating from 3.4.0.17 to 3.4.1
Doing it the normal way gives a Server Error (Error 500), if I tinker around with the top level files I can get as far as etienne, with only tehe header and the same error messages.
I restored the old version 3 times and reloaded the zip file to eliminate transfer errors, always the same.
Is there a known problem with this update?
Have others updated from 3.4.0.17 to 3.4.1 without issues?

Edit: I run PHP Version 5.6.18
memory_limit   128M
post_max_size   16M
Client API version   mysqlnd 5.0.11-dev - 20120503

Any other info required?
« Last Edit: April 03, 2016, 02:17:53 PM by simonwenger »

masonkante

  • Newbie
  • *
  • Posts: 6
    • View Profile
Re: Problem avter migrating from 3.4.0.17 to 3.4.1
« Reply #2 on: March 30, 2016, 10:35:54 AM »
Hi,

I have the same problem updating from 3.4.0.17 to 3.4.1.

Sombody has the same problem?

Thanks in advance

adrih

  • Newbie
  • *
  • Posts: 1
    • View Profile
Re: Problem avter migrating from 3.4.0.17 to 3.4.1
« Reply #3 on: April 03, 2016, 12:47:56 PM »
Hello, I get the same problem with the update from 3.4.o.17 to 3.4.1. Get de 500 internal server error. I use a server running php 5.6.
Never had this problem before. Tried it twice and had to restore the backups

natalia.martinez

  • Administrator
  • Jr. Member
  • *****
  • Posts: 69
    • View Profile
Re: Problem avter migrating from 3.4.0.17 to 3.4.1
« Reply #4 on: April 07, 2016, 12:10:15 PM »
Hi all,

Thanks for reporting this!

Well be checking this with Softaculous and keep you posted on the progress. We have been in touch recently with them in order to correct similar issues so well followup on that.

Best regards,

Natalia

cesarguerrero

  • Newbie
  • *
  • Posts: 4
    • View Profile
Re: Problem avter migrating from 3.4.0.17 to 3.4.1
« Reply #5 on: May 01, 2016, 03:42:44 PM »
I'm having the same problem while tryng to update from 3.4.0.7 to 3.4.1.0 with Softaculous. I made a backup of the installation, but not of the database, before updating.
As the guy above, it is not possible from me to open a console.

When I opened page /public/upgrade/index.php it said

You already have upgraded to the latest possible version: 3.4.1

    Config file found and loaded.
    File '/config/config.php' exists and is writable
    Folder '/config' exists and is writable
    Folder '/cache' exists and is writable
    Folder '/tmp' exists and is writable
    Folder '/upload' exists and is writable
    Extension 'mysql' is loaded
    Extension 'gd' is loaded
    Extension 'simplexml' is loaded

    Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in /home/gwervnwh/public_html/office/public/upgrade/library/classes/ScriptUpgrader.class.php on line 147
    Upgrade script has connected to the database.
    Test query has been executed. Its safe to proceed with database migration.
    Database schema transformations executed (total queries: 18)
    Feng Office has been upgraded. You are now running Feng Office 3.4.1 Enjoy!
    Please check for plugin updates.
    Open a console and execute the script 'public/install/plugin-console.php'
    with argument 'list' to view the plugins' status or argument 'update_all' to update them all.

So I'm afraid that if I try to rollback the softaculous installation, it may not work properly with the database in its current state. Is that correct?
If it is, where can I find which are the 18 schema transformation queries mentioned above so that I can undo them?


cesarguerrero

  • Newbie
  • *
  • Posts: 4
    • View Profile
Re: Problem avter migrating from 3.4.0.17 to 3.4.1
« Reply #6 on: May 01, 2016, 04:13:50 PM »
Nevermind. Since I could't get any help from my hosting provider and I couldn't be offline for ever, I decided to try the softaculous rollback, so I discovered that it, indeed, includes a database rollback. So now I have a working installation again. But please find out what's wrong with this update..

ThorstenW

  • Freshman
  • *
  • Posts: 35
    • View Profile
Re: Problem avter migrating from 3.4.0.17 to 3.4.1
« Reply #7 on: May 11, 2016, 02:04:27 PM »
[...] Moreover, when I activated the debug mode, this MYSQL error was displayed: "Unknown column 'get_read_state_from_server' in 'field list'".

This is caused by the current upgrade procedure which requires two independent procedures to update the database. If you skip one, you are stuck with an inconsistent state of your installation.

Reason & Solution:
[Step1] The installation files (e.g. fengoffice_3.4.1.zip) contains the core files including three preinstalled plugins "core_dimensions", "mail", "workspaces".
[Step2] The main upgrade script (fengoffice/public/upgrade) only updates the core database tables without those of the preinstalled plugins.
If you stop here, your installation will most likely be broken, as the plugin files are updated but the database is not.
(in this case: 'get_read_state_from_server' is a new field introduced to the table 'mail_accounts' of the mail plugin. This table doesn't get updated by Step 2 so the mail plugin fails and breaks the installation)
[Step3] You can't use the GUI due to the error. Therefore you must run the plugin update script (php fengoffice/public/install/plugin-console.php update_all) from console/command line to complete the database update for the plugins.

HTH
Thorsten

steveg

  • Full Member
  • ***
  • Posts: 176
    • View Profile
Re: Problem avter migrating from 3.4.0.17 to 3.4.1
« Reply #8 on: May 13, 2016, 02:45:12 PM »
Yup - i can confirm that if you run the plugin upgrade from console this solves things!

simonwenger

  • Freshman
  • *
  • Posts: 32
    • View Profile
Re: Problem avter migrating from 3.4.0.17 to 3.4.1
« Reply #9 on: May 14, 2016, 02:33:31 PM »
I can confirm the above solution.

I tried the above now using 3.4.2, upgrading from the console.
I get the following errors in the console:

simonwen@s34 [~/www]$ php f2/public/upgrade/console.php
Config file found and loaded.
File '/config/config.php' exists and is writable
Folder '/config' exists and is writable
Folder '/cache' exists and is writable
Folder '/tmp' exists and is writable
Folder '/upload' exists and is writable
Extension 'mysql' is loaded
Extension 'gd' is loaded
Extension 'simplexml' is loaded
PHP Deprecated:  mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in /home/simonwen/www/f2/public/upgrade/library/classes/ScriptUpgrader.class.php on line 147

Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in /home/simonwen/www/f2/public/upgrade/library/classes/ScriptUpgrader.class.php on line 147
Upgrade script has connected to the database.
Test query has been executed. Its safe to proceed with database migration.
2016-05-14 09:05:14 - Starting upgrade to 3.4.2
Error: Failed to execute DB schema transformations. MySQL said: Subquery returns more than 1 row
Error upgrading to version 3.4.2

2016-05-14 09:05:14 - Updating plugins...
2016-05-14 09:05:14 - Finished plugins update.

So it looks like going wrong. But then

simonwen@s34 [~/www/f2]$ php public/install/plugin-console.php list
DISPLAYING ONLY INSTALLED PLUGINS (to display all plugins use 'list_all')
---------------------------------------------
NAME:       core_dimensions
VERSION:    13
STATUS:    Activated
---------------------------------------------
NAME:       liquid_office
VERSION:    5
STATUS:    Inactive
---------------------------------------------
NAME:       mail
VERSION:    18
STATUS:    Activated
*** There is a new version of this plugin ***
---------------------------------------------
NAME:       workspaces
VERSION:    13
STATUS:    Activated
*** There is a new version of this plugin ***
simonwen@s34 [~/www/f2]$ php public/install/plugin-console.php update_all
simonwen@s34 [~/www/f2]$


makes things go right.

Thanks to ThorstenW!

Cheers!

malc25

  • Newbie
  • *
  • Posts: 1
    • View Profile
Re: Problem migrating from 3.4.0.17 to 3.4.4.1
« Reply #10 on: May 20, 2017, 10:00:35 PM »
Same problem with me too.....had to down-grade from backup.

Any more thoughts on this upgrade problem?   8)

ThorstenW

  • Freshman
  • *
  • Posts: 35
    • View Profile
Re: Problem avter migrating from 3.4.0.17 to 3.4.1
« Reply #11 on: May 21, 2017, 10:44:37 PM »
The steps I pointed out above still work for me. Tested it with 3.4.x => 3.5.0.9 today.

If you don't have access to a console, you might build yourself one in a php script. Example with message output (use at own risk!):
Code: [Select]
<?php
$ret 
= array();
$exitcode = array();
$fengoffice '/complete/root/path/to/your/fengoffice';
exec("php $fengoffice/public/upgrade/console.php"$ret[], $exitcode[]);
exec("php $fengoffice/public/install/plugin-console.php list"$ret[], $exitcode[]);
exec("php $fengoffice/public/install/plugin-console.php update_all"$ret[], $exitcode[]);
unlink("$fengoffice/cache/autoloader.php");
print 
'<pre>';
var_dump($exitcode);
var_export($ret);
print 
'</pre>';
?>

Result after running script:
Quote
array (
  0 =>
  array (
    0 => 'Config file found and loaded.',
    1 => 'File \'/config/config.php\' exists and is writable',
    2 => 'Folder \'/config\' exists and is writable',
    3 => 'Folder \'/cache\' exists and is writable',
    4 => 'Folder \'/tmp\' exists and is writable',
    5 => 'Folder \'/upload\' exists and is writable',
    6 => 'Extension \'mysql\' is loaded',
    7 => 'Extension \'gd\' is loaded',
    8 => 'Extension \'simplexml\' is loaded',
    9 => '',
    10 => 'Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in /complete/root/path/to/your/fengoffice/public/upgrade/library/classes/ScriptUpgrader.class.php on line 147',
    11 => 'Upgrade script has connected to the database.',
    12 => 'Test query has been executed. Its safe to proceed with database migration.',
    13 => '2017-05-22 01:08:40 - Starting upgrade to 3.4.4.52',
    14 => 'Database schema transformations executed (total queries: 35)',
    15 => 'Updating users timezone settings...',
    16 => 'Feng Office has been upgraded. You are now running Feng Office 3.4.4.52 Enjoy!',
    17 => '2017-05-22 01:08:40 - Finished upgrade to 3.4.4.52',
    18 => '2017-05-22 01:08:40 - Starting upgrade to 3.5.0.9',
    19 => 'Database schema transformations executed (total queries: 10)',
    20 => 'Feng Office has been upgraded. You are now running Feng Office 3.5.0.9 Enjoy!',
    21 => '2017-05-22 01:08:40 - Finished upgrade to 3.5.0.9',
    22 => '2017-05-22 01:08:40 - Updating plugins...',
    23 => '2017-05-22 01:08:41 - Finished plugins update.',
  ),
  1 =>
  array (
    0 => '',
    1 => 'DISPLAYING ONLY INSTALLED PLUGINS (to display all plugins use \'list_all\')',
    2 => '',
    3 => '---------------------------------------------',
    4 => 'NAME:       core_dimensions',
    5 => 'VERSION:    14',
    6 => 'STATUS:    Activated',
    7 => '---------------------------------------------',
    8 => 'NAME:       mail',
    9 => 'VERSION:    24',
    10 => 'STATUS:    Activated',
    11 => '---------------------------------------------',
    12 => 'NAME:       workspaces',
    13 => 'VERSION:    15',
    14 => 'STATUS:    Activated',
    15 => '',
  ),
  2 =>
  array (
    0 => '',
  ),
)
As you can see in line 22, plugins were automatically updated in exec #1. So it's probably no longer necessary to call update_all (exec #3), but doesn't do any harm either.

Greetings,
Thorsten

primvakt

  • Freshman
  • *
  • Posts: 17
    • ICQ Messenger - 271551524
    • MSN Messenger - primvakt@yandex.ru
    • Yahoo Instant Messenger - нача
    • View Profile
    • начало
    • Email
Problem avter migrating from 3 4 0 17 to
« Reply #12 on: March 28, 2018, 04:19:18 AM »
Hi,
did any of You met problem with INTERNAL ded rewriter? i mean i can burn CD?DVDs only from one workstation no 1 and second i can only read disks.

regards,AK
<a href=http://pskbigmaster.ru/> </a>

nadir.latif

  • Newbie
  • *
  • Posts: 7
    • View Profile
    • Email
Re: Problem avter migrating from 3.4.0.17 to 3.4.1
« Reply #13 on: July 19, 2018, 08:12:12 AM »
We tried to upgrade Feng Office from version 2.3 to version 3.5.1.5. We followed this migration guide: http://www.fengoffice.com/web/wiki/doku.php/installation:migration.

When running the migration command: php public/upgrade/console.php it gave the error: Error: Failed to execute DB schema transformations. MySQL said: Specified key was too long; max key length is 1000 bytes

The problem was that the table schema for the tables: fo_contacts and fo_members had too many indexes. As a result the index size of table rows became too large. The sql queries for setting the column size were failing during migration. The solution was to edit the migration script and lower the column size. We had to change the following queries:

```
ALTER TABLE  `fo_contacts` MODIFY `surname` varchar(255) COLLATE 'utf8_unicode_ci' NOT NULL DEFAULT '';
ALTER TABLE `fo_members` CHANGE `name` `name` varchar(511) COLLATE 'utf8_unicode_ci' NOT NULL DEFAULT '';
```
to

```
ALTER TABLE  `fo_contacts` MODIFY `surname` varchar(75) COLLATE 'utf8_unicode_ci' NOT NULL DEFAULT '';
ALTER TABLE `fo_members` CHANGE `name` `name` varchar(100) COLLATE 'utf8_unicode_ci' NOT NULL DEFAULT '';
```

The changes had to made to the file: BauruUpgradeScript.class.php in public/upgrade/scripts folder. After making the changes we got the following error:

Error: Failed to execute DB schema transformations. MySQL said: Subquery returns more than 1 row

The problem was that the migration script had added duplicate data. We had to remove this duplicate data. After that migration script worked without problems.

To find the sql queries that were causing the problem, we had to first location the migration script that was relevant for our version of Feng Office. The migration script basically adds several sql queries to a variable. The queries are all executed together. To find out the sql queries that were being run we printed out the value of this variable and then ran the sql queries one by one from PhpMyAdmin. This allows us to find out which sql queries were failing.

Here is the final output:

root@ExergoDevelopment:/mnt/public_html/ccs1# php public/upgrade/console.php 
Config file found and loaded.
File '/config/config.php' exists and is writable
Folder '/config' exists and is writable
Folder '/cache' exists and is writable
Folder '/tmp' exists and is writable
Folder '/upload' exists and is writable
Extension 'mysql' is loaded
Extension 'gd' is loaded
Extension 'simplexml' is loaded
Upgrade script has connected to the database.
Test query has been executed. Its safe to proceed with database migration.
2018-07-19 10:39:24 - Starting upgrade to 3.4.4.52
Database schema transformations executed (total queries: 35)
Updating users timezone settings...
Feng Office has been upgraded. You are now running Feng Office 3.4.4.52 Enjoy!
2018-07-19 10:44:04 - Finished upgrade to 3.4.4.52
2018-07-19 10:44:04 - Starting upgrade to 3.5.1.5
Database schema transformations executed (total queries: 15)
Feng Office has been upgraded. You are now running Feng Office 3.5.1.5 Enjoy!
2018-07-19 10:44:05 - Finished upgrade to 3.5.1.5
2018-07-19 10:44:05 - Updating plugins...
2018-07-19 10:48:26 - Finished plugins update.
« Last Edit: July 19, 2018, 08:21:00 AM by nadir.latif »

 

anything