Applicable to:
- Plesk for Windows
Symptoms
-
It is not possible to upload / edit / change permissions to files or rename them in Plesk at Domains > example.com > File Manager or download file by FTP under the user account. The following error appears:
PLESK_ERROR: Internal error: filemng failed: Unable to get the object (C:\Inetpub\vhosts\example.com\httpdocs\test.html) security info: (5) Access is denied. at execute "C:\Program Files (x86)\Plesk\admin\bin\filemng.exe" user --permissions --list-common "--file=C:\Inetpub\vhosts\example.com\httpdocs\test.html" "--accounts=tmp54B2.tmp"(RunTime::RunAsUser::run line 221) (Error code 1)
-
A backup of a website based on WordPress finishes with the warning:
CONFIG_TEXT: Warning: domain "example.com"
Unable to get attributes of the file C:\Inetpub\vhosts\example.com\httpdocs\wp-content\uploads\2018\07\12.png: Access is denied. The file will not be archived. [:121566464] -
When trying to Add Files to Archive from Domains > example.com > File Manager, the following error is shown making reference to all the files that were uploaded via PHP:
PLESK_ERROR: Unable to create the archive:
7-zip 18.05 (x86): Copyright (c) 1999-2018 Igor Pavlov: 2018-04-30
Scanning the drive: 1913 folders, 10397 files, 258441467 bytes (247 MiB) Creating archive:
C:\Inetpub\vhosts\example.com\httpdocs\backup.zip Add new data to archive: 1913 folders, 10397 files, 258441467 bytes (247 MiB)
WARNING: Access is denied. wp-content\uploads\2019\04\01.png: Access is denied.
...
Cause
Product issues:
-
#PPP-49179 "The outdated PHP handlers (versions 5.6 and 7.0) no longer contain custom upload_tmp_dir as their values."
Fixed in:- Plesk Obsidian 23 June 2020 (Windows)
-
#PPPM-4539 "Files uploaded via WordPress are now assigned the correct file system permissions."
Fixed in:- Plesk Obsidian 21 January 2020 (Windows)
Resolution
Upgrade the Plesk server to the next release, make sure that FastCGI Settings are enabled in the domain PHP Settings:
Note: Check how to enable the FastCGI settings per Service Plan
-
Go to Domains > example.com > PHP Settings > Select a PHP version handled by FastCGI > Scroll down to FastCGI Settings > Set the option Enable FastCGI Settings to On > Click OK to apply the changes
Workaround
-
Connect to the server via RDP
-
Run the command:
C:\> plesk bin repair --repair-webspace-security -webspace-name example.com -all-filesystem-objects
-
Connect to the server via RDP
-
Fix file permissions:
-
For one domain
C:\> plesk bin repair --repair-webspace-security -webspace-name example.com -all-filesystem-objects
-
For all domains
C:\> for /f %i in ('plesk bin subscription -l') do plesk bin repair --repair-webspace-security -webspace-name %i -all-filesystem-objects
-
-
Create a full Plesk backup.
Warning: The following workaround must be applied every time after applying the changes at Tools & Settings > Backup Manager > Schedule, because the task is overwritten.
-
Log in to Plesk GUI and schedule a full server backup:
1.1. Go to at Tools & Settings > Backup Manager > Schedule >
1.2. Enable Activate this backup task.
1.3. Disable Use incremental backup.
1.4. Click OK.
-
Connect to the server via RDP
-
Run the following command to create a script that will automatically fix file permissions:
C:\> echo for /f %%i in ('plesk bin subscription -l') do plesk bin repair --repair-webspace-security -webspace-name %%i -all-filesystem-objects > C:\pleskrepair.cmd
-
Create a new task:
5.1. Start Task Scheduler.
5.2. Expand Task Scheduler Library and select the task Plesk Scheduler Task #Domain Backup Scheduler 1.
5.3. Click Properties on the right.
-
On the General tab, set Configure for to the latest task type available:
-
Switch to the Actions tab and click New....
-
Configure the task:
8.1. Set Action as Start a program.
8.2. In the Program/script field, specify the location of the script created on step 4 -
C:\pleskrepair.cmd
.8.3. Click OK.
-
Increase the priority of the script task, so it will run before server backup task:
9.1. Select the new action.
9.2. Click the
button.
9.3. Click OK.
Comments
0 comments
Please sign in to leave a comment.