The ErrorLog will not relocate to <VirtualHost>

Discussion in 'Installation/Configuration' started by edi00, May 31, 2010.

  1. edi00

    edi00 Member

    In spite of having the error logfile for a <VirtualHost> within its container, its host's errors will be logged at ErrorLog /var/log/apache2/error.log rather than in
    /var/log/ispconfig/httpd/domain/error.log as provided in the .vhost

    I have tried usual fixes like changing property of the folders and file...... nothing worked.:confused:
     
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    I've not seen such a problem in a ispconfig 3 setup before.

    1) Have you modified the vhost file or any folder permissions?
    2) Please post the vhost file.
     
  3. edi00

    edi00 Member


    all folders are root/root chmod 755
    the error.log is client1/web4 chmod 664

    ErrorLog /var/log/ispconfig/httpd/airpatrol.us/error.log

    The addition is red which is mod_perl2
    I have manually added /perl/ directory
    The error is generated by the mod_per test script /perl/x.pl

    However, it appears that the errors generated by the script /cgi-bin/x.pl are properly relocated.



    Code:
    <Directory /var/www/airpatrol.us>
        AllowOverride None
        Order Deny,Allow
        Deny from all
    </Directory>
    
    <VirtualHost *:80>
          DocumentRoot /var/www/airpatrol.us/web
      
        ServerName airpatrol.us
        ServerAdmin webmaster@airpatrol.us
    
        ErrorLog /var/log/ispconfig/httpd/airpatrol.us/error.log
    
        ErrorDocument 400 /error/400.html
        ErrorDocument 401 /error/401.html
        ErrorDocument 403 /error/403.html
        ErrorDocument 404 /error/404.html
        ErrorDocument 405 /error/405.html
        ErrorDocument 500 /error/500.html
        ErrorDocument 503 /error/503.html
    	
        <Directory /var/www/airpatrol.us/web>
            Options FollowSymLinks
            AllowOverride All
            Order allow,deny
            Allow from all
            # ssi enabled
            AddType text/html .shtml
            AddOutputFilter INCLUDES .shtml
            Options +Includes
        </Directory>
        <Directory /var/www/clients/client1/web4/web>
            Options FollowSymLinks
            AllowOverride All
            Order allow,deny
            Allow from all
            
            # ssi enabled
            AddType text/html .shtml
            AddOutputFilter INCLUDES .shtml
            Options +Includes
        </Directory>
        # cgi enabled
        <Directory /var/www/clients/client1/web4/cgi-bin>
          Order allow,deny
          Allow from all
        </Directory>
        ScriptAlias  /cgi-bin/ /var/www/clients/client1/web4/cgi-bin/
        AddHandler cgi-script .cgi
        AddHandler cgi-script .pl
    [COLOR="Red"]    #mod-perl
        Alias /perl/co.pl /var/www/perl/co.pl
        Alias /perl/ /var/www/clients/client1/web4/perl/
        <Directory /var/www/clients/client1/web4/perl>
          Order allow,deny
          Allow from all
        </Directory>[/COLOR]
        # suexec enabled
        SuexecUserGroup web4 client1
        # php as fast-cgi enabled
        <IfModule mod_fcgid.c>
          # SocketPath /tmp/fcgid_sock/
          IdleTimeout 3600
          ProcessLifeTime 7200
          # MaxProcessCount 1000
          DefaultMinClassProcessCount 3
          DefaultMaxClassProcessCount 100
          IPCConnectTimeout 8
          IPCCommTimeout 360
          BusyTimeout 300
        </IfModule>
        <Directory /var/www/airpatrol.us/web>
            AddHandler fcgid-script .php .php3 .php4 .php5
            FCGIWrapper /var/www/php-fcgi-scripts/web4/.php-fcgi-starter .php
            Options +ExecCGI
            AllowOverride All
            Order allow,deny
            Allow from all
        </Directory>
        <Directory /var/www/clients/client1/web4/web>
            AddHandler fcgid-script .php .php3 .php4 .php5
            FCGIWrapper /var/www/php-fcgi-scripts/web4/.php-fcgi-starter .php
            Options +ExecCGI
            AllowOverride All
            Order allow,deny
            Allow from all
        </Directory>
    
        # add support for apache mpm_itk
        <IfModule mpm_itk_module>
          AssignUserId web4 client1
        </IfModule>
    
    </VirtualHost>
    
    
    
     
    Last edited: May 31, 2010
  4. edi00

    edi00 Member

    There is another twist to this.
    It appears that an error generated by a script executed in /perl/x.pl will properly relocate.

    However, if that script includes a modul.pm (mod_perl module) and if the error happens within that module it will not relocate and goes to /var/log/apache2/error.log

    So I do not know if the ISPConfig 3 supports mod_per2 or if it is normal but there is nothing in the apache2.conf which would distinguish between a script and module generated errors.
     
    Last edited: May 31, 2010

Share This Page