While installing Nextcloud onto my Ubuntu 18.04LTS Server, after opening my browser and going to http://my-ip-address/nextcloud , where it asks for the location of the data folder, is it safe to point it to a data folder I created on my LVM ?
I did this and ran into file permission Issues. After a week of research I figured it out, and it has been running like a champ for a week now, with many more years to come, as I can now expand my LVM endlessly.
I also was auto mounting the data file, this fixed everything.
-
sudo umount /mnt/NextCloud/data
-
cd /mnt/NextCloud
-
ls , then sudo rm -r data
-
ls , to make sure data file is gone.
-
change fstab mount to: /mnt/NextCloud
-
sudo mount /mnt/NextCloud , or sudo mount -a , make sure it mounted.
-
cd /mnt/NextCloud
-
ls -l only lost+found should be in there
-
sudo mkdir /mnt/NextCloud/data
-
ls -l check it out
-
copy anything from original /var/www/html/nextcloud/data to /mnt/NextCloud/data , for testing purposes.
-
sudo chown www-data:www-data /mnt/NextCloud/data
-
ls -l check it out, notice permissions changed.
-
Restart.
-
Check mount point, cd /mnt/NextCloud , ls -l check out permissions on data folder. If permissions are good, install Next Cloud.
Then I https://my-ip-address/nextcloud , entered the info and told nextcloud that my data folder is located at /mnt/Mextcloud/data , it installed and works great…