Installation help

Problem upgrading from Moodle 2.2.2 to 2.4+

 
 
Picture of Rick Sparrow
Problem upgrading from Moodle 2.2.2 to 2.4+
 

Hi there, hoping someone can help please!

I'm trying to upgrade our Moodle server from 2.2.2 to the latest 2.4+ release. This is running on a dedicated server running Ubuntu 12.04.1 LTS.

I put the server into maintenance mode, backed up everything, downloaded 2.4 and unzipped, copied back the config.php, themes and mod directories. I went back to the web browser to start the upgrade process. Moodle displayed a message asking if I wanted to begin the upgrade process, which I confirmed. So far so good. it came up with a screen to review plugins. There were some issues with outdated plug-ins, so I installed the most recent. During this step, Moodle came up with "Site is being upgraded, please try again later" which caught me off-guard as I thought I was still just reviewing the plugins. I waited a bit and came back and eventually I could login again. However the front page is messed up--the original theme is gone, and several of the main links on the left hand side of the window are no longer available to select.

I've attached a screenshot. How do I go about fixing this? My guess would be there is some permissions issue but as far as I can tell, they are configured OK.

 

Thanks in advance for any help you can provide!

Rick


 
Average of ratings: -
Picture of Ken Task
Re: Problem upgrading from Moodle 2.2.2 to 2.4+
Group Particularly helpful Moodlers

The downloads page shows a .tar.gz and a .zip.  Did you really download the .zip?  Would think that since it's on Ubuntu the tar.gz would be a better choice.

Does a ls -l of the code directory show www-data:www-data as owner/group?

Did you chown www-data:www-data recursively on the moodle code directory?  When you installed those mods/themes and transfered them from old site to new site those may have gotten tagged as belonging to root:root.

Check apache error_log for clues too!

'spirit of sharing', Ken

 
Average of ratings: -
Picture of Rick Sparrow
Re: Problem upgrading from Moodle 2.2.2 to 2.4+
 

Sorry, I used 'unzipped' generically. I downloaded moodle-latest-24.tgz using the link on the moodle.org site, placed it in /var/www. Then ran tar xvzf moodle-latest-24.tgz as per the upgrade notes. I don't think that was the issue, as again the server does say it is now on 2.4+.

As a test, I ran chmod -R 0777 /var/moodledata and chmod -R 0777 /var/www/moodle, so they should be wide open, but no change. So at present /var/www/moodle shows root root for owner/group, and www-data www-data for /var/moodledata for owner/group.

I did back up the original /var/www/moodle directory, as well as the moodledata folder, and the database. So I guess I can revert back. I don't know what other file/folder permissions there would be to reset.

 
Average of ratings: -
Picture of Rick Sparrow
Re: Problem upgrading from Moodle 2.2.2 to 2.4+
 

This is really bizarre. I thought I'd give it another go, so I created a new /var/www moodle directory with the expanded 2.4 install files located there.

As before, it went through a plug-ins check. I copied over the plugins previously downloaded manually into the new mod folder. I had a message about the plugin files not being writable, so per the troubleshooting page I ran chown -R www-data mod and chmod -R u+w mod, and reloaded the test plugins page. This time the error went away and I had the option to automatically upgrade the plugins. That being done, I eventually got to the main login page. Now my default theme is there, but I still can't click on the majority of items on the left hand side of the main window. Attached an updated picture.

What other permissions are there to reset? I'm not sure what else there is to change.

Thanks in advance for any help,

Rick


 
Average of ratings: -
Picture of Ken Task
Re: Problem upgrading from Moodle 2.2.2 to 2.4+
Group Particularly helpful Moodlers

In the code directory, there is a config-dist.php file.  Copy the 'debugging' lines to your current config.php file.  No need to restart apache or other service - just refresh your browser and let's see what it says.

Also check the apache error logs.  Recently, have seen postings on issues with 2.4 related to the code behind the 'triangles' and 'drop down menus'.  Those might appear in either debugging output OR in apache error log.

'spirit of sharing', Ken

 
Average of ratings: -
Picture of Rick Sparrow
Re: Problem upgrading from Moodle 2.2.2 to 2.4+
 

OK, i reset permissions as suggested in your second reply (chown www-data:www-data www -R) but no change so far.

OK, I copied the following lines to my config.php

@error_reporting(E_ALL | E_STRICT); // NOT FOR PRODUCTION SERVERS!
@ini_set('display_errors', '1');    // NOT FOR PRODUCTION SERVERS!
$CFG->debug = (E_ALL | E_STRICT);   // === DEBUG_DEVELOPER - NOT FOR PRODUCTION SERVERS!
$CFG->debugdisplay = 1;             // NOT FOR PRODUCTION SERVERS!

