
Admin tools: Inactive User Cleanup
In the first step admin user of the site setup days of inactivity and drafting notification mail for all users from the Site administration > Reports > Inactive User Cleanup
If an inactive user is found he/she gets a notification mail.
In second step if the user still has not accessed the moodle site within the time span which is mentioned in the notification mail. Then the deletion process starts. The particular inactive user account entry is removed with next run of this cleanup process which is automatically or manually run by cron process.
Using
Some setting is require for this cleanup process.
Days of Inactivity is set by the admin user.
Days Before Deletion is set with zero when admin just wants to notify the inactive user for access the site i.e. in first step. After that when user wants to run cleanup process then Days Before Deletion will set by the admin user.
Email setting
Admin user must set the subject and body text of the email.
Cron process
Admin user run cron job manually from http://<moodlename>/admin/cron.php
Uninstall
Admin can uninstall this admin tool from Site administration > Plugins > Admin tools > Manage Admin Tools
Contributors
- DualCube
Firstly, the changes in the path will not affect other things and secondly, if you make no change in the inactive user's setting and run the cron, it will not remove any user.
It will remove the user if you set the specified date or time in inactive user's settings and if the user is inactive in that period.
Lastly, the removed user will not be recovered as there is no option available in Moodle.
Thank you.
https://www.upexams.info/
In this version, on Moodle 3.6.4 (Build: 20190513) PHP Version 7.0.33-0+deb9u3 during installaiton I get
Fatal error: Namespace declaration statement has to be the very first statement in the script in [...snip] /admin/tool/inactive_user_cleanup/classes/task/tool_inactive_user_cleanup_task.php
Easy enough to put the `namespace` ahead of the `defined` to fix it
I'm using the latest moodle 3.7.2 together with this plugin. I setup 365 days of inactivity with 14 days before the deletion. The majority of users are using oauth2 for office365 and the other the standard login. Today all the users have been deleted even active ones. How is possible?
Thank you
Thank you.
It crashes and it completely stops my Cron from working, at all. Once i uninstall it, the cron works properly again.
Then I will reinstall it, I've tried zip file, and I've tried instlaling through the browser, and it crashes within a few hours everytime.
the error it gives me is:
/home/llumenam/school.llumenamilenii.org/admin/tool/inactive_user_cleanup/classes/task/tool_inactive_user_cleanup_task.php on line 28
but line 28 is:
namespace tool_inactive_user_cleanup\task;
i don't understand what this means, it looks normal to me.
Please set up your SMTP properly from the outgoing mail configuration. Then test the outgoing mail configuration. After it is tested OK, please run the cron. It should solve the issue.
Thank you.
Users who just created an account but haven't logged in yet, will they also be seen as inactive users and get an notification mail? Because when I use a filter in "brows list of users" to select only the users whose last visit was 1 year ago, users who never logged in are also shown in this selection.
Kind regards,
Esther Peek
I am using Moodle 3.7 on PHP 7.3 everything is working fine but there is one problem that I am facing, when I installed the plugin schedule task were not showing.
i.e. schedule task were blank after plugin install. So, how can I schedule the time for this plugin and others too.
Have any idea why it is happening ??
Regards,
Amit
It might be that both use a cron job to do the job. We will check the compatibility issue and fix it .
Thank you.
Can you please let me know the version of Moodle that you are using ?
Thank you.
Fatal error: Namespace declaration statement has to be the very first statement or after any declare call in the script in /var/www/moodle35-cy-origin-qualif/admin/tool/inactive_user_cleanup/classes/task/tool_inactive_user_cleanup_task.php on line 28
concerns the task class, but also the default provider. namespace declaration should be sooner than the MOODLE_INTERNAL control.
cheers.