cmdref.net - Cheat Sheet and Example

cmdref.net is command references/cheat sheets/examples for system engineers.

User Tools

Site Tools


Sidebar









Etc


Reference














.

middleware:web:httpd:index.html



Middleware

Apache HTTP Server Configuration Examples

References

Installing

Commands

configtest

Environment Commands Note
Source /usr/local/apache2/bin/apachectrl configtest
/usr/local/apache2/bin/httpd -t
RHEL7/CentOS7 apachectl configtest
httpd -t
RHEL6/CentOS6
RHEL5/CentOS5
/etc/init.d/httpd configtest
service httpd configtest


Configuration

Ubuntu

/etc/apache2/apache2.conf
/etc/apache2/envvars
/etc/apache2/ports.conf
/etc/apache2/conf-available
/etc/apache2/conf-enabled
/etc/apache2/mods-available
/etc/apache2/mods-enabled
/etc/apache2/sites-available
/etc/apache2/sites-enabled
Directory Disable Command Enable Command explanation
/etc/apache2/conf-available
/etc/apache2/conf-enabled
a2disconf a2enconf
/etc/apache2/mods-available
/etc/apache2/mods-enabled
a2dismod a2enmod
/etc/apache2/sites-available
/etc/apache2/sites-enabled
a2dissite a2ensite Virtual host Configuration

Performance

How to Check

Security

  • RC4

Dissable Apache Signature and Banner

ConfigurationNote
ServerTokens Prod This directive configures what you return as the Server HTTP response Header
Prod or ProductOnly
Prod displays “Server:Apache”
ServerSignature Off Optionally add a line containing the server version and virtual host name to server-generated pages
TraceEnable Off The 'HTTP TRACE' request is used as a debugging tool eo echo all the received information.

Disable directory Indexing

<Directory /var/www/html>
  Options -Indexes
</Directory>

Restrict Access to 'Root' directory




middleware/web/httpd/index.html.txt · Last modified: 2021/04/07 by admin

Page Tools