Quantcast
Channel: Installing and upgrading help
Viewing all 47502 articles
Browse latest View live

Re: Looking for some assistance

$
0
0
by Tom Connolly.  

Done - thanks!

Re: Exception - Call to member function Moodle 3.7

$
0
0
by Mark Terranova.  

I am also receiving the error message "Exception - Call to a member function instance_copy() on boolean" on Moodle 3.5.5. However when I turned on debugging I am getting the error below with a little more information and the attached error message.


Exception - Call to a member function instance_copy() on boolean


More information about this error


Debug info: 

Error code: generalexceptionmessage

Stack trace:

line 95 of /my/lib.php: Error thrown

line 127 of /my/index.php: call to my_copy_page()

Re: Looking for some assistance

$
0
0
by Marcus Green.  

You might get it installed in less than 2 hours, but configuring it and installing some plugins will add to that estimate. Most Moodle installs use some plugins, even MoodleCloud from Moodle HQ use 5 plugins.

Re: After upgrading from 3.5.1 to 3.7.1 cron is not working

$
0
0
by Leon Stringer.  

The error is saying that the database INSERT statement is inserting a different number of values to the number of columns but the INSERT statement is explicitly stating 10 columns and 10 values.

Is that the full error message? The tenth column (i.e. index 9 in the array) should terminate with a single quote (').

Check the Environment report and see if there are any warnings or errors.

Is the PHP version that cron.php is being run with the expected version? It's possible that there are two different versions installed with different settings. For the command you are using for cron, run php with --version to check this.

Check MariaDB's log to see if that reports anything that coincides with these issues. On my system this is in /var/log/mariadb/mariadb.log but it may be somewhere else on yours.

If there's a time when the site is quiet, preferably with no one using it, you could use MySQL general logging to see the exact INSERT statement and response from MariaDB. You can then try that statement manually as a test. Because there are 10 columns and 10 values this error shouldn't occur and this may help identify the problem.

I think the collation utf8mb4_unicode_ci is recommended regardless of the language is use.

Re: After upgrading from 3.5.1 to 3.7.1 cron is not working

$
0
0
by Ken Task.  

Could be several things ...

In config.php db array do you have a line for collation that matches what was done do DB: utf8mb4_slovenian_ci?

Is character set for all tables utf8mb4?   Another script in moodlecode/admin/cli will help with that to get DB fully compliant ... but that also requires Baracuda rather than Antelope.   Setting in my.cnf?

Have found it's always more problematic ... or has potential for problems if upgrading PHP/MySQL at the same time.  The release notes on highest may/maynot be tested with all possible combo's:

https://docs.moodle.org/dev/Moodle_3.7_release_notes#Database_requirements

as example does show mariadB 5.5.x as minimal but has for 'recommended' as 'latest' -

Here: https://downloads.mariadb.org/mariadb/repositories/#mirror=accretive&distro=Debian&distro_release=stretch--stretch

I don't see a 15.1 of MariaDB?????

3.7.1 has some major changes to theme ... only 'boost' and a new one callled 'classic' are 100% compat.   Thus manually removing contents of moodledata/cache/ is a good next move.

When you say cron kicks out different errors ... not all the same every time ... mind providing a list?

Running from command line should/would kick out the same errors me thinks .. you might have to run it via command line several times to get some not so often scheduled task to kick in.

'SoS', Ken


Re: After upgrading from 3.5.1 to 3.7.1 cron is not working

$
0
0
by Erik Frangež.  

Hi Ken and Leon,

Before upgrading we have PHP version 7.0, now we have upgraded, delete PHP7.0 and install PHP7.3. We did not upgrade MariaDB, its same version like before:
mysql --version
mysql Ver 15.1 Distrib 10.1.38-MariaDB, for debian-linux-gnu (x86_64) using readline 5.2

php -v
PHP 7.3.7-1+0~20190710.40+debian9~1.gbp032aec (cli) (built: Jul 10 2019 07:38:52) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.3.7, Copyright (c) 1998-2018 Zend Technologies
with Zend OPcache v7.3.7-1+0~20190710.40+debian9~1.gbp032aec, Copyright (c) 1999-2018, by Zend Technologies

Right now I have deleted content in /var/www/moodledata/cache, situation is same (I have copy/paste content below, its not easy readable but you will see 86400 number, which tell us that cron is not doing his job. If we run "clean" from GUI it works and cleans particular job!!!):

Log table cleanup \logstore_standard\task\cleanup_task Standard log Never
Run now
torek, 23 julij 2019, 3:05 22 4 * * * 86400
Clear
Yes
LTI Assignment and Grade Services table cleanup \ltiservice_gradebookservices\task\cleanup_task LTI Assignment and Grade Services Never
Run now
torek, 23 julij 2019, 10:40 0 0 * * * 86400
Clear
Yes
Messages digest mailings \message_email\task\send_email_task Email Never
Run now
torek, 23 julij 2019, 8:40 0 22 * * * 86400
Clear
Yes
Background processing for assignment module \mod_assign\task\cron_task Assignment petek, 19 julij 2019, 8:02
Run now
ponedeljek, 22 julij 2019, 9:10 * * * * * 86400
Clear
Yes
Check for attendance sessions that require auto marking \mod_attendance\task\auto_mark Attendance Never
Run now
ponedeljek, 22 julij 2019, 8:50 8 * * * * 86400
Clear
Yes
Send warnings to users \mod_attendance\task\notify Attendance Never
Run now
torek, 23 julij 2019, 12:10 30 1 * * * 86400
Clear
Yes
Background processing for chat module \mod_chat\task\cron_task Chat Never
Run now
ponedeljek, 22 julij 2019, 8:55 */5 * * * * 86400
Clear
Yes



About errors when we running cron job from CLI:
Sometimes they are and sometimes we get normally executed job (but in GUI shows 86400):
php /var/www/moodle/admin/cli/cron.php
Server Time: Mon, 22 Jul 2019 19:36:48 +0200


Execute scheduled task: Predvidi modele (tool_analytics\task\predict_models)
... started 19:36:48. Current memory use 18.6MB.
Za predvidevanje ni na voljo nobenega omogočenega in priučenega modela.
... used 1 dbqueries
... used 0.0052239894866943 seconds
Scheduled task complete: Predvidi modele (tool_analytics\task\predict_models)
Cron script completed correctly
Cron completed at 19:36:48. Memory used 19.2MB.
Execution took 0.080951 seconds

We running cron every 5min and time to time we get this:
Default exception handler: Odkrita napaka v kodi, odpravi jo lahko programer: A lock was created but not released at:
[dirroot]/lib/cronlib.php on line 99

Code should look like:

$factory = \core\lock\lock_config::get_lock_factory('type');
$lock = $factory->get_lock(Resource id #565);
$lock->release(); // Locks must ALWAYS be released like this.

Debug:
Error code: codingerror
* line 117 of /lib/classes/lock/lock.php: coding_exception thrown
* line 114 of /lib/cronlib.php: call to core\lock\lock->__destruct()
* line 73 of /lib/cronlib.php: call to cron_run_scheduled_tasks()
* line 61 of /admin/cli/cron.php: call to cron_run()

I hope I have explain well problem.

Erik

Re: How to intergrate moodle with a pulic facing web hosting service like bluehost

$
0
0
by Kan Abhulimen.  

Thanks, so basically the position of the moodle file dictates the url look.

Working with moodle theme

$
0
0
by Kan Abhulimen.  

I have a moodle 3.7 theme which covers the website index page. Is it possible to make the theme appear as www.websitename.com then when you click on login it switches to a subdomain like mylms.websitename.com, all this with the same theme?


Re: How to intergrate moodle with a pulic facing web hosting service like bluehost

$
0
0
by Howard Miller.  

I'm not sure I understand your question but I'm pretty sure it's nothing to do with the theme.

The URL that your Moodle ends up as is a function of whatever domain name you buy, whatever hostname you add in DNS and then how your web server software is configured.

Re: Working with moodle theme

Re: After upgrading from 3.5.1 to 3.7.1 cron is not working

$
0
0
by Howard Miller.  

What Leon says... that insert statement isn't valid.

Which is very odd.

Next step is to turn up Debugging to full and get a better trace so that we know exactly where this is happening in the Moodle code.

Re: After upgrading from 3.5.1 to 3.7.1 cron is not working

$
0
0
by Ken Task.  

For next time ... 10.1.38-MariaDB is version of server.

Biggy:
Log table cleanup \logstore_standard\task\cleanup_task Standard log Never

Shows never????

That table is normally the largest in the DB!!!!

cd path/to/moodlecode/admin/tool/task/cli/

Run:
php schedule_task.php --execute="\logstore_standard\task\cleanup_task"

and let's see what it does/says.

Locks ... in /moodledata/locks/ are like indicators of the status of a cron job/task ... error shown is cannot release a lock ... ie, remove it ... probably from moodledata/locks/

Make sure your moodledata/locks directory has very liberal permissions so that if running cron job as root or whatever user apache runs under in your distro can read/write ... create/destroy.

Also, run from command line ... cron.php

Not just once but multiple ... running cron every 5 minutes may not be frequent enough.  Recommendation these days is once every minute, me thinks!

cd /path/to/moodlecode/admin/cli/

php cron.php [ENTER]

Wait 30 seconds or so ... 'up arrow' then enter again.

Do that several times ... when one of those task/adhoc task kick in you'll see it ... and it will also report errors if there are any.

Fingers crossed! smile

'SoS', Ken



Re: Looking for some assistance

$
0
0
by Tom Connolly.  

I have done Moodle installations before with plugins in Moodle...I can deal with that myself...it is the other stuff that I want done. I don't want to have to go through that learning curve. I have too many other things on my plate now.

Re: Looking for some assistance

$
0
0
by James Steerpike.  

Before installing Moodle, how many students do you have, how important is your site, and what is your budget?
At one extreme you have a site with thousands of fee paying students and where a failure could nearly wreck your school. That requires a Moodle Partner level of skill and commitment,
For a single class Moodlecloud is the best option. It can get more expensive if you have several hundred students but installing Moodle ALWAYS costs - in money or time.
In between these, I suggest installing yourself. You have Ubuntu and updating and installing a LAMP stack is well documented. From there follow the Ubuntu step by step guide. Any questions post here.
Most problems people have here is because they try to install on a home computer running Windows or a Mac. Sticking to a clean Linux server as you have done eliminates many problems.



Re: Installing Moodle 3.7.1 on GoDaddy

$
0
0
by James Steerpike.  

Any reason you went for a Windows VPS? The Linux install is more common.

Re: After upgrading from 3.5.1 to 3.7.1 cron is not working

$
0
0
by Erik Frangež.  

Hi Ken and Howard,

In Moodle we have enabled Debugging level for developers.

I have run command to execute scheduled task for cleanup logstore standard:
root@polh:/var/www/moodle/admin/tool/task/cli# php schedule_task.php --execute="\logstore_standard\task\cleanup_task"
Execute scheduled task: Čiščenje tabele dnevnikov (logstore_standard\task\cleanup_task)
Deleted old log records from standard store.
... used 3 dbqueries
... used 0,042447090148926 seconds
Scheduled task complete: Čiščenje tabele dnevnikov (logstore_standard\task\cleanup_task)
... used 4 dbqueries
... used 0,046233177185059 seconds
Scheduled task failed: Čiščenje tabele dnevnikov (logstore_standard\task\cleanup_task),Napaka pri pisanju v podatkovno bazo
Debug info:
Column count doesn't match value count at row 1
INSERT INTO mdl_task_log (type,component,classname,userid,timestart,timeend,dbreads,dbwrites,result,output) VALUES(?,?,?,?,?,?,?,?,?,?)
[array (
0 => 0,
1 => 'logstore_standard',
2 => 'logstore_standard\\task\\cleanup_task',
3 => 0,
4 => 1563856022.3714321,
5 => 1563856022.4131601,
6 => 2,
7 => 1,
8 => 0,
9 => 'Execute scheduled task: Čiščenje tabele dnevnikov (logstore_standard\\task\\cleanup_task)
Deleted old log records from standard store.
... used 3 dbqueries
... used 0,042447090148926 seconds
Scheduled task complete: Čiščenje tabele dnevnikov (logstore_standard\\task\\cleanup_task)
',
)]
Backtrace:
* line 1329 of /lib/dml/mysqli_native_moodle_database.php: call to moodle_database->query_end()
* line 1375 of /lib/dml/mysqli_native_moodle_database.php: call to mysqli_native_moodle_database->insert_record_raw()
* line 84 of /lib/classes/task/database_logger.php: call to mysqli_native_moodle_database->insert_record()
* line 299 of /lib/classes/task/logmanager.php: call to core\task\database_logger::store_log_for_task()
* line 718 of /lib/classes/task/manager.php: call to core\task\logmanager::finalise_log()
* line 163 of /admin/tool/task/cli/schedule_task.php: call to core\task\manager::scheduled_task_complete()

I see that INSERT statement is not closed at row 9. How can I fix this? or is it normal?

Thank you!

Regards,
Erik

moodle upgrade docs are stupid and broken

$
0
0
by todd lehman.  

so, in order to upgrade my existing moodle instance i must:

1) copy the entire webroot to a new backup folder.

2) deploy some new zip archive to replace the entire webroot, and then copy back the moodledata dir.

