Forums | Mahara Community

Support /
Upgrading 1.4.0 to 1.5.2


anonymous profile picture
Account deleted
Posts: 3

29 August 2012, 13:27

Hello together,

I took over a Mahara 1.4.0 system which I didn't install. I don't know much about it as nobody worked me into it. My task now is to upgrade the system. 
I don't know where the initial installation of Mahara was downloaded and I don't know what non-core plug-ins are running on it. It uses a custom theme, which I thought would be my biggest problem in the Upgrading-progress... But unforunately I didn't get far enough to have trouble with the custom theme.The Upgrade failed in the first try. And as I don't have the rights to load the backup on the server and the database I decided to copy everything and try it with a xampp installation on my own system before crashing the operative system again.

I am using xamp v3.0.12 with MySQL and an Apache Server:
Apache-Version: Apache/2.4.2 (Win32) OpenSSL/1.0.1c PHP/5.4.4
PHP-Version: 5.4.4
MySQL: Client API version mysqlnd 5.0.10 - 20111026 - $Id: b0b3b15c693b7f6aeb3aa66b646fee339f175e39 $ (???)
MySQL Server 5.5 

I copied the database, the data and the web directory, edited the config.php and everything worked quite well. The only problem was that the files (profile-icons, uploaded files in groups, etc.) didn't work. The error in the php error log is (just as an example, there are plenty of such errors in the log):
[29-Aug-2012 16:20:14 UTC] [WAR] b5 (C:\xampp\htdocs\web\social\collabuni\lib\mahara.php:801) Creating default object from empty value
[29-Aug-2012 16:20:14 UTC] Call stack (most recent first):
[29-Aug-2012 16:20:14 UTC]   * log_message("Creating default object from empty value", 8, true, true, "C:\xampp\htdocs\web\social\collabuni\lib\mahara.ph...", 801) at C:\xampp\htdocs\web\social\collabuni\lib\errors.php:446
[29-Aug-2012 16:20:14 UTC]   * error(2, "Creating default object from empty value", "C:\xampp\htdocs\web\social\collabuni\lib\mahara.ph...", 801, array(size 7)) at C:\xampp\htdocs\web\social\collabuni\lib\mahara.php:801
[29-Aug-2012 16:20:14 UTC]   * get_config_plugin("blocktype", "wall", "defaultpostsizelimit") at C:\xampp\htdocs\web\social\collabuni\blocktype\wall\lib.php:161
[29-Aug-2012 16:20:14 UTC]   * PluginBlocktypeWall::wallpost_form(object(BlockInstance)) at C:\xampp\htdocs\web\social\collabuni\blocktype\wall\lib.php:62
[29-Aug-2012 16:20:14 UTC]   * PluginBlocktypeWall::render_instance(object(BlockInstance)) at Unknown:0
[29-Aug-2012 16:20:14 UTC]   * call_user_func_array(array(size 2), array(size 1)) at C:\xampp\htdocs\web\social\collabuni\lib\mahara.php:1184
[29-Aug-2012 16:20:14 UTC]   * call_static_method("PluginBlocktypeWall", "render_instance", object(BlockInstance)) at C:\xampp\htdocs\web\social\collabuni\blocktype\lib.php:672
[29-Aug-2012 16:20:14 UTC]   * BlockInstance->render_viewing() at C:\xampp\htdocs\web\social\collabuni\lib\view.php:1398
[29-Aug-2012 16:20:14 UTC]   * View->build_column(1, false) at C:\xampp\htdocs\web\social\collabuni\lib\view.php:1366
[29-Aug-2012 16:20:14 UTC]   * View->build_columns() at C:\xampp\htdocs\web\social\collabuni\user\view.php:309 

