Security and permissions for WP site hosted on a raspberry pi 4 and errors importing an Updraft backup file from Google Drive into the Updraft plugin
This is my first try both a WP site and a Raspberry Pi set up as a server-I apologize if this question seems elementary. I bought a WP site and set up the code on a Raspberry Pi 4 with Debian 10 Buster. The person I bought it from did updates and made changes to improve the site after sending me the initial code. Now I have a backup of that improved site in my google drive and am trying to add that backup through the Updraft plugin so I can restore the site to it’s upgraded version. I have connected the site on my Pi to the google drive with the backup but it did not recognize the backup files already there. I have tried to download them to my laptop then drag and drop to upload the backup file here.
Then I get Upload error: Backup directory (/var/www/html/wp-content/updraft) is not writable, or does not exist. You will find more information about this is the Settings section.
On my Pi, I went to /var/www/html/wp-content
pi@TessaPi:~ $ cd /var/www/html/wp-content
pi@TessaPi:/var/www/html/wp-content $ ls -l
total 28
-rw-r--r-- 1 www-data www-data 28 Mar 10 21:25 index.php
drwxr-xr-x 2 root root 4096 Mar 10 21:25 mu-plugins
drwxr-xr-x 21 www-data www-data 4096 Jun 9 06:23 plugins
drwxr-xr-x 8 www-data www-data 4096 Jun 9 06:24 themes
drwxr-xr-x 2 root root 4096 Mar 10 21:24 updraft
drwxr-xr-x 2 root root 4096 Mar 10 21:24 upgrade
drwxr-xr-x 8 root root 4096 Mar 10 21:25 uploads
The Updraft folder clearly exists and it has owner permissions for writing. I have also tried to download it through Chromium directly to the updraft folder and was given an “insufficient permissions” message. Am I having this issue because there is mixed ownership of my WP files? Do I have to download it through command lines? Additionally, there seems to be a debate as to whether or not root or www-data should have ownership of files for security reasons. I would greatly appreciate some advice on the best direction to go with permissions.
Leave an answer
You must login or register to add a new answer .