Why don't I have permission to delete my own files? Print

  • 2

Problem Description

  • When logged in via FTP or using the Plesk File Manager, you're unable to remove files or folders that belong to your own web app.

This typically occurs because some of the files you're trying to delete were uploaded through a web application such as WordPress or Joomla at a point when it was (or is) set to use PHP as an Apache module. When this occurs, the files are owned by the web server user account (apache or httpd by default), which means you don't have ownership of the files nor do you have permission to delete them.

Problem Resolution

To resolve this, complete the following steps:

  1. Change the PHP mode to PHP-FPM with Apache under PHP Settings for the domain in Plesk. This will mean all files uploaded in the future will be under your user account and not the 'apache' account.
  2. If you have your own VPS without Hands-On Support management: login via SSH or console, navigate to the domain's files at /var/www/vhosts/<domain>/ (possibly in httpdocs for your primary domain) and then change ownership recursively. If you have a shared hosting account or Hands-On Support management, create a support request asking to have your file ownership changed to your username and we will take care of this for you

More information on the differences between using PHP via FPM or FastCGI and as an Apache Module can be found here.

 


Was this answer helpful?

← Back