[rt-users] Trouble/Error with Web deployment httpd/apache/mod_fcgid

Bill Cole rtusers-20090205 at billmail.scconsult.com
Mon Nov 30 18:00:05 EST 2015


On 30 Nov 2015, at 15:02, dwdixon wrote:

> Hi Bill,
>
> Thanks for getting back with me so quickly- I was sort of on the right 
> track
> based on what you've indicated but long story short I think you're 
> correct
> and this info has helped me further...When I initially did a "httpd 
> -S" I
> got:
>
> ******************************************************************
> # httpd -S
> httpd: Could not reliably determine the server's fully qualified 
> domain
> name, using 127.0.0.1 for ServerName

That complaint is in the context of the default config that handles 
requests Apache can't determine as being for any virtual host. Not a 
serious problem, since you don't really want that config catching 
anything, I assume...

> VirtualHost configuration:
> 192.168.1.97:80      rt-ir-sandbox.snip.snip.snip.edu
> (/etc/httpd/conf.d/rt.conf:1)
> Syntax OK

So, Apache httpd is seeing the config file for the RT virtual host. 
That's good.


> ******************************************************************
>
> So I then played around with adding the ServerName directive in my 
> rt.conf:
>
> ******************************************************************
> <VirtualHost rt-ir-sandbox.snip.snip.snip.edu:80>
>      ### Optional apache logs for RT
>      # Ensure that your log rotation scripts know about these files
>      # ErrorLog /opt/rt4/var/log/apache2.error
>      # TransferLog /opt/rt4/var/log/apache2.access
>      # LogLevel debug
>      ServerName rt-ir-sandbox.snip.snip.snip.edu
>      AddDefaultCharset UTF-8
>
>      ScriptAlias / /opt/rt4/sbin/rt-server.fcgi/
>
>      DocumentRoot "/opt/rt4/share/html"
>      <Location />
>
>          Require all granted
>
>          Options +ExecCGI
>          AddHandler fcgid-script fcgi
>      </Location>
> </VirtualHost>
> ******************************************************************
>
> Still got the same complaining output as above from "httpd -S"  after 
> adding
> ServerName to rt.conf....

At which point I have to ask what may seem like an insulting question 
but really it isn't meant as such:

Are you restarting Apache after every config change?

Because while "httpd -S" will parse your current config files and tell 
you what Apache httpd would do if it was using those files, the live 
httpd processes are always using whatever config was parsed and loaded 
when their master process (assuming you're using the pre-fork MPM) was 
started.

> so then I added my
> rt-ir-sandbox.snip.snip.snip.edu as the ServerName in
> /etc/httpd/conf/httpd.conf

Don't do that. Or if you do, remove the VirtualHost "tags" around the 
config for RT. You DO NOT want the default host config for Apache 
handling requests for RT if you have RT configured inside a virtual host 
section. If you tell the default config its name is 
rt-ir-sandbox.snip.snip.snip.edu, it will handle requests for 
rt-ir-sandbox.snip.snip.snip.edu.
[...]

> I'm not certain what seems to be the issue at this point...nor why 
> when I
> add the ServerName directive to my rt.conf inside <VirtualHost> it 
> doesn't
> recognize it, and only does when I add it to 
> /etc/httpd/conf/httpd.conf.
> You also mentioned I could me missing an Include directive in 
> httpd.conf,
> any idea what that might be?

Since httpd -S is picking up your rt.conf file, that Include directive 
is correct.

The only other thing that comes to mind is the actual RT config in 
/opt/rt4/RT_SiteConfig.pm. If you haven't set WebDomain to 
rt-ir-sandbox.snip.snip.snip.edu, RT might (not sure off the top of my 
head...) redirect requests to use its default WebDomain, localhost", and 
if you're testing with a browser on the host itself that'll still work 
but hit the default config.



More information about the rt-users mailing list