Jump to: navigation, search
MithiWiki Home > ConnectXf Home > ConnectXf Administration > Configuration > Immediately free up disk space used up by spam reports table
Troubleshooting Icon.png
Troubleshooting
Product ConnectXf
Version All
Applies to Administrators
Level Advanced



Immediately free up disk space used up by spam reports table

Prerequisites

  1. The /mcsdata partition must not be 100% full. If the disk space is 100% full, then the table has to be dropped and new table created as given here http://wiki.mithi.com:8080/xf/wiki/index.php/Administration:Database#Immediately_free_up_disk_space_used_up_by_spam_reports_table_when_disk_space_is_100.25_full.
  2. During the time of following operations, the load on the server will increase, therefore it is recommended to run the script in non-peak hours.

Operations

  • The clean up can be done with a small downtime of about 5 minutes or without downtime.
  • If we take downtime, then the spam reports data in that 5 minutes will not be lost.
  • If we do not take downtime, spam reports data will not get added in table for 5 minutes, but smtp and queue can continue to run.
  • By default the script will keep data of 3 days in the report table. Older data will be deleted.

Process with downtime

  1. Stop SMTP and queue services.
  2. Run the cleanspamreporttable.sh script using runonce.sh
  3. In the output of the script it will show foll. message 'You can now start SMTP and Queue services if you have stopped them', after a short time interval - about 3 - 5 minutes.
  4. Start the SMTP and queue services.
  5. Monitor the /var/log/messages & /var/log/maillog.
  6. The cleanspamreporttable.sh will continue. At the end it will show line 'Completed spam report table cleanup operation'.
  7. Check disk space.
  8. Check spam report is getting generated for 1 user.

Process without downtime :

  1. Run the cleanspamreporttable.sh script using runonce.sh
  2. Monitor the /var/log/messages & /var/log/maillog.
  3. In the output of the script it will show foll. message 'You can now start SMTP and Queue services if you have stopped them', after a short time interval - about 3 - 5 minutes. Ignore this as we have not stopped the services.
  4. At the end cleanspamreporttable.sh will show line 'Completed spam report table cleanup operation'.
  5. Check disk space.
  6. Check spam report is getting generated for 1 user.

Script

Download script http://xf.wiki.mithi.com/xd/wiki/images/Cleanspamreporttable.sh.doc

Copy the script to MCS server.

Run foll. 2 commands to make script execuable

dos2unix Cleanspamreporttable.sh.doc

chmod +x Cleanspamreporttable.sh.doc