Get your server issues fixed by our experts for a price starting at just 25 USD/Hour. Click here to register and open a ticket with us now!

Author Topic: How to disable statistics calculation for a particular domain  (Read 2647 times)

0 Members and 1 Guest are viewing this topic.

vinayakk

  • Guest
How to disable statistics calculation for a particular domain
« on: February 24, 2014, 07:06:40 am »
How to disable statistics calculation for exact domain to decrease load on server while statistics recalculation task runs.

Statistics recalculation task takes a time to recalculate huge amount of HTTP and FTP statistics for domains.

There are three ways to disable statistics recalculation:

   1. Duplicate current service plan with option 'none' as statistics processing utility.

   2. Block synchronization with service plan.

    Firstly, statistics collection should be disabled. To disable it via GUI follow 'Customer Panel' > 'Hosting settings' > 'Web stat' > Specify "none"

    Or you can execute shell command:

    # /usr/local/psa/bin/domain -u domain.tld -webstat none

    Secondly, you need to block synchronization with service plan:

    # /usr/local/psa/bin/domain --lock-subscription <subscription_name.tld>

    3. Modify 'cron' task.

    You can add the script which will disable statistics and will be executed before 'daily task':

    # /usr/local/psa/bin/domain -u domain.tld -webstat none

    And will enable this back after 'daily task' ran:

    # /usr/local/psa/bin/domain -u domain.tld -webstat awstats

    This workaround does not affect synchronization with service plan and exclude the domains to calculated.

 :)