Plesk returns copy_file failed error, when changing administrator password or adding a certificate

Created:

2016-11-16 12:51:26 UTC

Modified:

2017-08-16 17:04:31 UTC

0

Was this article helpful?


Have more questions?

Submit a request

Plesk returns copy_file failed error, when changing administrator password or adding a certificate

Applicable to:

  • Plesk 12.5 for Linux
  • Plesk 11.x for Linux

Symptoms

The error listed below occurs while changing Plesk administrator password, adding a new certificate, or performing any other actions that lead to file creation by the Plesk backend:

copy_file failed: copy_file: system error: invalid file paths in /usr/local/psa/admin/bin/copy_file....

Cause

This error occurs if a symbolic link is used as path to Plesk product directory. PHP does not follow symlinks for security reasons.

Resolution

  1. Check the product directory that is currently set for Plesk in /etc/psa/psa.conf :

    # grep PRODUCT_ROOT_D /etc/psa/psa.conf
    PRODUCT_ROOT_D /usr/local/psa
  2. Make sure this path does not contain symbolic links by listing every directory in the path:

     # ls -lda /usr/local/psa
    drwxr-xr-x 13 root root 4096 2012-03-24 15:19 /usr/local/psa
    # ls -lda /usr/local
    drwxr-xr-x 12 root root 4096 2012-01-30 13:50 /usr/local
    # ls -lda /usr
    drwxr-xr-x 14 root root 4096 2011-09-28 13:00 /usr
  3. If a symbolic link is found, like in the example below, set the real path to Plesk (in the example below, it is /home/psa ) in the /etc/psa/psa.conf , /usr/local/psa/admin/conf/php.ini , and /usr/local/psa/admin/conf/httpsd.conf files:

    # ls -l /usr/local/psa
    lrwxrwxrwx  1 root root 9 Nov 17  2010 /usr/local/psa -> /home/psa
  4. Restart Plesk after modifying the configuration files:

    # /etc/init.d/psa restart
Have more questions? Submit a request
Please sign in to leave a comment.