3) figure out what plugins or modules need special attention, because the update process is unable to apprise me of them.

4) the docs assume that I have deployed moodle at some  "/moodle" dir, instead of the root of the webhost.


In all honesty, I would be better off deploying and entirely new moodle instance and trying to import students, courses, assignments, submissions, etc...


Moodle doesn't really have an " upgrade" or "update" functionality.

Moodle has some really nice features, and can use external DB data to create courses, students, professors, etc..


But your upgrade docs, considering that the latest version is only 2 months old, REALLY SUCK.

give me an archive that I can deploy in-place, and quit acting like you are some high-end LMS, you are NOT.


if you care to disagree with me, or maybe I am just dumb and can't find the correct docs, PLEASE, and I mean PLEASE, tell me what I am doing wrong.

tplehman@gmail.com

Re: moodle upgrade docs are stupid and broken

$
0
0
by Howard Miller.  

Well, I'm crying.

If I can be perfectly honest with you, telling people that their documentation "REALLY SUCKS" is pretty childish and will get you the attention that probably won't surprise you.

You are correct about the upgrade procedure. Yes, it could be better but Moodle is a very large, complicated application and it's rarely straightforward to upgrade between major versions due to all the non-core additions that may have been used. It's not Wordpress. Personally, I'm not a fan of these "one click" upgraders. This way gives you a push towards doing proper testing.

If you want to help, the docs are a Wiki and anybody can improve them. If you want to write or sponsor some nice upgrader for Moodle then that would be fabulous wink

Re: moodle upgrade docs are stupid and broken

$
0
0
by todd lehman.  

fair enough, you actually listened to my childishi temper-tantrum, and didn't just write me off respect sir.

Re: How to intergrate moodle with a pulic facing web hosting service like bluehost

$
0
0
by Rick Jerz.  

To some extent. However, I believe that one can use subdomains to provide Moodle a "first" position, even though it may not be in the first position on your server. (Others here might qualify my response.)

So, let's see:

A folder like www could appear as https://yourdomain.com
Then, www/moodle could appear as https://yourdomain.com/moodle
Then, www/apps/moodle could appear as https://yourdomain.com/apps/moodle

If you subdomain the last (let's say "mymoodle") then
www/apps/moodle could appear as https://mymoodle.com
Viewing all 47502 articles
Browse latest View live


Latest Images