But that didn't stop me from trying to upgrade the system. The upgrade started, the progress "bar" spinned and spinned. But it never finished. There was no explicit error in the error-log aswell:
[27-Aug-2012 17:42:42 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 100/3485
[27-Aug-2012 17:42:44 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 200/3485
[27-Aug-2012 17:42:46 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 300/3485
[27-Aug-2012 17:42:48 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 400/3485
[27-Aug-2012 17:42:51 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 500/3485
[27-Aug-2012 17:42:53 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 600/3485
[27-Aug-2012 17:42:56 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 700/3485
[27-Aug-2012 17:42:58 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 800/3485
[27-Aug-2012 17:43:00 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 900/3485
[27-Aug-2012 17:43:02 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 1000/3485
[27-Aug-2012 17:43:05 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 1100/3485
[27-Aug-2012 17:43:07 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 1200/3485
[27-Aug-2012 17:43:09 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 1300/3485
[27-Aug-2012 17:43:11 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 1400/3485
[27-Aug-2012 17:43:14 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 1500/3485
[27-Aug-2012 17:43:16 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 1600/3485
[27-Aug-2012 17:43:18 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 1700/3485
[27-Aug-2012 17:43:21 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 1800/3485
[27-Aug-2012 17:43:23 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 1900/3485
[27-Aug-2012 17:43:26 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 2000/3485
[27-Aug-2012 17:43:29 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 2100/3485
[27-Aug-2012 17:43:31 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 2200/3485
[27-Aug-2012 17:44:10 UTC] [DBG] a7 (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 2300/3485 

When I manually stopped the upgrade the following error occured:
[27-Aug-2012 18:13:08 UTC] [DBG] 2b (C:\xampp\htdocs\web\social\collabuni\admin\upgrade.php:98) Not upgrading; unfinished upgrade from 2012/08/27 19:42 still in progress
[27-Aug-2012 18:13:08 UTC] [WAR] 2b (C:\xampp\htdocs\web\social\collabuni\lib\web.php:2761) include_once(C:\xampp\htdocs\web\social\collabuni/lib/htmlpurifiercustom/YouTubeIframe.php): failed to open stream: No such file or directory
[27-Aug-2012 18:13:08 UTC] Call stack (most recent first):
[27-Aug-2012 18:13:08 UTC]   * log_message("include_once(C:\xampp\htdocs\web\social\collabuni/...", 8, true, true, "C:\xampp\htdocs\web\social\collabuni\lib\web.php", 2761) at C:\xampp\htdocs\web\social\collabuni\lib\errors.php:446
[27-Aug-2012 18:13:08 UTC]   * error(2, "include_once(C:\xampp\htdocs\web\social\collabuni/...", "C:\xampp\htdocs\web\social\collabuni\lib\web.php", 2761, array(size 8)) at C:\xampp\htdocs\web\social\collabuni\lib\web.php:2761
[27-Aug-2012 18:13:09 UTC]   * clean_html() at C:\xampp\htdocs\web\social\collabuni\lib\web.php:2761
[27-Aug-2012 18:13:09 UTC]   * clean_html("An upgrade began at 2012/08/27 19:42 and did not c...") at C:\data\web\social\data\dwoo\compile\default\C-\xampp\htdocs\web\social\collabuni\theme\raw\templates\message.tpl.d17.php:10
[27-Aug-2012 18:13:09 UTC]   * include("C:\data\web\social\data\dwoo\compile\default\C-\xa...") at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\Dwoo.php:364
[27-Aug-2012 18:13:09 UTC]   * Dwoo->get(object(Dwoo_Template_File), array(size 20)) at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\mahara\Dwoo_Mahara.php:118
[27-Aug-2012 18:13:09 UTC]   * Dwoo_Mahara->fetch("message.tpl") at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\mahara\Dwoo_Mahara.php:105
[27-Aug-2012 18:13:09 UTC]   * Dwoo_Mahara->display("message.tpl") at C:\xampp\htdocs\web\social\collabuni\lib\errors.php:387
[27-Aug-2012 18:13:09 UTC]   * die_info("An upgrade began at 2012/08/27 19:42 and did not c...") at C:\xampp\htdocs\web\social\collabuni\admin\upgrade.php:99

I loaded the backup files and recovered the database to retry the upgrade. But the site didn't run as expected (and working before...). The Top Header didnt work as there was suddenly no path given for it in the html source code. I am not sure but I think that this is the corresponding error from the log:
[27-Aug-2012 18:42:25 UTC] [WAR] c6 (C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\Dwoo\Loader.php:103) include(C:\xampp\htdocs\web\social\collabuni\lib\dwoo\mahara\plugins\display_default_name.php): failed to open stream: No such file or directory
[27-Aug-2012 18:42:25 UTC] Call stack (most recent first):
[27-Aug-2012 18:42:25 UTC]   * log_message("include(C:\xampp\htdocs\web\social\collabuni\lib\d...", 8, true, true, "C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo...", 103) at C:\xampp\htdocs\web\social\collabuni\lib\errors.php:446
[27-Aug-2012 18:42:25 UTC]   * error(2, "include(C:\xampp\htdocs\web\social\collabuni\lib\d...", "C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo...", 103, array(size 2)) at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\Dwoo\Loader.php:103
[27-Aug-2012 18:42:25 UTC]   * Dwoo_Loader::loadPlugin() at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\Dwoo\Loader.php:103
[27-Aug-2012 18:42:25 UTC]   * Dwoo_Loader->loadPlugin("display_default_name", false) at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\Dwoo\Compiler.php:2903
[27-Aug-2012 18:42:25 UTC]   * Dwoo_Compiler->getPluginType("display_default_name") at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\Dwoo\Compiler.php:2692
[27-Aug-2012 18:42:25 UTC]   * Dwoo_Compiler->replaceModifiers(array(size 4), "var", 28) at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\Dwoo\Compiler.php:2178
[27-Aug-2012 18:42:25 UTC]   * Dwoo_Compiler->parseVar("    {foreach from=$friends item=row}

[27-Aug-2012 18:42:25 UTC]         <tr>...", 413, 531, false, "root", 420) at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\Dwoo\Compiler.php:1328
[27-Aug-2012 18:42:25 UTC]   * Dwoo_Compiler->parse("    {foreach from=$friends item=row}

[27-Aug-2012 18:42:25 UTC]         <tr>...", 413, null, false, "root", 420) at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\Dwoo\Compiler.php:794
[27-Aug-2012 18:42:25 UTC]   * Dwoo_Compiler->compile(object(Dwoo_Mahara), object(Dwoo_Template_Mahara_Blocktype)) at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\Dwoo\Template\String.php:369
[27-Aug-2012 18:42:25 UTC]   * Dwoo_Template_String->getCompiledTemplate(object(Dwoo_Mahara), null) at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\Dwoo.php:363
[27-Aug-2012 18:42:25 UTC]   * Dwoo->get(object(Dwoo_Template_Mahara_Blocktype), array(size 4)) at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\mahara\Dwoo_Mahara.php:118
[27-Aug-2012 18:42:25 UTC]   * Dwoo_Mahara->fetch("blocktype:myfriends:myfriendrows.tpl") at C:\xampp\htdocs\web\social\collabuni\blocktype\myfriends\lib.php:58
[27-Aug-2012 18:42:25 UTC]   * PluginBlocktypeMyfriends::build_myfriends_html(array(size 4), "52", object(BlockInstance)) at C:\xampp\htdocs\web\social\collabuni\blocktype\myfriends\lib.php:96
[27-Aug-2012 18:42:25 UTC]   * PluginBlocktypeMyfriends::render_instance(object(BlockInstance)) at Unknown:0
[27-Aug-2012 18:42:25 UTC]   * call_user_func_array(array(size 2), array(size 1)) at C:\xampp\htdocs\web\social\collabuni\lib\mahara.php:1184
[27-Aug-2012 18:42:25 UTC]   * call_static_method("PluginBlocktypeMyfriends", "render_instance", object(BlockInstance)) at C:\xampp\htdocs\web\social\collabuni\blocktype\lib.php:672
[27-Aug-2012 18:42:25 UTC]   * BlockInstance->render_viewing() at C:\xampp\htdocs\web\social\collabuni\lib\view.php:1398
[27-Aug-2012 18:42:25 UTC]   * View->build_column(1, false) at C:\xampp\htdocs\web\social\collabuni\lib\view.php:1366
[27-Aug-2012 18:42:25 UTC]   * View->build_columns() at C:\xampp\htdocs\web\social\collabuni\user\view.php:309

I recovered everything several times, restarted the computer and the xampp server and eventually it worked. I have no idea why... But the user-profile icons, group files, etc. still didn't work.

I retried the upgrade:
[...]
[29-Aug-2012 16:32:59 UTC] [DBG] 0d (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 2800/3485
[29-Aug-2012 16:33:35 UTC] [DBG] 0d (C:\xampp\htdocs\web\social\collabuni\artefact\internal\blocktype\textbox\db\upgrade.php:114) Upgrading textbox blocks: 2900/3485

... and it stopped again without an error. But it came to 2900/3485 this time (the last time it ended at 2300/3485)

I tried to load the backups again and the Header-Logo didn't work once more. I repeatedly loaded the backups as I did yesterday but the happy end didn't come as I am getting a new error now. When I visit the site it doesn't load and states:
ERROR - something bad happened after headers have been sent. Check the error log for more information.

The error log says: 
[29-Aug-2012 18:13:17 UTC] [WAR] 4c (C:\xampp\htdocs\web\social\collabuni\lib\errors.php:464) An exception was thrown of class Dwoo_Exception. 
[29-Aug-2012 18:13:17 UTC] [WAR] 4c (C:\xampp\htdocs\web\social\collabuni\lib\errors.php:464) THIS IS BAD and should be changed to something extending MaharaException,
[29-Aug-2012 18:13:17 UTC] [WAR] 4c (C:\xampp\htdocs\web\social\collabuni\lib\errors.php:464) unless the exception is from a third party library.
[29-Aug-2012 18:13:17 UTC] [WAR] 4c (C:\xampp\htdocs\web\social\collabuni\lib\errors.php:464) Original trace follows
[29-Aug-2012 18:13:17 UTC] [WAR] 4c (C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\Dwoo\Loader.php:112) Plugin <em>display_default_name</em> can not be found, maybe you forgot to bind it if it's a custom plugin ?
[29-Aug-2012 18:13:17 UTC] Call stack (most recent first):
[29-Aug-2012 18:13:17 UTC]   * Dwoo_Loader->loadPlugin("display_default_name") at C:\data\web\social\data\dwoo\compile\default\C-\xampp\htdocs\web\social\collabuni\theme\raw\templates\header\topright.tpl.d17.php:4
[29-Aug-2012 18:13:17 UTC]   * include("C:\data\web\social\data\dwoo\compile\default\C-\xa...") at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\Dwoo.php:364
[29-Aug-2012 18:13:17 UTC]   * Dwoo->get(object(Dwoo_Template_File), array(size 23), null, false) at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\Dwoo.php:312
[29-Aug-2012 18:13:17 UTC]   * Dwoo->get(object(Dwoo_Template_File), array(size 23)) at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\plugins\builtin\functions\include.php:70
[29-Aug-2012 18:13:17 UTC]   * Dwoo_Plugin_include(object(Dwoo_Mahara), "header/topright.tpl", null, null, null, "_root", null) at C:\data\web\social\data\dwoo\compile\default\C-\xampp\htdocs\web\social\collabuni\theme\raw\templates\header.tpl.d17.php:40
[29-Aug-2012 18:13:17 UTC]   * include("C:\data\web\social\data\dwoo\compile\default\C-\xa...") at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\Dwoo.php:364
[29-Aug-2012 18:13:17 UTC]   * Dwoo->get(object(Dwoo_Template_File), array(size 23), null, false) at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\Dwoo.php:312
[29-Aug-2012 18:13:17 UTC]   * Dwoo->get(object(Dwoo_Template_File), array(size 23)) at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\plugins\builtin\functions\include.php:70
[29-Aug-2012 18:13:17 UTC]   * Dwoo_Plugin_include(object(Dwoo_Mahara), "header.tpl", null, null, null, "_root", null) at C:\data\web\social\data\dwoo\compile\default\C-\xampp\htdocs\web\social\collabuni\theme\raw\templates\index.tpl.d17.php:6
[29-Aug-2012 18:13:17 UTC]   * include("C:\data\web\social\data\dwoo\compile\default\C-\xa...") at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\dwoo\Dwoo.php:364
[29-Aug-2012 18:13:17 UTC]   * Dwoo->get(object(Dwoo_Template_File), array(size 23)) at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\mahara\Dwoo_Mahara.php:118
[29-Aug-2012 18:13:17 UTC]   * Dwoo_Mahara->fetch("index.tpl") at C:\xampp\htdocs\web\social\collabuni\lib\dwoo\mahara\Dwoo_Mahara.php:105
[29-Aug-2012 18:13:17 UTC]   * Dwoo_Mahara->display("index.tpl") at C:\xampp\htdocs\web\social\collabuni\index.php:106


I am really desperate as no error seems to be reproducible and I run into new problems all the time... The first thing to be fixed now is the last mentioned problem because I cant load the site and do anything right now. I would be very grateful if anyone could help me with my problems. 

Kindest regards,

Christian

Yaju Mahida's profile picture
Posts: 131

02 September 2012, 19:14

It seems your are affected with this bug Remove Explicit CAST from textbox to artefact upgrade queries.

For more information please read this - Upgrade 1.4.2 - 1.5 fails.

anonymous profile picture
Account deleted
Posts: 3

04 September 2012, 11:48

Thank you very much!

Unfortunately I can't try the workaround because the backup of the system doesn't work. It throws the last mentioned "Dwoo_Exception". Does anyone have an idea how to fix this?

 

Thanks in advance!

Christian

anonymous profile picture
Account deleted
Posts: 197

18 September 2012, 0:34

Hi Christian,

Without knowing what customisations you may be dealing with (if you download the same version of 1.4 as the version file says, you can compare it against your current code files with a diff tool), I can tell you this much:

Dwoo gets cached, and it looks like the cache (in the C:\data\web\social\data\dwoo\compile\default\C-\xampp\htdocs\web\social\collabuni\theme\raw\templates\header\topright.tpl.d17.php directory) is for 1.5, but if you're trying to run your backups, you need the cache to match 1.4. If you clear the C:\data\web\social\data\dwoo\compile directory of its contents, it should come right. It may already have expired anyway.

Thanks,
Melissa.

A post by Account deleted was deleted

anonymous profile picture
Account deleted
Posts: 3

07 October 2012, 15:37

Hi Melissa,

 

thanks a million! That was an easy solution. :)
I now upgraded the system on my local copy and everything worked fine (it was indeed a time-out problem, thanks again to Yaju for the solution!). 

Now I only have to customize everything again. The tip with the diff tool ist a great idea, I'll try that one. Thanks a lot again! 

Hopefully everything will work as well when I'll try it on the real system. :-) 

 

Best regards,

Christian

6 results