Second attempt at upgrading 1.9 to 2.0 (Part 2)

Posted on April 14th, 2011 in Administration, Moodle 2.0 | 2 Comments »

..continuing on with my 1.9 to 2.0 journey

As I mentioned in my previous post I was stuck on the “migrating courses” page when I tried upgrading from Moodle 1.9.11 to 2.0.2. The two errors coming up were “Incorrect pool file content” and a number of stack trace errors:

error

I did some Googling and found 2 tracker items regarding these issues but it didn’t seem like it was during the upgrading process. I did find one discussion thread from a few months back about this issue that helped me troubleshoot.

First, I turned on as much debugging, error reporting or messages I could in the config.php file (not sure if there are other debugging settings to turn on?):

debugging

The debugging information didn’t help too much and I couldn’t find any error logs regarding this issue, so I continued to Google and research online. I checked out the /lib/filestorage/filestorage.php file because that was the file where the apparent first two errors were happening. I’m no expert at PHP so I wasn’t quite sure how to change or echo any further information when upgrading to see if it gave me anything more to work with.

I continued to read through the discussion thread I mentioned over and over and thought maybe it was corrupt file, too big of a course or file, etc. I looked in my moodledata folder [see path below] Commentand found a file named with a random string of characters – which was the same string that was displayed in the “incorrect pool file content” error.

moodledata path

There were two other files with a long string of characters that were the same as two long strings of characters which were being displayed in the debugging information (these strings were successful operations). The two files weren’t big, the problem hash named file however was 500 MB. Was this the problem? I didn’t dare change anything via the moodledata folder.

I figured it was a file issue in one or more courses..I went into phpMyAdmin and started deleting courses, hoping a corrupt file would be removed and fix the issue. I had 3 imported courses from our production server that I restored on the 1.9 testing server to test “real life” courses in the upgrade process.

I deleted two of the four courses, same error.  Went back and deleted another course. Tried again, boom – worked. Since I had all of the debugging and information set to display it displayed all of the database stuff. Clicked Continue. It displayed tons of new settings, clicked Continue – MOODLE 2.0!

Success! Sort of..well..half way…I was able to upgrade from a 1.9.11 to 2.0.2 but I had to delete a few courses first. I believe I had to delete the courses that I imported from our production server (v 1.9.9). Only one course made it through, which I initially created on that install.

roll back

So it looks like the course migration is the issue – something with the files (doesn’t surprise me). I’m going to roll back to 1.9 and import different courses, create a few more courses and try again. I’ll post my results after I try it out again.

 

Related Posts

Video – Converting Moodle Database from MyISAM to INNODB @mguhlin

Posted on April 13th, 2011 in Administration, how-to, Information, Moodle 2.0 | No Comments »

In my post yesterday I talked about converting my Moodle database from MyISAM to INNODB before upgrading to Moodle 2.0. I used Miguel Guhlin’s directions, double checked with him via twitter and it was pretty easy. He’s made it even easier by doing the process in a few videos.

Check out his blog post for the videos : )

magic

Another updatePart 2 of my “Second attempt at upgrading from 1.9 to 2.0” is coming soon. I actually had some success and was able to upgrade (with some tweaks).I’ve got the post written up about my experience. I just have to finalize and add some images. It will most likely be up tomorrow.

Second attempt at upgrading 1.9 to 2.0

Posted on April 12th, 2011 in Administration, Information, Moodle 2.0 | 5 Comments »

Today was my second attempt at upgrading Moodle 1.9 to Moodle 2.0. The first time I ran into a few problems and tried to solve them but then scrapped the install and left it for a few months. This time I upgraded from an install of Moodle 1.9.11 with the Book module installed and a few “real life” courses I imported, to see how they upgraded.

One major thing I did this time that I didn’t do last time was migrate my database from MyISAM to INNODB. I followed the directions from Miguel Guhlin (complete with Databasescreenshots). So, I really don’t know what this does but it sounds like this is necessary? However, I haven’t seen it documented in Moodle Docs (please provide a link if it’s there!).

