SSI problem
-
pepe_carlos
- Posts: 43
- Joined: Wed Aug 17, 2011 9:09 am
- Location: Madrid, Spain
SSI problem
Hello,
I have the next problem:
I have a Nagios Core (3.5.0) in Red Hat 6.5 and the code in ssi files doesn´t work. I put the simple html code but doesn´t appear
Can anyone help me?
I have the next problem:
I have a Nagios Core (3.5.0) in Red Hat 6.5 and the code in ssi files doesn´t work. I put the simple html code but doesn´t appear
Can anyone help me?
-
pepe_carlos
- Posts: 43
- Joined: Wed Aug 17, 2011 9:09 am
- Location: Madrid, Spain
Re: SSI problem
Yes, I refer to ssi folder, for example, the file extinfo-footer.ssi has the next source code:
In other Nagios server (in debian) works
I don´t see this text in the extinfo.cgi page.<p>IT IS A TEST </p>
In other Nagios server (in debian) works
-
slansing
- Posts: 7698
- Joined: Mon Apr 23, 2012 4:28 pm
- Location: Travelling through time and space...
Re: SSI problem
Can you provide an example of how/why you would like to use this? I believe PHP takes care of all of this.
-
pepe_carlos
- Posts: 43
- Joined: Wed Aug 17, 2011 9:09 am
- Location: Madrid, Spain
Re: SSI problem
I used ssi integration for put the custom information.
-
slansing
- Posts: 7698
- Joined: Mon Apr 23, 2012 4:28 pm
- Location: Travelling through time and space...
Re: SSI problem
Can you go into a bit more detail on this? What custom information? We're just trying to piece together a picture here.
-
pepe_carlos
- Posts: 43
- Joined: Wed Aug 17, 2011 9:09 am
- Location: Madrid, Spain
Re: SSI problem
In attached image works you can see the scenario under Ubuntu Server, in this case works:
Source code of web page in extinfo-info.cgi page (view source code browser option):
But in RHE 6.5 Server doesn't works; Source code of web page in extinfo-info.cgi page (view source code browser option):
...
...
<TR CLASS='comment'><TH CLASS='comment'>Entry Time</TH><TH CLASS='comment'>Author</TH><TH CLASS='comment'>Comment</TH><TH CLASS='comment'>Comment ID</TH><TH CLASS='comment'>Persistent</TH><TH CLASS='comment'>Type</TH><TH CLASS='comment'>Expires</TH><TH CLASS='comment'>Actions</TH></TR>
<TR CLASS='commentOdd'><TD CLASS='commentOdd' COLSPAN='10'>This service has no comments associated with it</TD></TR></TABLE></DIV>
</TD>
</TR>
</TABLE>
</DIV>
<p>IT IS A TEST</p>
</div>
<!-- Produced by Nagios (http://www.nagios.org). Copyright (c) 1999-2007 Ethan Galstad. -->
</body>
</html>
But in RHE 6.5 Server doesn't works; Source code of web page in extinfo-info.cgi page (view source code browser option):
...
...
<TR CLASS='comment'><TH CLASS='comment'>Entry Time</TH><TH CLASS='comment'>Author</TH><TH CLASS='comment'>Comment</TH><TH CLASS='comment'>Comment ID</TH><TH CLASS='comment'>Persistent</TH><TH CLASS='comment'>Type</TH><TH CLASS='comment'>Expires</TH><TH CLASS='comment'>Actions</TH></TR>
<TR CLASS='commentOdd'><TD CLASS='commentOdd' COLSPAN='10'>This service has no comments associated with it</TD></TR></TABLE></DIV>
</TD>
</TR>
</TABLE>
</DIV>
<!-- Produced by Nagios (http://www.nagios.org). Copyright (c) 1999-2007 Ethan Galstad. -->
</body>
</html>
Re: SSI problem
Please run the following and post the output:
grep -r "Includes" /etc/httpd/
grep -r "Includes" /etc/httpd/
Former Nagios employee
-
pepe_carlos
- Posts: 43
- Joined: Wed Aug 17, 2011 9:09 am
- Location: Madrid, Spain
Re: SSI problem
#grep -r "Includes" /etc/httpd/
Binary file /etc/httpd/modules/mod_include.so matches
/etc/httpd/conf/httpd.conf:# Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
/etc/httpd/conf/httpd.conf:# Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec
/etc/httpd/conf/httpd.conf:# (You will also need to add "Includes" to the "Options" directive.)
/etc/httpd/conf/httpd.conf: Options IncludesNoExec
/etc/httpd/conf/httpd.conf: AddOutputFilter Includes html
Binary file /etc/httpd/modules/mod_include.so matches
/etc/httpd/conf/httpd.conf:# Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
/etc/httpd/conf/httpd.conf:# Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec
/etc/httpd/conf/httpd.conf:# (You will also need to add "Includes" to the "Options" directive.)
/etc/httpd/conf/httpd.conf: Options IncludesNoExec
/etc/httpd/conf/httpd.conf: AddOutputFilter Includes html
Re: SSI problem
Looks like you need "Options +Include" somewhere.
http://www.cyberciti.biz/faq/why-my-apa ... t-working/
This could be a security risk, which is one reason why PHP is usually used for this now. However if you want you can add the .htaccess file in that directory with the appropriate string and it should work. If not, you will need to all overrides in the directory you want to use the SSI in so the .htaccess takes effect.
http://www.cyberciti.biz/faq/why-my-apa ... t-working/
This could be a security risk, which is one reason why PHP is usually used for this now. However if you want you can add the .htaccess file in that directory with the appropriate string and it should work. If not, you will need to all overrides in the directory you want to use the SSI in so the .htaccess takes effect.
Former Nagios employee