Following a refresh, I get the following:

textlib_get_instance() is deprecated. Please use static calling textlib::functioname() instead.
  • line 2905 of /lib/deprecatedlib.php: call to debugging()
  • line 80 of /filter/wiris/filter.php: call to textlib_get_instance()
  • line 55 of /filter/wiris/filter.php: call to filter_wiris->WF_initfilter()
  • line 157 of /lib/filterlib.php: call to filter_wiris->filter()
  • line 195 of /lib/filterlib.php: call to filter_manager->apply_filter_chain()
  • line 319 of /lib/filterlib.php: call to filter_manager->filter_text()
  • line 1154 of /lib/weblib.php: call to performance_measuring_filter_manager->filter_text()
  • line 123 of /admin/settings/appearance.php: call to format_text()
  • line 6259 of /lib/adminlib.php: call to require()
  • line 3268 of /lib/navigationlib.php: call to admin_get_root()
  • line 3173 of /lib/navigationlib.php: call to settings_navigation->load_administration_settings()
  • line 701 of /lib/pagelib.php: call to settings_navigation->initialise()
  • line 717 of /lib/pagelib.php: call to moodle_page->magic_get_settingsnav()
  • line 133 of /blocks/settings/block_settings.php: call to moodle_page->__get()
  • line 284 of /blocks/moodleblock.class.php: call to block_settings->get_content()
  • line 232 of /blocks/moodleblock.class.php: call to block_base->formatted_contents()
  • line 953 of /lib/blocklib.php: call to block_base->get_content_for_output()
  • line 1005 of /lib/blocklib.php: call to block_manager->create_block_contents()
  • line 353 of /lib/blocklib.php: call to block_manager->ensure_content_created()
  • line 6 of /theme/canvas/layout/general.php: call to block_manager->region_has_content()
  • line 804 of /lib/outputrenderers.php: call to include()
  • line 734 of /lib/outputrenderers.php: call to core_renderer->render_page_layout()
  • line 153 of /my/index.php: call to core_renderer->header()

Strict Standards: Creating default object from empty value in /var/www/filter/wiris/filter.php on line 81 Strict Standards: Creating default object from empty value in /var/www/lib/editor/tinymce/version.php on line 27 Warning: include_once(/var/www/lib/editor/tinymce/tiny_mce/3.5.7b/plugins/tiny_mce_wiris/integration/libwiris.php): failed to open stream: No such file or directory in /var/www/filter/wiris/filtersettings.php on line 24 Warning: include_once(): Failed opening '/var/www/lib/editor/tinymce/tiny_mce/3.5.7b/plugins/tiny_mce_wiris/integration/libwiris.php' for inclusion (include_path='/var/www/lib/zend:/var/www/lib/pear:.:/usr/share/php:/usr/share/pear') in /var/www/filter/wiris/filtersettings.php on line 24

(see attached picture)

The most recent entries from /var/log/apache2/error.log shows the following:

