Plesk for Windows
Plesk for Linux
kb: how-to
ABT: Group B
Applicable to:
- Plesk for Linux
- Plesk for Windows
Question
How to restore default content of the domain/subscription directory?
Answer
-
For Linux:
-
Connect to the server via SSH
-
Copy the content using the following command:
# cp -R /var/www/vhosts/.skel/0/. /var/www/vhosts/example.com/
Note: it is also recommended to restore permissions for the files with the command:
# plesk repair fs example.com
Or applying the following article:
How to restore default permissions in the virtual host directory on Linux?
-
-
For Windows:
-
Connect to the server via RDP
-
Copy the content from
%plesk_vhosts%\.skel\0\httpdocs
to the website home directory.
For example,%plesk_vhosts%\example.com\httpdocs
.
-
Comments
4 comments
For centos, it does not work for main server domain hosting files. It does not repair user and user group so file permissions stays for root user.
@Hüseyin Şevki TOPUZ
In test server with Plesk Onyx 17.8 and CentOS 7 everything works as expected.
Could you please clarify Plesk version and OS?
Are there any errors when restoring permissions?
OS CentOS Linux 7.5.1804 (Core)
Product Plesk Onyx 17.8.11 Update #24
Copying the example folder list was okay. There were no errors shown after the repair command but files/folders user:usergroup were root:root. I run "chown -r foldername" command for changing them to username:psaadm etc.
@Hüseyin Şevki TOPUZ
Alternatively, you can apply the following article:
https://support.plesk.com/hc/en-us/articles/213910345-How-to-restore-default-permissions-in-the-virtual-host-directory-on-Linux-
I have added the information to this article.
Please sign in to leave a comment.