what is really in moodledata session folder ?
- ◀︎ Hi Can we create trainer list in front is using courses
- Avi video format not supported in moodle 3.4 ▶︎
This discussion has been locked so you can no longer reply to it.
what is really in moodledata session folder ?
by REMI PICARD (substitute) -
Number of replies: 8
hi,
i was doing my firlst annual backup and the folder session of moodledata took a really long time !
what does it contain ?
the official documentation said 'nothing' whereas the older doc i found, almost said something.
https://docs.moodle.org/19/en/Moodledata_directory#Sessions_folder
"Keeps session information" !
what is the aim of all this files in dession folder ? if i deleted them, what will happen ?
Is the content of this files is requiert to display the "all log" of users , or not ?
Thank you for your help and maybe a link to another helpfull documentation of that session folder.
Average of ratings: -
Permalink Reply
In reply to REMI PICARD (substitute)
Re: what is really in moodledata session folder ?
by Howard Miller -
By default PHP stores 'session' information in files. Moodle redirects them to this location. Session information is, strictly speaking, stuff that is loaded to PHP's magic $_SESSION variable. This is all sorts of things. Significantly, the user information that confirms that you are logged in (and lots of other things). If you delete that information everybody gets logged out. You definitely don't need to back it up.
Average of ratings: Useful (1)
Permalink Show parent Reply
In reply to Howard Miller
Re: what is really in moodledata session folder ?
by REMI PICARD (substitute) -
hi,
thank you for the reply.
ok it is jsut the php session backup thing $_session ...i know that part.
when i put down the site under maintenance mode, moodle should clean this folder, what is the use of collect & keep them after an maintenance mode...
moreover, i guess each file is not "linked" to user moodle item, so when i delete an account, the session file remains there whereas it should not...
mine folder have 133000 files in this folder (200 users in 2years), so i will delete them at the best time.
The documentation of 3.x should be updated about each folder description, role, importance..etc.
have a good day !
Average of ratings: -
Permalink Show parent Reply
In reply to REMI PICARD (substitute)
Re: what is really in moodledata session folder ?
by REMI PICARD (substitute) -
once i delete, i re-login myself, i check one page (user list)
after that, there is already 13 files in sessions folder whereas i'm the only one logged !
very strange behaviour of session files...maybe there is cron session but i'm wandering what are this quantity of file.
edited :
1min after my message, still the only one logged, there is now 92 files in session folder...🙄
Average of ratings: -
Permalink Show parent Reply
In reply to REMI PICARD (substitute)
Re: what is really in moodledata session folder ?
by Howard Miller -
Does it matter? You don't need to full understand the mechanism of PHP sessions to use Moodle. You just need to know that this data is not critical. As long as you are in maintenance mode, you can safely delete it.
Average of ratings: -
Permalink Show parent Reply
In reply to REMI PICARD (substitute)
Re: what is really in moodledata session folder ?
by Howard Miller -
"when i put down the site under maintenance mode, moodle should clean this folder"
Really?
The documentation is a Wiki, so please feel free to make updates when you discover new information that may help others.
Average of ratings: -
Permalink Show parent Reply
In reply to REMI PICARD (substitute)
Re: what is really in moodledata session folder ?
by Ron Peters -
The moodledata directory is the location of files that are uploaded or created by the Moodle interface. Since it is a directory, it can have a different name and location than the default name of moodledata. It contains Cache, sessions, temp, upgrade logs, etc.
Average of ratings: -
Permalink Show parent Reply
In reply to Ron Peters
Re: what is really in moodledata session folder ?
by REMI PICARD (substitute) -
hi,
yeah i knwo what is moodledata folder.
but i just would like more infos of each role of the subfolder.
As i said, the previous documentation almost began to explain them one by one what was a pretty good idea (for admin, user like me):
https://docs.moodle.org/19/en/Moodledata_directory
but the new documentation contains less infos, even nothing of the subfolders !
http://docs.moodle.org/en/Moodledata_directory
at least for this one, i'd liek to know :
- what happend if i clean it or not backup it at all
- does it contains sensible info (maybe the session subfolder can be hacked to re-use login/session...? i don't know....)
- does the size of the content is very expensive of not...what is the average size
- should one be empty after a sucess update or other event....
By example, my point, last week i performed a full moodle backup. So i noticed the session subfolder took a very very very long time to be backuped. I looked into it and discovered more than 130k files in only one folder (without sub architecture such as a/b/c/d/...like the filedir subfolder). i never saw a 133k files content in one folder since a very long time.... pretty gorgeous for system file structure....
Best regards
Average of ratings: -
Permalink Show parent Reply
In reply to REMI PICARD (substitute)
Re: what is really in moodledata session folder ?
by Visvanath Ratnaweera -
The moodledata/ structure evolves slowly. See What folders in /moodledata are actually important to backup? But moodledata/sessions/ was never a compulsory part of site backups. In fact, it is better not to backup the sessions.
Average of ratings: -
Permalink Show parent Reply
- ◀︎ Hi Can we create trainer list in front is using courses
- Avi video format not supported in moodle 3.4 ▶︎