by AL Rachels.
I install different Moodle verions on my Centos server on a fairly regular basis, and have seen this a few times when I forgot to give the web user (apache) the correct permissions to all the folders and files of the install. Normally the data folders have to have read and write all the time while the main moodle folder used to only need read permission EXCEPT when you first install because it HAS to write the config file. Without write permission, I get that error. With the new built in add-on install and update capability, the main moodle folder also routinely needs write permission now or it will warn you that it cannot do the updates for add ons due to no write permission.