Resolved hosting update is failed: webstatmng: (ubuntu)

Alex Garcia

New Pleskian
Server operating system version
Ubuntu 20.04.6 LTS
Plesk version and microupdate number
Plesk Obsidian 18.0.79 - Web Host Edition
new server complete reinstall -
version : Plesk Obsidian 18.0.79 - Web Host Edition
system : Ubuntu 20.04.6 LTS

Error when i try to install a webhosting domain name
message error :
Creating physical hosting
hosting update is failed: webstatmng:
Unable to open file /opt/psa/etc/awstats/awstats.mydomainname.com-
http.conf: No such file or directory

System error 2: No such file or directory
webstatmng: Unable to copy the file /etc/awstats/awstats.model.conf to /opt/psa/etc/awstats/awstats.mydomainname.com-http.conf
System error 2: No such file or directory

trying to make an check and repair -> done
checking on file system
Webserver Configurations Troubleshooter. -> done

trying to reinstall an domaine, same results (impossible)

How to fix
1 Désinstall awstats (Debian/ubuntu)
Code:
apt remove --purge awstats

or 1 Désinstall awstats (OS version: AlmaLinux 9.8 x86_64)
see here
sources : Plesk 18.0.79.0 - Creating physical hosting fails with webstatmng: Unable to find the awstats template file
Code:
yum remove awstats


2 If you want to install goaccess:
Code:
plesk sbin packagemng -sdf

3 To switch all service plans over to goaccess:
Code:
plesk installer --select-release-current --install-component goaccess

after that install subscription or domain could be install successfully ;-)
 
The path is wrong it should be something similar to this

Thats what you should be seeing let set up my vps to see if i can get the same sort of error but this is what it should look like /var/www/vhosts/mydomainname.com/httpdocs
 
So I know!

The main issues is this:
Plesk is trying to create AWStats config files for your domain, but the directory:
Code:
/opt/psa/etc/awstats/
is missing or incomplete.
So when Plesk runs webstatmng, it tries to copy

Code:
/etc/awstats/awstats.model.conf

to:

Code:
/opt/psa/etc/awstats/awstats.mydomainname.com-http.conf

…but the target directory doesn’t exist → System error 2: No such file or directory.

This usually happens on:
  • Fresh installs of Plesk (especially on free/unsupported builds)
  • Broken AWStats installation
  • Missing Plesk components (Web Statistics)
  • Corrupted /opt/psa/etc/awstats/ folder
The Fix part A — Reinstall AWStats component (most common fix)

Run:

Code:
plesk installer --select-release-current --install-component awstats

Then repair configs:

Code:
plesk repair web -y

The Fix part B - Manually recreate missing directories

Check if the folder exists:

Code:
ls -la /opt/psa/etc/awstats/

If missing, create it:

Code:
mkdir -p /opt/psa/etc/awstats/
chmod 755 /opt/psa/etc/awstats/

Then copy the model file:

Code:
cp /etc/awstats/awstats.model.conf /opt/psa/etc/awstats/

Try cry creating the domain again.

Fix C — Switch statistics engine to Webalizer (quick workaround)

If AWStats is broken and you don’t need it:

Code:
plesk bin domain --update mydomainname.com -webstat webalizer

Then repair:

Code:
plesk repair web -y

This bypasses AWStats entirely.

Fix D — Rebuild Plesk configs

Sometimes AWStats is installed but Plesk didn’t generate configs:

Code:
/usr/local/psa/admin/sbin/webstatmng --create --domain-name=mydomainname.com

Or rebuild all:

Code:
plesk repair installation

Fix R — If you installed Plesk using a “free unofficial script”

Many free installers skip AWStats.

You must install missing packages manually:

Code:
apt install awstats

Then:

Code:
plesk installer --select-release-current --install-component awstats
 
Back
Top