1

I've got a vm set up with Apache and mysql and it works so far:

enter image description here

but it only has 16gb, just for Ubuntu, Apache and Mysql. But I've also got a data disk:

enter image description here

I've done the steps to change the document-root: https://www.digitalocean.com/community/tutorials/how-to-move-an-apache-web-root-to-a-new-location-on-ubuntu-16-04

However, when I try to access the url, I get

enter image description here

Why? I checked, and they're both the same owner/permissions:

enter image description here enter image description here

I haven't the foggiest how to do it with symlinks, which was suggested to me.

5
  • 2
    If you are sure you have copied the whole html directory to disc1, remove it from the root partition: sudo rm -r /var/www/html and create a symlink: sudo ln -s /net/vmits0356/disk1/html /var/www/html. Don't run everything as root, that is bad practice.
    – Jos
    Oct 31, 2020 at 13:56
  • I did your steps, still getting 403 forbidden Oct 31, 2020 at 14:03
  • 2
    That will be because the target directory is owned by root and not by the web server user, which will be www-data if you are running Apache2. Do sudo chown -R www-data:www-data /var/www/html.
    – Jos
    Oct 31, 2020 at 14:10
  • 1
    Nope, still the same, 403 Forbidden, with www-data as owner. Another problem, the symlink doesn't seem to be working: i.imgur.com/ErluLLm.png , i.imgur.com/DAILRjf.png ! Oct 31, 2020 at 14:14
  • Omg....disc not disk...problem solved! Oct 31, 2020 at 14:20

0

You must log in to answer this question.

Browse other questions tagged .