Can I Use My LVM for Data Folder & Storage?

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.

  1. sudo umount /mnt/NextCloud/data

  2. cd /mnt/NextCloud

  3. ls , then sudo rm -r data

  4. ls , to make sure data file is gone.

  5. change fstab mount to: /mnt/NextCloud

  6. sudo mount /mnt/NextCloud , or sudo mount -a , make sure it mounted.

  7. cd /mnt/NextCloud

  8. ls -l only lost+found should be in there

  9. sudo mkdir /mnt/NextCloud/data

  10. ls -l check it out

  11. copy anything from original /var/www/html/nextcloud/data to /mnt/NextCloud/data , for testing purposes.

  12. sudo chown www-data:www-data /mnt/NextCloud/data

  13. ls -l check it out, notice permissions changed.

  14. Restart.

  15. 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…