Vhost - Communication error

Moderator: crythias

Post Reply
phoenixrouge
Znuny newbie
Posts: 5
Joined: 14 Nov 2014, 15:00
Znuny Version: 6.0.4

Vhost - Communication error

Post by phoenixrouge »

Hi guys,

I got a problem after updating my OTRS with vhost configuration.
I updated apache configuration file to work without "/otrs" suffix.

Here is my new configuration file (/opt/otrs/scripts/apache2-httpd.include.conf updated too) :
<VirtualHost otrs-xxxxxxxxxxxxxxx.fr:80>
ServerName otrs-xxxxxxxxxxxxxxx.fr
ServerAlias www.otrs-xxxxxxxxxxxxxxx.fr
Redirect permanent / https://otrs-xxxxxxxxxxxxxxx.fr/
</VirtualHost>

# --
# added for OTRS (http://otrs.org/)
# --


<VirtualHost otrs-xxxxxxxxxxxxxxx.fr:443>
ServerName otrs-xxxxxxxxxxxxxxx.fr
ServerAlias www.otrs-xxxxxxxxxxxxxxx.fr
Alias /otrs-web/ "/opt/otrs/var/httpd/htdocs/"
DocumentRoot "/opt/otrs/bin/cgi-bin/"
SSLEngine on
SSLCertificateFile /opt/certificats/otrs/otrs.cer
SSLCertificateKeyFile /opt/certificats/otrs/otrs.key
SSLCertificateChainFile /opt/certificats/otrs/otrs.txt

<IfModule mod_perl.c>

# Setup environment and preload modules
Perlrequire /opt/otrs/scripts/apache2-perl-startup.pl

# Reload Perl modules when changed on disk
PerlModule Apache2::Reload
PerlInitHandler Apache2::Reload

# mod_perl2 options for GenericInterface
<Location /otrs/nph-genericinterface.pl>
PerlOptions -ParseHeaders
</Location>

</IfModule>

<Directory "/opt/otrs/bin/cgi-bin/">
AllowOverride None
DirectoryIndex index.pl
Options +ExecCGI -Includes
ErrorDocument 403 /otrs/index.pl
AddHandler perl-script .pl .cgi
PerlResponseHandler ModPerl::Registry
PerlOptions +ParseHeaders
PerlOptions +SetupEnv
Require all granted

<IfModule mod_version.c>
<IfVersion < 2.4>
Order allow,deny
Allow from all
</IfVersion>
<IfVersion >= 2.4>
Require all granted
</IfVersion>
</IfModule>
<IfModule !mod_version.c>
Order allow,deny
Allow from all
</IfModule>

<IfModule mod_filter.c>
<IfModule mod_deflate.c>
AddOutputFilterByType DEFLATE text/html text/javascript application/javascript text/css text/xml application/json text/json
</IfModule>
</IfModule>
</Directory>

<Directory "/opt/otrs/var/httpd/htdocs/">
AllowOverride None

<IfModule mod_version.c>
<IfVersion < 2.4>
Order allow,deny
Allow from all
</IfVersion>
<IfVersion >= 2.4>
Require all granted
</IfVersion>
</IfModule>
<IfModule !mod_version.c>
Order allow,deny
Allow from all
</IfModule>

<IfModule mod_filter.c>
<IfModule mod_deflate.c>
AddOutputFilterByType DEFLATE text/html text/javascript application/javascript text/css text/xml application/json text/json
</IfModule>
</IfModule>

# Make sure CSS and JS files are read as UTF8 by the browsers.
AddCharset UTF-8 .css
AddCharset UTF-8 .js

# Set explicit mime type for woff fonts since it is relatively new and apache may not know about it.
AddType application/font-woff .woff

</Directory>

<IfModule mod_headers.c>
# Cache css-cache for 30 days
<Directory "/opt/otrs/var/httpd/htdocs/skins/*/*/css-cache">
<FilesMatch "\.(css|CSS)$">
Header set Cache-Control "max-age=2592000 must-revalidate"
</FilesMatch>
</Directory>

# Cache css thirdparty for 4 hours, including icon fonts
<Directory "/opt/otrs/var/httpd/htdocs/skins/*/*/css/thirdparty">
<FilesMatch "\.(css|CSS|woff|svg)$">
Header set Cache-Control "max-age=14400 must-revalidate"
</FilesMatch>
</Directory>

# Cache js-cache for 30 days
<Directory "/opt/otrs/var/httpd/htdocs/js/js-cache">
<FilesMatch "\.(js|JS)$">
Header set Cache-Control "max-age=2592000 must-revalidate"
</FilesMatch>
</Directory>

# Cache js thirdparty for 4 hours
<Directory "/opt/otrs/var/httpd/htdocs/js/thirdparty/">
<FilesMatch "\.(js|JS)$">
Header set Cache-Control "max-age=14400 must-revalidate"
</FilesMatch>
</Directory>
</IfModule>

</VirtualHost>

OTRS works fine, but when we try to use some functionnalities we got this warning :
Communication error
There was an error in communication with the server. Server might be experiencing some temporary problems, please reload this page to check if they have been resolved.
and apache error logs...
client denied by server configuration : /opt/otrs/bin/cgi-bin/index.pl, referer: https://otrs-xxxxxxxxxxxxxxx.fr/index.p ... ketID=xxxx
If someone has an idea...
Thanks

PS : server on private network, cant give real url...
OTRS v6.0.4-03
phoenixrouge
Znuny newbie
Posts: 5
Joined: 14 Nov 2014, 15:00
Znuny Version: 6.0.4

Re: Vhost - Communication error

Post by phoenixrouge »

Any idea?
Post Reply