I do know that in a fresh 2.0 install it does create the database with the “INNODB” type (you can view it in phpmyadmin, it will be in a column when viewing the database). Needless to say, I want to become more comfortable with what this is doing before I do anything on a production server. The good news is that following Miguel’s directions was easy.

Alright, here is the short run down of what I did:

1.) Exported my database via phpMyAdmin (saved on my desktop)Maps

2.) Migrated my database from MyISAM to INNODB – DIRECTIONS

3.) Made a copy of my moodledata folder (used Fire FTP Firefox add-on for steps 2-7)

4.) Copied the config.php file from my current 1.9 install

5.) Renamed my web files Moodle folder to moodle1910.backup

6.) Uploaded a fresh copy of Moodle 2.0 (named the same as the old Moodle folder in step 5)

7.) Copied the config.php file into the new Moodle folder uploaded in step 6

8.) Visited my Moodle install, Clicked on Notifications

 

Next

Result after clicking on Notifications

1.) Yippee, I’m doing it! -> screenshot 1

2.) Server checks, CHECK! Yay! -> screenshot 2

3.) Plugin Checks, eh..okay..a few non-standard ones but allows me to continue -> screenshot 3 | screenshot 4

4.) Then I ran into a problem [screenshot of where I'm stuck]. A progress bar (at 0%) is displayed for 3-7 seconds and then a red-highlighted box saying “Incorrect pool file content 17f65e7276dd4895c5fc8970e2aa834622a3696b.” is displayed. I’m also given the following error:

error

And that’s where I stand now. A weird thing happened as I was writing this  blog post – my computer froze up on me and I restarted. When I came back and restored my tabs in Firefox, the screen I was stuck on that had a progress bar at 0% now has a progress bar at 33.3%. Weird?

I haven’t fully looked into what is causing the “incorrect pool file content” or the other errors but here are a few links I quickly found:

I plan to further investigate about the above problem, it seems like there have been some discussion about the errors so I’m confident I’ll figure it out soon.

 

Minor issue/curious

The other thing I am wondering about is why there are standard (I thought) modules that say they are missing. I know Book is non-standard and I think hotpot, journal, lams and loan calculator are no longer in the core install but what about admin and admin_tree? Is this causing problems?
plugins

plugins

 

Like I said, this is my second attempt at upgrading and I haven’t spent too much time preparing or investigating the upgrade progress so I’m not too frustrated yet. I’ve been in the mode of waiting until more and more bugs get fixed and I keep checking the Moodle Tracker.

Line ChartOriginally our district was going to upgrade in the summer after 2.1 is released but we may push that back so we can implement a solid pilot group and create quality training resources.

I was upgrading on a CentOS VPS using cPanel, Fire FTP and phpMyAdmin. I’ll update this post with any updates on the error I received. Any insight into these errors would be greatly appreciated.

Extending the Moodle Database Activity with CSS, templates & HTML

Posted on December 17th, 2010 in Modules, Tips | 4 Comments »

I was recently given the task in my district to develop a solution for a searchable forms database on our new web site. These forms include staff forms for HR, district permission slips,art box enrollment forms, etc. We just migrated our site to a paid for service which included many features except a way to store, search and display forms (files).

I decided to use a Database Activity in Moodle. A few obstacles I initially saw:

  • Integrate the activity into the district site seamlessly
  • Integrate the look into the district site
  • Customizing the display
  • Meeting the district’s needs of menus, filters and search

Integrate the activity into the district site seemlesslycheck mark

A simple solution for this, although I don’t particularly enjoy using them, was to use an iframe on our district web site. I only had a WYSIWYG Editor to use that allowed HTML. Clicking a link on the district site which opened a link in Moodle wasn’t an option. It needed to be embedded within the web site and not be noticeable that it’s using another product or site. So, iframe it was.

Integrate the look into the district site check mark

The biggest issue was the header and footer in Moodle. I was able to remove all of this using the CSS template in the Database Activity. With much help from Mary Evans in the Moodle Forums on Moodle.org I used Firebug to accomplish hiding the header, breadcrumb navigation, description box and footer.

Below is the screenshot pointing out each section and below that is the code corresponding to each section in the screenshot.

screenshot

/*Hide header, banner*/
#mod-data-view #header { display: none;}
#mod-data-view #banner { display: none;}

/*Hide breadcrumb navigation*/
#mod-data-view #page .navbar { display: none;}

/*Hide description box*/
#mod-data-view #intro {display:none; padding-top:0px;}

/*Hide footer*/
#mod-data-view #footer { display: none;}
#mod-data-view .paging {margin: 0px;}

Customizing the display check mark

I lucked out in that the theme I picked, Leatherbound, matched most of the colors for our district site. Now, I wanted to add in some highlighting and shadowing. I lucked out again that Moodle.org has documentation on “How can I add highlighting like on the Modules and plugins page?“. I modified it a bit and put it in my CSS template.

Meeting the district’s needs of menus, filters and search check markdrop down menu

Finally, I needed to add in some drop down menus to departments and buildings. I got tons of help again, from the Moodle.org forums. Itamar Tzadok helped me out in several Database Activity Forum threads.

I put that HTML in the “List” template. I was able to get direct links to each “field” by manually searching for that field and copying and pasting it as a link. ‘Department’ and ‘Building’ were fields, so I was able to search (filter) and get the link.

After a lot of testing and troubleshooting here is the final product (you can see the Moodle Database Activity bordered in black)

final product

You can see it live by going to http://bloomington.k12.mn.us click on “Quicklinks” in the top right, then click on “Forms A-Z“.

More helpful links

Phew, time for a treat! Moodle to the rescue!

cupcake

Turning off Autosubscribe default in Forums

Posted on February 18th, 2009 in Features, Ideas, Information, Tips | 1 Comment »

Fresh out of the box Moodle sets each user’s default setting Forum Auto-subscribe: as Yes: when I post, subscribe me to that forum.

autosubscribe

This can be changed by the user when they edit their profile. However, I have found out that many users do not know how to change this, that it can be changed or they forgot to change it. I’ve gotten several questions from teachers wondering why they are getting these strange e-mails from Moodle telling them that Sue Johnson has posted in a Forum in the Moodle Training course they were in months ago!

Now, we tell our staff in the training to change this setting in their profile but I think it would be much easier to make this feature an “opt-in” instead of an “opt-out”. There has been a lot of discussion about this issue and Martin Dougiamas explains that it basically encourages interaction. In my opinion, having this feature be an “opt-in” situation works best for our district. Teachers get enough e-mail and it will more than likely just annoy or frustrate them if they don’t know why they’re getting all of the e-mails or how to stop them from coming in. If a user wants to really follow a Forum they will take the time to click that option when they post.

Another problem with Subscribing to a Forum is that sometimes I want to follow just a post in a Forum, not the entire Forum! I think there should be a “Subscribe to Thread” option, like many of the Forums on the web.

Anyways, while searching the web and the Moodle.org Forums I found an answer to setting the Auto-subscribe setting default to be “No: don’t automatically me to forums” for new users and a way to change that setting for users already in the system:

If you have access to your database through phpmyadmin, then just do the following.

1. Select the mdl_user table
2. Click on the pencil (to edit) beside autosubscribe
3. Change the default value from 1 to 0

The above will change the default value for all new accounts.

1. Select the mdl_user table
2. At the top, click on SQL
3. Erase what is in the query field and enter the following:

UPDATE mdl_user SET autosubscribe = 0

4. Press “Go”

This will change all existing accounts to “No: don’t automatically subscribe me to forums”.

Note: It’s always a good idea to back up your database before doing anything like this. Use at you own risk

Source: http://moodle.org/mod/forum/discuss.php?d=94386

I do not have the rights to phpmyadmin for our Moodle site but I was able tell our network person how to do this and it was done. It seemed to have worked but as we continue trainings some teachers are still getting the “Yes” option. I am currently waiting to try it again with our network person to check out the problem. Although, I am having problems with it working 100% all of my research has pointed to the above solution. Any information about this issue would be greatly appreciated! I may be missing another setting I need to cahnge. Any opinions or information on this?