So my sequence of changes was as follows:
1. Enable maintenance mode
2. Move moodledata from '/home/lmschartallcamp/public_html/moodledata' to '/home/lmschartallcamp/moodledata'
3. Update config to the version you have above
4. Disable maintenance mode
We may have a misunderstanding of root. I am using a server managed by a hosting company. The highest directory I have access to is 'lmschartallcamp'. I don't have access to home. ('/home/lmschartallcamp/moodledata') - home being the root I presume?
Im starting to think that because I moved the moodledata folder before updating the config file, some files and folders were regenerated at the old dataroot before I could update the config file.
There have been no changes to the files or folders at the old root since the day of the swap.
I moved the moodledata folder our of public_html as guided by this installation guide: https://docs.moodle.org/36/en/Installing_Moodle#Create_the_.28moodledata.29_data_directory
"IMPORTANT: This directory must NOT be accessible directly via the web. This would be a serious security hole."
This is the reason I moved the folder.
Protections wise, my server software is managed by my hosts so I'm not 100% on what is being used there. I'll check what security measures are in place by my hosts.
What do you suggest as necessary precautions?
I am actually setting up a server at the moment that I will be managing so I will have better control over these things.
I hope I'm not exposing myself to any additional vulnerabilities. It would be ironic as I'm doing this to further secure the site.
Again, thank you Ken and Howard for your help. Your knowledge on these forums has helped me numerous times in the last 3 years I have been moodling!