Search Engine: Elastic

Article ID: 118513, created on Nov 8, 2013, last review on May 11, 2014

  • Applies to:
  • Odin Business Automation Standard 4.2


I'm providing Plesk Domain through PBA-S 4.2. Web statistics is enabled in Plesk Domain Hosting Plan (HP):

Top > Billing Director > Product Manager > Hosting Plans > HP > Applications
Web statistics: Included

Top > Billing Director > Product Manager > Hosting Plans > HP > Plesk platform setup
Web statistics engine:  Webalizer

I would like to enable "password-protected directory '/plesk-stat/webstat/'" for Web statistics in my domain:

Plesk > Home > Subscriptions > DOMAIN.TLD > Websites & Domains > DOMAIN.TLD
Web statistics (accessible via password-protected directory '/plesk-stat/webstat/'[X]) 

Is it possible?


Property "Password protected directory '/plesk-stat/webstat/'" has been added to Plesk Hosting Plans in PBA-S since version 4.3. Please consider upgrading PBA-S to the latest version.

To make the feature be enabled for Plesk domain after provisioning through PBA-S 4.2 you should configure Event Handler "Hosting settings created" in Parallels Plesk Panel 10.4/11.0/11.5.

Login to Parallels Plesk Panel as admin and create the Event Handler through

Plesk > Tools & Settings > Event Manager > Add New Event Handler > “Hosting setting created”

Put script name "/usr/local/psa/bin/" into the "Command" line.

The script does not exist by default - you should create it manually. For that login to the Plesk server as root and create the script with following content:


/bin/echo `date` >> /usr/local/psa/admin/logs/panel.log
/bin/echo /usr/local/psa/bin/domain --update $NEW_DOMAIN_NAME -webstat $NEW_WEB_STATISTICS -webstat-protdir-access true >> /usr/local/psa/admin/logs/panel.log
/usr/local/psa/bin/domain --update $NEW_DOMAIN_NAME -webstat $NEW_WEB_STATISTICS -webstat-protdir-access true

Verify script permissions and fix with "chmod 755":

[root@plesk11 ~]# ls -l /usr/local/psa/bin/
-rwxr-xr-x 1 root root 487 Nov  8 11:40 /usr/local/psa/bin/
[root@plesk11 ~]#

Now during domain creation, the event will be triggered and the "protected directory" feature be enabled for the domain. Event log will be written into /usr/local/psa/admin/logs/panel.log.

If you use Parallels Plesk Panel version 9.5 or earlier (EOLed version), please consider upgrading Plesk.

Additional information

Event Parameters Passed by Event Handlers in 10.4

Event Parameters Passed by Event Handlers in 11.0

Event Parameters Passed by Event Handlers in 11.5

62a72d260afd42b853c9105003928212 caea8340e2d186a540518d08602aa065 400e18f6ede9f8be5575a475d2d6b0a6 70a5401e8b9354cd1d64d0346f2c4a3e

Email subscription for changes to this article
Save as PDF