[Thu Jan 03 12:59:38 2013] [error] [client 173.210.250.62] File does not exist: /var/www/favicon.ico
[Thu Jan 03 14:14:34 2013] [error] [client 192.168.4.40] PHP Strict Standards:  Creating default object from empty value in /var/www/filter/wiris/filter.php on line 81, referer: http://moodle.servername.ca/
[Thu Jan 03 14:14:34 2013] [error] [client 192.168.4.40] PHP Strict Standards:  Creating default object from empty value in /var/www/lib/editor/tinymce/version.php on line 27, referer: http://moodle.servername.ca/
[Thu Jan 03 14:14:34 2013] [error] [client 192.168.4.40] PHP Warning:  include_once(/var/www/lib/editor/tinymce/tiny_mce/3.5.7b/plugins/tiny_mce_wiris/integration/libwiris.php): failed to open stream: No such file or directory in /var/www/filter/wiris/filtersettings.php on line 24, referer: http://moodle.servername.ca/
[Thu Jan 03 14:14:34 2013] [error] [client 192.168.4.40] PHP Warning:  include_once(): Failed opening '/var/www/lib/editor/tinymce/tiny_mce/3.5.7b/plugins/tiny_mce_wiris/integration/libwiris.php' for inclusion (include_path='/var/www/lib/zend:/var/www/lib/pear:.:/usr/share/php:/usr/share/pear') in /var/www/filter/wiris/filtersettings.php on line 24, referer: http://moodle.servername.ca/
[Thu Jan 03 14:15:01 2013] [error] [client 192.168.4.40] PHP Strict Standards:  Creating default object from empty value in /var/www/lib/editor/tinymce/version.php on line 27, referer: http://moodle.servername.ca/my/
[Thu Jan 03 14:15:01 2013] [error] [client 192.168.4.40] PHP Warning:  include_once(/var/www/lib/editor/tinymce/tiny_mce/3.5.7b/plugins/tiny_mce_wiris/integration/libwiris.php): failed to open stream: No such file or directory in /var/www/filter/wiris/filtersettings.php on line 24, referer: http://moodle.servername.ca/my/
[Thu Jan 03 14:15:01 2013] [error] [client 192.168.4.40] PHP Warning:  include_once(): Failed opening '/var/www/lib/editor/tinymce/tiny_mce/3.5.7b/plugins/tiny_mce_wiris/integration/libwiris.php' for inclusion (include_path='/var/www/lib/zend:/var/www/lib/pear:.:/usr/share/php:/usr/share/pear') in /var/www/filter/wiris/filtersettings.php on line 24, referer: http://moodle.servername.ca/my/
[Thu Jan 03 14:15:26 2013] [error] [client 192.168.4.40] PHP Strict Standards:  Creating default object from empty value in /var/www/lib/editor/tinymce/version.php on line 27, referer: http://moodle.servername.ca/admin/index.php
[Thu Jan 03 14:15:26 2013] [error] [client 192.168.4.40] PHP Warning:  include_once(/var/www/lib/editor/tinymce/tiny_mce/3.5.7b/plugins/tiny_mce_wiris/integration/libwiris.php): failed to open stream: No such file or directory in /var/www/filter/wiris/filtersettings.php on line 24, referer: http://moodle.servername.ca/admin/index.php
[Thu Jan 03 14:15:26 2013] [error] [client 192.168.4.40] PHP Warning:  include_once(): Failed opening '/var/www/lib/editor/tinymce/tiny_mce/3.5.7b/plugins/tiny_mce_wiris/integration/libwiris.php' for inclusion (include_path='/var/www/lib/zend:/var/www/lib/pear:.:/usr/share/php:/usr/share/pear') in /var/www/filter/wiris/filtersettings.php on line 24, referer: http://moodle.servername.ca/admin/index.php
[Thu Jan 03 14:15:31 2013] [error] [client 192.168.4.40] PHP Strict Standards:  Creating default object from empty value in /var/www/lib/editor/tinymce/version.php on line 27, referer: http://moodle.servername.ca/my/
[Thu Jan 03 14:15:31 2013] [error] [client 192.168.4.40] PHP Warning:  include_once(/var/www/lib/editor/tinymce/tiny_mce/3.5.7b/plugins/tiny_mce_wiris/integration/libwiris.php): failed to open stream: No such file or directory in /var/www/filter/wiris/filtersettings.php on line 24, referer: http://moodle.servername.ca/my/
[Thu Jan 03 14:15:31 2013] [error] [client 192.168.4.40] PHP Warning:  include_once(): Failed opening '/var/www/lib/editor/tinymce/tiny_mce/3.5.7b/plugins/tiny_mce_wiris/integration/libwiris.php' for inclusion (include_path='/var/www/lib/zend:/var/www/lib/pear:.:/usr/share/php:/usr/share/pear') in /var/www/filter/wiris/filtersettings.php on line 24, referer: http://moodle.servername.ca/my/
[Thu Jan 03 14:17:07 2013] [error] [client 119.63.193.194] PHP Strict Standards:  Creating default object from empty value in /var/www/filter/wiris/filter.php on line 81

Thanks in advance for your help, Ken! The error message suggests there might still be a problem with one of the plugins (wiris) I'm not entirely sure how I can remove that to confirm, without being able to access the plugins settings on the main page. Would it be as easy as just removing the wiris directory from /var/www/filter?

Rick


 
Average of ratings: -
Picture of Ken Task
Re: Problem upgrading from Moodle 2.2.2 to 2.4+
Group Particularly helpful Moodlers

Can't read the error in the graphic ... too small.  That's text so one could copy and paste that text.

Hide the folder for that plugin ... wiris:

Change into directory where wiris is located (/var/www/filter/) and issue:

mv wiris .wiris

That renames the folder and makes it hidden to Apache and to Moodle.

Go to: Site administration
/ ▶ Plugins
/ ▶ Filters
/ ▶ Manage filters

and disable.

Hit Notifications in Site Admin menu.

About that plugin:

https://moodle.org/plugins/view.php?plugin=filter_wiris

As far as support for it:

https://moodle.org/user/profile.php?id=1343738

