ISPConfig 3 - Disabled Sites are Deleted from /sites-enabled/

Discussion in 'General' started by reason8, Oct 15, 2015.

  1. reason8

    reason8 Member

    Hello and good afternoon.
    I have been a ISPConfig user for many years. It's a great piece of software and I recommend it to everyone.
    For some reason, when I disable a site and try to re-enable, it does not load.
    The vhost file is not in the /etc/apache2/sites-enabled but it is in the /sites-available
    I have tried disabling and reenabling from the control panel but with no success.
    The only thing that works is restoring the backup copy and the site loads.
    If someone could help, I would greatly appreciate it.

    ISPConfig 3 / openSUSE 12.1
    Pentium 2.8GHZ w/ Hyperthreading
    4GB Ram, 1TB Hard Drive
     
  2. lnxgs

    lnxgs Member

    Hi,
    do you use openSuSE 12?
    This distro does not have /etc/apache2/sites-enabled or /etc/apache2/sites-avalable but virtualhost are in /etc/apache2/vhosts.d folder.

    Regards,
    L.
     
  3. reason8

    reason8 Member

    I upgraded from openSUSE 11.4 to 12.1.

    I have been running ISPConfig on on openSUSE since version 11.1 and upgraded to 11.4 almost a year ago. Since the distro is no longer being updated, I decided to upgrade to 12.1 about a month or so ago.

    So my installation may still be using /sites-enabled/ and /sites-available/.
    After restoring the XXX-domain.tld.vhost file, I was able to get the site back up and working.
    But I am afraid of this occurring with existing and future domains.
     
  4. reason8

    reason8 Member

    Hello and good afternoon.

    I am still having this problem.

    Can someone please give me some insight?

    I configured debug logging and see that the site and symlinking is attempted but the vhost does not appear in /etc/apache2/sites-enabled.

    Logging shows:
    Creating symlink: /etc/apache2/sites-enabled/100-domain.com.vhost->/etc/apache2/sites-available/domain.com.vhost

    But it does not actually get created.
    I can manually create the new vhost by physically creating the symlink.
    The permissions on the directory are root:root for both /etc/apache2/sites-available and /etc/apache2/sites-enabled.

    This was working fine years ago but I have upgraded opensuse a few times (from 11.1 to 11.4) and thats when I saw it not working.
    I have since upgraded from 11.4 to 13.1.
    Thanks.
     
  5. till

    till Super Moderator Staff Member ISPConfig Developer

    Please check that SELinux and Apparmor are not enabled. Then you should check that there is no open_basedir set in the global php.ini file.
     
    reason8 likes this.
  6. reason8

    reason8 Member

    Hi Till,
    SELinux and Apparmor are not turned on (never had been).

    However, my /etc/php5/apache2/php.ini includes the following:
    open_basedir = "/srv/www:/usr/local/ispconfig:/tmp/ispconfig3_install:/etc/postfix:/usr/lib/php5"

    Should I comment this out?
    A few opensuse upgrades ago (I believe 11.1 to 11.2 or 11.3), ISPConfig would not upgrade without setting open_basedir for the ispconfig directory.
     
  7. reason8

    reason8 Member

    Update,
    I was able to get a site re-eneabled.
    My /etc/php5/cli/php.ini had open_basedir = "/srv/www:/tmp/ispconfig3_install:/usr/local/ispconfig:/root:/home:/etc:/var/backup:/var/vmail:/var/lib/mailman:/var/lib/named:/srv/www/cgi-bin/php5:/usr/local/bin:/var/log/ispconfig:/bin:/sbin:/srv/www/cgi-bin/php:/usr/bin/systemctl:/var/log:/etc/phpMyAdmin:/bin/systemd"
    Commenting this entire line allowed the re-enabling of the site. However, is this going to cause me system functionality issues?
    I believe I started adding these directories a couple years ago because ISPConfig (and some other apps) were not working.
    Maybe because I had this in effect it was causing issues altogether?

    open_basedir is still in affect at /etc/php5/apache2/php.ini
     
  8. till

    till Super Moderator Staff Member ISPConfig Developer

    There should be no global open_basedir set in php cli php.ini. ISPConfig configures open_basedir for each site individually.
     
    reason8 likes this.
  9. reason8

    reason8 Member

    That worked!
    Should I also comment out open_basedir in apache php.ini?
    I have two, 2 cli and apache2 php.ini
     
  10. till

    till Super Moderator Staff Member ISPConfig Developer

    If it works currently, then you can leave it as it is.
     

Share This Page