Moodle H5P Plugin Upgrade


It seems that something's wrong with upgrading H5P in Moodle.

I cannot get my H5P plugin updated. I'm always forced to uninstall and reinstall.

As I am not an expert user of Moodle, it will be my fault most probably. It is so or H5P cannot be upgraded in Moodle?

I am using Moodle 2.8.12 (Build: 20160509)

fnoks's picture

It is possible do upgrade the H5P plugin. Could you please describe what kind of problems you see when trying to upgrade. Do you get any error-messages?

Thank you for your answer.

As I said before, I am quite a newbie in Moodle, so I may be doing something wrong on my local test installation.

It happens that there were a new release in, but I didn't have any notification for updating the plugin in my Moodle. So I tried downloading the new realease package and installing it while the old version was still installed. Then I got the error that says that the extension was already installed.

Most probably due to my ignorance, I had to uninstall the old version and reinstall the new one, which drove me to loose all the activities that I had done (which was not a big loose beacause I made everything just to evalueate H5P).

So my post was to try to see if my problem was an issue or it was just me doing it wrong, as I couldn't find anything related to the point in Google.

This happened when trying to update to January 2017 release from the previous one.

I cannot attach any log information.

fnoks's picture


I few follow-up questions for you:

  1. Which version of the H5P-plugin do you currently have on your system?
  2. Do you get notifications when other plugins are updated?
  3. Do you have access to the file system for the Moodle backend?


I'll try to answer your questions:

1. 2017010900  - 1.0-rc.6 (As it appears in Moodle)

2. I don't have any other plugin installed. My Moodle is a bare bone installation in my local machine. It runs over a Wampserver64 that starts when my machine starts up

3. Yes I do. As I've got it installed in my local machine...

fnoks, I really apreciate your interest, but I woudn't like to make anyone to spent too much time on this. As you can see, my system is very particular, just built up for evaluation purposes and that might be the reason why it works in such a bizarre way.

Anyway, thank you again.

icc's picture

It seems you have the latest plugin. However, you might need to update your content types. The process for doing this is described in detail here: Update/install all recommended content types.


Updating the library is not the problem. I had the problem when I updated the plugin to versión 2017010900  - 1.0-rc.6 from rc.5.

fnoks's picture