It would not be unusual to see/have bizarre behavior on an incompat plugin/theme/mod/ or whatever was incompat.

'spriit of sharing', Ken

 

 

 
Average of ratings: -
Picture of Ken Task
Re: Problem upgrading from Moodle 2.2.2 to 2.4+
Group Particularly helpful Moodlers

'So at present /var/www/moodle shows root root for owner/group'

Think the moodle directory and contents should be www-data:www-data, shouldn't they?

chown www-data:www-data moodle -R

'spirit of sharing', Ken

 
Average of ratings: -
Picture of Rick Sparrow
Re: Problem upgrading from Moodle 2.2.2 to 2.4+
 

Getting a little bit closer to resolving this!

You mentioned other people were having problems with the drop down menus and triangles, etc, so I searched elsewhere on the forum and found the suggestion to clear my browser's cache. So i tried that and that *seemed* to do the trick! I could now access the submenus.

But....thinking that's all the problem was, i went back to remove the debugging lines from config.php. And when I went to refresh, I could no longer access the submenus. Hmmmm.....

ANOTHER UPDATE: Since turning on debugging allowed me to get into the plugins menu, I removed the Wiris filter, as I read elsewhere about people having problems with that and version 2.4. I then removed the wiris directory. Interestingly, there were no more debugging notes on the top of each page even though it was still on. But once again, when I commented out the debugging lines from config.php, I could not access the submenus. So I guess I keep hunting.

Rick

 
Average of ratings: -
Picture of Ken Task
Re: Problem upgrading from Moodle 2.2.2 to 2.4+
Group Particularly helpful Moodlers

Some of those error lines relate to the menus you are trying to access.  2.4 now has a cache - but no tool to clear it!  

You'll find the MUC in the data folder and there is a editor_tinymce folder there - with dragMath cached.  That might have conflicted with the other editor plugin wiris.  There is also a folder for the theme.

Re-start apache service with debugging lines active, close browser, open browser and before accessing site clear browser cache as well.  From the terminal go to the datafolder/cache and issue the following command:

watch 'ls -lR'

Leave that terminal window where you can see it.  Then, with your browser, hit the site.  Check the 'watch' window to see what's being generated.

Go to Site Admin menu -> Plugins -> Caching ->

There are a few buttons for purging in Configured store instances. Purge them.  Advise not to tinker too much until current issues are resolved!

What other dodad/thingy did you copy from the old moodle code directory into new?  Unless you've a customized theme, themes do not need to be copied to new.  And let's take it out of maintenance mode if it's still in that mode.

Trying to get the 2.4 to a 'stock' 2.4 as possible.

'spirit of sharing', Ken

 
Average of ratings: -
Picture of Rick Sparrow
Re: Problem upgrading from Moodle 2.2.2 to 2.4+
 

Re: MUC in the data folder; I can't find one. Do you mean in /mod/data or /filter/data? I do see TinyMCE HTML Editor listed under plugins.

Before getting your reply, I turned maintenance mode back off, disabled debugging in config.php, rebooted the Moodle server and once again cleared the cache on Firefox. I also purged the three settings in Admin > Plugins > Caching > Configured store instances. Now the submenus are showing up there and in Chrome. The only one that's being fussy for me is IE 9. Depsite having cleared the cache, I can't access the menus there. Might have to do a more thorough purge! I'm thinking that might be a more local issue.

I'll try your other suggestions and get back to you.

 

 
Average of ratings: -
Picture of Ken Task
Re: Problem upgrading from Moodle 2.2.2 to 2.4+
Group Particularly helpful Moodlers

MUC is both a directory and uses a cache directory In your moodledata folder ....

From a Linux box (CentOS):

[root@sos moodle24data]# pwd

/var/www/moodle24data

[root@sos moodle24data]# ls
cache  environment  filedir  geoip  lang  muc  repository  temp  trashdir

[root@sos moodle24data]# cd cache

[root@sos cache]# ls
cachestore_file  editor_tinymce  filelocks  htmlpurifier  js  languages  theme

and yes, IE is *not* the browser to be using ... use FireFox.  Why is that NOT surprising? ;)  There is some compatibility setting in IE that supposed to help, but since I no 'workie' on a PC (and won't ever go back) can't tell where/what that is.

You are close! ;)

'spirit of sharing', Ken

 
Average of ratings: -
Picture of Rick Sparrow
Re: Problem upgrading from Moodle 2.2.2 to 2.4+
 

Just want to say thanks for all your help Ken. A more thorough cleaning of the IE9 cache solved the problem for my third browser test. No compatibility mode required to see everything working as far as I can tell.

 

Rick

 
Average of ratings: -