Document root (Apache2) change under ISPConfig 3.2

Discussion in 'Server Operation' started by MaKa, Jan 9, 2021.

  1. MaKa

    MaKa New Member

    Dear all,

    i have extended server with another new disc partition /dev/vdb1
    Now, I wanna move some existing running websites under ISPCOnfig 3.2.2 to the new disc.
    I have copied (tar) content of my old site (/var/www/domainname.nn) to new one /var2/www/domainname.nn
    Now I stopped site under ISCOnfig (Website-Webdomain-Active STOP) and changed (Website-Webdomain-Options-Apache Directive to DocumentRoot "/var2/www/domainname.nn/web/"
    Get site back ON, but error has appears...
    The following error occurred:

    You are not permitted to access the requested URL.

    Please contact the webmaster with any queries

    Document root under /etc/apache2/sites-available/domainname.nn.vhost
    is (why?)
    DocumentRoot /var/www/clients/client1/web2/web

    Is't better to symlink the old tree /var/www/clients/client1/web2/web to new one? /var2/www/domainname.nn?
     
    Last edited: Jan 9, 2021
  2. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

  3. MaKa

    MaKa New Member

  4. Th0m

    Th0m ISPConfig Developer Staff Member ISPConfig Developer

    Symlinks are not allowed for the DocRoot. It can be done by changing the vhost template, but this makes your setup less secure.
     
  5. nhybgtvfr

    nhybgtvfr Well-Known Member HowtoForge Supporter

    can you not get away with just bind mounting /var2/www/ to /var/www ?

    although personally, i would make sure the new disk/partition is large enough to hold all of /var/www with plenty of space left.
    mount it elsewhere, rsync all of /var/www to it, and then unmount it and the old partition at /var/www and remount the new larger partition at /var/www/
     
    ahrasis likes this.

Share This Page