Re: It is possible that the database is overloaded or otherwise not running properly
Seriously, you people are insulting Unix. Unix is not Windows (where you reboot or even reinstall since you don't know what is happening inside).
Get to the root cause of the problem! If BigBlueButton is the culprit, report in the "Web conferencing plugins" forum: https://moodle.org/mod/forum/view.php?f=1114.
Re: It is possible that the database is overloaded or otherwise not running properly
Been running Moodle successfully for nine years w/o incident. Yesterday got same config.php error shown above. Accessed server and noticed we were out of space. Had some old back-up versions, in www folder. Moodle2.2, Moodle.Test etc. Deleted a couple directories and piked up 8gb of space. Server rebooted w/o incident and we were back up and running. By end of day we had run out space and error has returned. We only have a small amount of users at this time. Suggestions? Thinking a file may be duplicating versus caching and resetting? Currently on 2.6
Re: It is possible that the database is overloaded or otherwise not running properly
@Ray
About the only thing that comes to mind is automated backups. If on, turn to either manual or off.
This gets to be kinda tricky if one cannot get to the admin interface of the site and the automated backups were saved to the default area which is that sea of hashed files in moodledata/filedir/
Need to free up enough space to be able to login ... so with whatever you have to browse files on the server, you need to manually remove the files/folders in the following areas:
moodledata/sessions/ - those are small files and won't gain much space but they are created upon login
moodledata/trashdir/ - all the contents
moodledata/temp/backup/ - this is the area used by moodle to build backups and can be manually removed without any issues.
Hopefully, that will free up enough space so you can login as admin user and disable autobackups.
Then the next step ... go into courses ... hit restore link ... you are not going to restore any course, just trying to get to some Moodle screen that would allow you to remove automated backup files.
Suggest keeping one backup ... but definitely download the most recent backup of the course.
Hopefully, the above will give you a place to start!
'spirit of sharing', Ken
Re: It is possible that the database is overloaded or otherwise not running properly
Thank you for the quick response @Ken, missed the email notification. We can access the server via Linux, deleted some OLD Moodle versions/copies, moodledata25, moodle-oldd but server still returns no-space and cannot open site.
moodledata/sessions/ - no folder (Filezilla Screenshot below)
moodledata/trashdir/ - is empty
moodledata/temp/backup/ shows like 8 files 0 file size
Back-up folder structure...
Re: It is possible that the database is overloaded or otherwise not running properly
In the active moodle sites there is a config.php file that has a variable for the data directory for the site.
Check those. Make note of what directories.
Any moodledata directory you have that is NOT an active data directory found in those config.php files it is assumed to be safe to remove. From your screen shot, doesn't look like any of those are symlinked ...
There should be only one data directory per site. The largest you will find any any data directory is filedir (normally) and it's also the most important of all directories in moodledata. So before erasing check/double check. Also, does your hosting service have a full site backup service? Think I'd ask about that before removing cause you don't have room to make any local backups of active site.
See there is also a moodlecronlog directory - output of cron jobs not really that large so also assume the contents (just the contents) could be removed.
'spirit of sharing', Ken
Re: It is possible that the database is overloaded or otherwise not running properly
Well now we went and did it
We deleted some of the old install/folder versions oldd, 2,2, etc Was able to get into site long enough to put site in maintenance mode. verified backup was disabled. We had an Avamar backup running, deleted it. But when trying to access /admin
Coding error detected, it must be fixed by a programmer: moodle_database::update_record_raw() id field must be specified.
Waiting on our former support member to assist... anyone looking for some side work
Re: It is possible that the database is overloaded or otherwise not running properly
That specific error related to DB.
Please verify ... the config.php file pointed to a datadirectory/path that still remains on the server. Correct?
When one first logs onto a Moodle, the DB still records a session info in DB even though it might be using files for sessions found in moodledata/sessions/
On a typical CentOS box, the partition that contains the databases in in /var/lib/mysql
All files/folders in that directory should belong to the mysql user and group. Ant they shoud be readable/writeable/excuatable by the mysql user only. Please verify:
As root user:
cd /var/lib/mysql/
ls -l
in the listing, look for the DB for your Moodle ... here's an example of a moodle27
drwx------ 2 mysql mysql 20480 Sep 14 19:58 moodle27
if one changes into the directory and list all files one should see something like:
-rw-rw---- 1 mysql mysql 27082 Sep 14 19:58 mdl_user.frm
Re: It is possible that the database is overloaded or otherwise not running properly
Coding error detected, it must be fixed by a programmer: moodle_database::update_record_raw() id field must be specified.
I believe I've fixed this issue in the past if you require assistance.
tail -f 200 /var/log/mysql/error.log
find . -type f -iname "*.log" -printf '%s %p\n'| sort -nr | head -10
Re: Re: It is possible that the database is overloaded or otherwise not running properly
You can also turn on debugging and set debug level to 'DEVELOPER'. that will (hopefully) produce a stack trace that shows the line and php file where the error is occurring.
Re: It is possible that the database is overloaded or otherwise not running properly
Just to follow up on the issue of no space left on server (@Ray;s issue) ... which sometimes results in some rather bizarre errors if one isn't seeking in the right place ... and there could be several places.
The issue was ClamAV. Turned on in Moodle, Apache error logs growing very large with entries like:
LibClamAV Error: mpool_malloc(): Attempt to allocate 8388608 bytes. Please report to http://bugs.clamav.net
The scanning of uploaded files ... the server couldn't allocate more memory to complete scanning.
Options in Moodle to route file to quarantine directory but that was not set and the option to continue upon failure was also off. Hmmmm .... teacher should have probably noticed students hadn't submitted a file and reported but .... the space issue and shutdown of DB may have been thought to be the culprit.
Entity was also dealing with a DNS Denial of Service issue. Ouch! Not a pleasant situation at all!
Anyhoo ... DoS seems to have subsided now and on the way to deciding what to do about ClamAV with Moodle .... at least they know what the issue was/is and can act accordingly.
'spirit of sharing', Ken
Re: It is possible that the database is overloaded or otherwise not running properly
I want to publicly recognize and thank the Moodle forum for again validating why I've loved and appreciated this product for the past decade! Especially want to thank @Ken for his above and beyond the call of duty in answering the call and getting our staff and students back online!
Cheers!
Re: It is possible that the database is overloaded or otherwise not running properly
You are correct ... I too have seen a more friendly/helpful forum. And thanks for your thanks! ;)
'spirit of sharing', Ken
Re: It is possible that the database is overloaded or otherwise not running properly
Hello,
I have installed some plugins in my moodle software and on next day when i started my moodle then i have this error that,
Error: Database connection failed
It is possible that the database is overloaded or otherwise not running properly.
The site administrator should also check that the database details have been correctly specified in config.php
My moodle is on Windows 7. please any one help me.