• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Resolved Application Wordpress is botched because I removed folder

mr-wolf

Silver Pleskian
Plesk Guru
I removed the folder of the Wordpress install in /usr/local/psa/var/apspackages because I had permission errors.
I wrongly assumed it would recreate that folder for me.

There was also no accompanying zip file.
Other folders there all seem to have one.
Removing the Application Vault's cache didn't help neither did a "plesk repair installation"

I know I should have renamed the folder instead of deleting it, but that's too late now.
I also tried copying a Wordpress folder from another Plesk server, but that didn't work either.

There must be some way to recreate this folder?

Code:
Error: Cannot find package cache directory: '/usr/local/psa/var/apspackages/82e2fe74-e053-460a-b7e5-9d94bc4ca9f0'
 
Last edited:
Downloaded and unpacked application packages are located in /usr/local/psa/var/apspackages/ directory.
In general, you need to create this directory and deploy packages there according to records from database.
I think it would be better to ask assistance of Plesk Support Team.
 
Would an Onyx upgrade from 17.0.17 to 17.5 fix this?
This server is nearing its end-of-life and I might take this as an opportunity to move that closer.

I'm supposed to get support from a reseller and normally can't get direct assistance.
I'm not going that route of contacting my reseller as it has proven me extremely disappointing in the past.
 
The folder that's missing (deleted by me) is not mentioned in the database. (82e2fe74-e053-460a-b7e5-9d94bc4ca9f0)
The folder for Wordpress 4.5.2 is empty (08e5dade-3708-42b5-b2de-8b6951e37925)
The zip file for that is present. (08e5dade-3708-42b5-b2de-8b6951e37925.zip)

I created the folder, unzipped the zip in it and then did a chown -R psaadm:psaadm on that folder.

I thought I was there when the wizard started to work, but in the end it said:
Code:
Error: The following error has occurred during the installation of application:
Installation of WordPress at https://*****.nl/ failed. Non-zero exit status returned by script.
It made no directory structure

Code:
mysql> select `id`, `name`, `version`, `release`, `metafile_uri` from apsc.aps_package;
+----+-----------+---------+---------+----------------------------------------------------------------------------------+
| id | name      | version | release | metafile_uri                                                                     |
+----+-----------+---------+---------+----------------------------------------------------------------------------------+
| 11 | joomla    | 3.3.3   | 36      | /usr/local/psa/var/apspackages/ff4c01b7-4e15-4004-86fb-89a0dcf70db9/APP-META.xml |
| 20 | WordPress | 4.1.1   | 90      | /usr/local/psa/var/apspackages/ded6a038-fd14-44cc-8e75-3f2a482a02df/APP-META.xml |
| 25 | WordPress | 4.4     | 132     | /usr/local/psa/var/apspackages/102ef09a-eff5-4461-9c1c-c9b4bc492cbc/APP-META.xml |
| 26 | WordPress | 4.3.1   | 119     | /usr/local/psa/var/apspackages/ebc6a80f-6f34-4e41-b902-bd9142d09409/APP-META.xml |
| 28 | WordPress | 4.5.2   | 217     | /usr/local/psa/var/apspackages/08e5dade-3708-42b5-b2de-8b6951e37925/APP-META.xml |
| 32 | WordPress | 4.6.1   | 235     | /usr/local/psa/var/apspackages/e36a5d38-7559-4c2f-aded-71603f212703/APP-META.xml |
| 37 | WordPress | 4.7     | 236     | /usr/local/psa/var/apspackages/d10ec611-f248-4b48-aef0-81b7e6bef0ee/APP-META.xml |
| 38 | joomla    | 3.6.5   | 27      | /usr/local/psa/var/apspackages/b450f745-3ba1-4dad-a04c-e03e51bcb9c5/APP-META.xml |
| 40 | WordPress | 4.7.2   | 238     | /usr/local/psa/var/apspackages/18427298-c210-4fe9-b298-fe2bbdf84baa/APP-META.xml |
| 41 | WordPress | 4.7.3   | 239     | /usr/local/psa/var/apspackages/07662941-8a55-4063-b22b-e0bae7ea2d8e/APP-META.xml |
+----+-----------+---------+---------+----------------------------------------------------------------------------------+

What strikes me is that I can choose these Wordpress versions.
They don't correspond:

upload_2017-4-5_11-13-6.png
 
If I'm not mistaken in Plesk Onyx smb_apsPackages.cacheId is name of the folder. For example:

mysql> select * from smb_apsPackages\G
************************** 1. row **************************
id: 1
name: joomla
version: 3.6.5
release: 27
vendor: www.joomla.org
vendorHomePage: Joomla! The CMS Trusted By Millions for their Websites
packager: Plesk
packagerHomePage: Plesk WebOps platform for applications, websites and hosting
cacheId: apsE55A.tmp.zipc79c96ef-f49f-3963-be
installed: NULL
isUploaded: 0
isVisible: 0
globalSettingsNotSet: 0
registryUid: 0cfe3427-0399-44c2-886f-f31998da8beb
1 row in set (0.00 sec)
 
If I remove the folder 82e2fe74-e053-460a-b7e5-9d94bc4ca8ea, the panel starts to complain that this folder is missing.
Do note that it's not in the list generated by the database
Recreating it, does fix that again.

I just need the zip file 82e2fe74-e053-460a-b7e5-9d94bc4ca9f0.zip
None of my other installations have it.

One installation does have "82e2fe74-e053-460a-b7e5-9d94bc4ca8ea.zip" (notice the 8ea at the end, not 9f0)
I unzipped that zip anyhow to that folder and did a chown.

It still goes through the motions and then it gives that same error.
I also tried to install another version of Wordpress (one that is in the database list, but that gives me the same)...

I guess I'm going to migrate everything away onto a new server and give this one back to the reseller.
 
It turned out I did fix it this morning by unzipping that file from the other server.

I just bumped into another error because I had the wordfence's waf.php still loaded from the PHP-setup page.
Had this other error on another server just now.
By using the Wordpress wizard wich gave me more feedback than the one from applications it pointed me to that PHP-file being the culprit.

Do note: This wasn't the error all along. It just came on top of it.

upload_2017-4-5_16-4-41.png
 
To give some extra sense to this thread for other I did some additional tests.
The entry of "wordfence-waf.php" in my PHP-settings stopped me from fixing the whole problem

The info in my folder "/usr/local/psa/var/apspackages/82e2fe74-e053-460a-b7e5-9d94bc4ca9f0/" is discardable.
I only needed to recreate the folder and give it the "chown -R psaadm:psaadm".
It's a cache folder and it therefore doesn't show up in the database.

Whenever a package is selected it gets downloaded and placed there.
Pressing "Clear Cache" in Tools & Settings => Application Vault empties that folder.

So the folder I was so worried of filling with data turned out to be fully discardable.
My initial thought of removing that cache folder wasn't wrong as is now clear to me.
Manually recreating it with the correct permission was enough.

Too bad I was testing it on a domain that had another issue that needed to be resolved first.
 
Back
Top