Showing posts with label Plesk. Show all posts
Showing posts with label Plesk. Show all posts

PHP APC Extension memory limit

Recently a website of my client is acting like crazy. Certain links are not working but Apache itself is working, the main website is also working.
Upon checking on the Apache logs, I've found messages like below.

-
[Fri Aug 16 10:21:00 2012] [apc-warning] Unable to allocate memory for pool. in /var/www/vhosts/DOMAIN.com/httpdocs/modules/mod_roknavmenu/helper.php on line 25.
[Fri Aug 16 10:21:00 2012] [apc-warning] Unable to allocate memory for pool. in /var/www/vhosts/DOMAIN.com/httpdocs/modules/mod_roknavmenu/helper.php on line 41.
-


It was because of memory limitation in APC extension of PHP.
To fix it, you need to increase the memory limit of APC. Edit the file - /etc/php.d/apc.ini
Look for apc.shm_size and increase its size.

Plesk: Unable to create subdomain

Earlier today my client asked me to fix his Plesk, it can't create a subdomain.
Plesk only shows some generic error message from its interface. Upon checking the Plesk logs, I found this:

Skeleton directory `/var/www/vhosts/.skel/0' does not exist

Pretty simple, it means that /var/www/vhosts/.skel/0/ directory was deleted.
The work around is to simply recreate those directories. You may just copy the default Plesk files from any of your domain:

-bash-3.2# cp -a /var/www/vhosts/my-existing-domain.com/httpdocs/ /var/www/vhosts/.skel/0/httpdocs/
-bash-3.2# cp -a /var/www/vhosts/my-existing-domain.com/httpsdocs/ /var/www/vhosts/.skel/0/httpsdocs/
-bash-3.2# cp -a /var/www/vhosts/my-existing-domain/cgi-bin /var/www/vhosts/.skel/0/cgi-bin/
-bash-3.2# cp -a /var/www/vhosts/my-existing-domain/error_docs/ /var/www/vhosts/.skel/0/error_docs
/

If you'll attempt to create the subdomain now, I'm sure it will still fail.
Because even though it failed initially, Plesk still created the subdomain but without having those default files since they did not exist (from the .sked/0/ directory).

To remove the subdomain, issue the command below:

/usr/local/psa/admin/sbin/subdomainmng --remove --subdomain-name=testsubdomain --vhost-name=yourdomain.com

Go back to Plesk. You should be able to create the subdomain now.

Windows Server: I want to have MS SQL, do I need to purchase Plesk Power Pack?

As you have know, Windows Dedicated Server from 1and1 comes with Plesk Control Panel.
My client once asked me if he indeed needs Plesk Power Pack license for his MS SQL (Express Edition) to run on  his Windows box. Absolutely not, I told him. However he said that 1and1's tech support clearly said it to him over the phone, that MS SQL won't run on Windows Server if he won't purchase the addon license (Power Pack). Well that's another example of stupidity from 1and1's technical support.


The Power Pack addon license for Plesk is only needed if you want to manage your MS SQL server from Plesk environment. That means having Power Pack license, you will be able create/delete MS SQL database/user from Plesk. You can also to a stop/start/restart of MS SQL from the Service Management function of Plesk.

If you won't buy Power Pack license, you can still use MS SQL in your Windows Server.
Just install Management Studio to manage it.