So, that means you uninstalled rc5 and installed rc6? On the next update, you could try to just copy in the new version of the plugin (located in moodle's mods/hvp directory)


I'm having the same problem. 

If I try to upload the new plugin I am told that it already exists. If I try and install from the Plugins Database, Moodle tells me the plugin is already installed.

However if I try and upload the Library, it tells me that I am using an old version of the plugin (1.1) and need 1.2. So I'm stuck - and don't know what to do!

We are using Moodle 2.8.7 (Build: 20150706)

Hope you can help.

icc's picture

I'm sorry to hear this. I've tried reproducing the issue without any luck. To get the plugin updated you could always to this "manually" by downloading the zip file for the plugin, extracting it and then replace the existing mod/hvp folder with the one from the zip file. 

That should work.


Similar issues here,   am unable to upgrade currently.

Currently on  1.0-rc.3

Either from directory or H5P download

Install plugins from the Moodle plugins directory

There is a request to install plugin Interactive Content – H5P (mod_hvp) version 2017010900 from the Moodle plugins directory on this site. However, this plugin is already installed on the site.


 Install plugin from ZIP file


The plugin ZIP package must contain just one directory, named to match the plugin name. The file provided is not a valid plugin ZIP package.


ignore this,

I have used the zip file from the moodle directory, not the file downloaded from H5P, and its worked via the 'install plugin from zip file'



tim's picture

Glad you got it working. 

We're still having issues I'm afraid!

I've downloaded the plugin from Moodle Database and upload manually. Validation fails as it says the 'Target location already exists':


Really not sure what to do!



icc's picture

You would have to delete the mod/hvp folder manually and then upload the hvp folder that came out of the zip file.

OK Thanks.

Will this delete any existing H5P activies already in a course?

icc's picture

No, it will only update the code. If this is a production site I would set it in maintenance mode first to avoid users while the plugin is gone.

Thank you!

That's ok for the code but what would happen if the database changes?

icc's picture

The database upgrade will run the first time you visit the site afterwards.


Yes it works as you said. But I'm not sure that this two steps procedure is the best way to make the update.

icc's picture

No, it's more of a manual way of doing it. Not sure why the automated way of doing this stopped working for you.
Maybe this will work itself out once we get out of the RC versioning.

Although I was able to manually upload with several problems this time, this issue has been happening since rc5. It also appears that some partial updates occasionally take place - if the arrows turn green on the h5p Libraries page. However the php version does not update, neither in Moodle nor in the appropriate .php file. Using moodle 3.1. 

I just updated h5pon my dev server which is also on my site but in moodle 3.2. I was able to update rc8 activities with the green arrows but the plugins overview page still shows rc6 and the h5p.classes.php reads

public static $coreApi = array( 'majorVersion' => 1, 'minorVersion' => 12
icc's picture

I'm sorry, but I'm not really following you. What are you uploading?

Be aware that you must first upgrade the plugin to the latest version(rc.8 at the time). If this goes without any error messages you can then try to upgrade the content types through the H5P Libraries page. 

Hi, let me just walk you through the last few upgrades, it may be clearer.

 Neither work well on my systems, on 3.1 and 3.2. I added the plugin when it first came out to a new 3.1 moodle installation.


 To upgrade the plugin to the latest version and click any arrows to pgrade specific libraries, I go to the h5p Libraries page on my moodle site and if I recall, there used to be Moodle notifications as well.  I upload the .h5p file at the bottom of the instructions page on your website, and go through steps 4-7:

  1. Log in to your Moodle site
  2. Go to Site administration > Plugins > Activity modules > H5P > H5P Libraries
  3. Upload the H5P file you downloaded in #3
  4. Click the "Upload" button, and all libraries will be updated to the latest version


 With rc5 I had an error message about a problem with the libraries. I followed advice on the forum, unzipped the plugin to the moodle/mod folder from the cp and rc6 was successfully installed. This was reflected on the Moodle plugins page which features the version as well as in the h5p.view.php document lines 1670 or so.


Since then, there have been no error messages and I continued upgrading and using h5p. I recall clicking the green arrows in one of the upgrades before March.


 In March, I upgraded and never had to click any arrows. As I was able to make a new version of the memory game, I did not think twice about the upgrade. But then, importing a course with h5p failed. So to double-checked my upgrade, I checked the rc version, found it was still on rc6 (!) despite several upgrades that seemed to go ok, and the .php file that indicated I was on version 1-11 (rc7 no?). I uploaded the .h5p file on Moodle and clicked the upgrade button. The file was uploaded but then nothing happened and Moodle did not indicate there was a new version of the plugin.


 So, I downloaded the most recent h5p libraries and unzipped these in mod/hvp in the cp. Moodle recognizes rc8 and the h5p.view.php reads 1-12.


I hope that is clearer? Thanks.


icc's picture

I'm sorry, it's difficult to follow the procedure you're describing to reproduce the issue. You should never have to unpack any h5p libraries – where did you get them?

To upgrade the plugin manually you should do the following:

  1. Put your site in maintenance mode.
  2. Take a backup of your site's database and files.
  3. Delete the old mod/hvp/ plugin folder. (and do not visit your site while the filesystem and database isn't in sync)
  4. Download and unpack the new hvp plugin folder from
  5. Visit your sites admin notification area and run any updates.
  6. Verify that the new version of the plugin is correct within Moodle.
  7. Just to be on the safe side, check for any recent messages in your web server's error_log.

When you're sure that you're running the latest plugin it's time to update your content types and upgrade any old content through the H5P Libraries page.

Did you follow these steps when upgrading?


I followed upgrade instructions on 


  1. If you get update notifications, follow the on screen instructions to upgrade, if not, do the steps mentioned below. 
  2. Make sure you are using the latest H5P module for Moodle
  3. Download the H5P file at the bottom of this page (h5p file or so the link says)
  4. Log in to your Moodle site
  5. Go to Site administration > Plugins > Activity modules > H5P > H5P Libraries
  6. Upload the H5P file you downloaded in #3 (file from here did not work on my installation; I also tried the ZIP version from it did not work)
  7. Click the "Upload" button, and all libraries will be updated to the latest version 

Then, in the cp, I renamed hvp to hvprc6 and deleted the hvp folder. I unzipped the latest release from the Moodle website under /mod/hvp, went back to moodle where I followed instructions regarding h5p. As of now, this is the only way to make sure the upgrade is complete on my website.

icc's picture

Ok, so then you're running the rc8 version of the plugin and everything is working?

I wanted to confirm as did the user who opened the thread that there has been an upgrading problem for several versions on some systems. This does not stop me from using h5p as I manage through the cp and am on rc8 now.

By teh way, are we supposed to use the zip or the .h5p file under the instructions on this website, or either is ok (but different procedures)? Thanks.

icc's picture

Ah, ok! I think this may be related to the maturity level(RC) and it should be straightened out when releasing 1.0.

For the content types, it should always be a .h5p file. Where is the .zip file being referred to? 

I was referring to the Moodle plugin format to unzip under the cp. However, I now understand how the h5p upgrades are done via the libraries. Funny how Moodle does not recognize libraries being out of date or updated.

icc's picture

Ah, I see.

By default in Moodle, you don't get update notifications unless the plugin version is marked as 'stable'. You can change this under Admin -> Server -> Update notifications, where there's an option 'Required code maturity'. 

Thanks, I've now checked the box.