We need to modify a few files in order for this to work in your environment.
- Modify the specified options on line 6
- Modify the table in line 9 if needed
- Save and close
- Modify line 3 to whatever directory you want to store logs into.
Once all the files are modified we can run the script. Please take a backup before you run this script as there is no undo option!
$ python transient.py
This will run the script. It will generate the log file called
The log file is so you can verify that the script is actually deleting things. If a 0 is present then the script did not find anything to delete or you have a misconfiguration in your transient.py file.
I highly suggest setting this up to run on a CRON job. If you need help setting this up feel free to contact 45Squared at anytime!