This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
documentation:server-install-components [2018/11/29 05:58] mpospisek [Config files settings] |
documentation:server-install-components [2019/01/27 08:02] mpospisek [Tomcat] |
||
---|---|---|---|
Line 115: | Line 115: | ||
# D | install systemd unit file | # D | install systemd unit file | ||
# create and open unit file service | # create and open unit file service | ||
- | vi / | + | #vi / |
- | </ | + | echo \ |
- | File contents: | + | "[Unit] |
- | <sxh bash> | + | |
- | [Unit] | + | |
Description=Apache Tomcat 9.0.x Servlet Container | Description=Apache Tomcat 9.0.x Servlet Container | ||
After=syslog.target network.target | After=syslog.target network.target | ||
Line 127: | Line 125: | ||
Group=tomcat | Group=tomcat | ||
Type=forking | Type=forking | ||
- | #Environment=JAVA_HOME=/ | + | Environment=JAVA_HOME=/ |
- | Environment=JAVA_HOME=/ | + | #Environment=JAVA_HOME=/ |
Environment=CATALINA_PID=/ | Environment=CATALINA_PID=/ | ||
Environment=CATALINA_HOME=/ | Environment=CATALINA_HOME=/ | ||
Line 136: | Line 134: | ||
[Install] | [Install] | ||
- | WantedBy=multi-user.target | + | WantedBy=multi-user.target" >/ |
- | </sxh> | + | |
- | + | # Prepare config files | |
- | Prepare config files | + | # / |
- | <codedoc code: | + | echo \ |
- | vi / | + | "#!/bin/bash -x |
- | </ | + | |
- | + | ||
- | <sxh bash> | + | |
- | #!/bin/bash -x | + | |
cd $CATALINA_BASE | cd $CATALINA_BASE | ||
- | ./ | + | ./ |
- | </sxh> | + | |
- | <codedoc code: | + | # / |
- | vi / | + | echo \ |
- | </ | + | "#!/bin/bash -x |
- | + | ||
- | <sxh bash> | + | |
- | #!/bin/bash -x | + | |
cd $CATALINA_BASE | cd $CATALINA_BASE | ||
- | ./ | + | ./ |
- | </sxh> | + | |
- | The Dcom.sun.management lines are just voluntarily, | + | # / |
- | <codedoc code: | + | # The Dcom.sun.management lines are just voluntarily, |
- | vi / | + | # *** Check validity of Xms-Xmx settings in your environment *** |
- | </ | + | echo \ |
- | + | "CATALINA_OPTS=" | |
- | <sxh bash> | + | |
- | CATALINA_OPTS=" | + | |
| | ||
| | ||
Line 175: | Line 162: | ||
| | ||
| | ||
- | " | + | " |
+ | |||
+ | # make the scripts executable | ||
+ | chmod +x / | ||
</ | </ | ||
- | < | + | Add ${catalina.home}/ |
- | cd / | + | |
- | chmod +x *.sh | + | < |
- | # | + | |
vi / | vi / | ||
</ | </ | ||
Line 290: | Line 279: | ||
WantedBy=multi-user.target | WantedBy=multi-user.target | ||
</ | </ | ||
- | | ||
- | <codedoc code: | ||
- | vi / | ||
- | </ | ||
- | <sxh bash> | + | Modify / |
- | # Add these lines ... | + | |
- | LANG=C | + | <sxh bash> |
- | OPENAAA_PROTOCOL=" | + | echo 'LANG=C' >>/ |
- | OPENAAA_HANDLER="/ | + | echo 'OPENAAA_PROTOCOL=" |
- | OPENAAA_AUTHORITY=" | + | echo 'OPENAAA_HANDLER="/ |
+ | echo OPENAAA_AUTHORITY=\"`hostname`\" | ||
+ | tail -3 / | ||
</ | </ | ||
+ | |||
==== Config files settings ==== | ==== Config files settings ==== | ||
Line 311: | Line 299: | ||
</ | </ | ||
- | <sxh bash; highlight: [4, | + | <sxh bash; highlight: [4,9,17, |
### Keep the Include conf.modules.d/ | ### Keep the Include conf.modules.d/ | ||
### but append one line in front of it, so the result will be: | ### but append one line in front of it, so the result will be: | ||
Line 331: | Line 319: | ||
# Place these three lines at the end of file | # Place these three lines at the end of file | ||
- | EnableTrace | + | TraceEnable |
Include / | Include / | ||
Include / | Include / | ||
Line 347: | Line 335: | ||
</ | </ | ||
- | <codedoc code: | ||
- | vi 00-mpm.conf | ||
- | </ | ||
<sxh bash> | <sxh bash> | ||
+ | cat 00-mpm.conf | grep prefork | ||
LoadModule mpm_prefork_module modules/ | LoadModule mpm_prefork_module modules/ | ||
</ | </ | ||
- | <codedoc code:bash> | + | <sxh bash> |
- | vi 00-proxy.conf | + | echo \ |
- | </ | + | "# This file configures all the proxy modules: |
- | <sxh bash> | + | |
- | # This file configures all the proxy modules: | + | |
LoadModule proxy_module modules/ | LoadModule proxy_module modules/ | ||
#LoadModule lbmethod_bybusyness_module modules/ | #LoadModule lbmethod_bybusyness_module modules/ | ||
Line 374: | Line 358: | ||
#LoadModule proxy_hcheck_module modules/ | #LoadModule proxy_hcheck_module modules/ | ||
#LoadModule proxy_scgi_module modules/ | #LoadModule proxy_scgi_module modules/ | ||
- | #LoadModule proxy_wstunnel_module modules/ | + | #LoadModule proxy_wstunnel_module modules/ |
</ | </ | ||
Line 382: | Line 366: | ||
<sxh bash; highlight: [9]> | <sxh bash; highlight: [9]> | ||
- | # | + | echo \ |
+ | "# | ||
# This file loads most of the modules included with the Apache HTTP | # This file loads most of the modules included with the Apache HTTP | ||
# Server itself. | # Server itself. | ||
Line 454: | Line 439: | ||
LoadModule version_module modules/ | LoadModule version_module modules/ | ||
#LoadModule vhost_alias_module modules/ | #LoadModule vhost_alias_module modules/ | ||
- | #LoadModule watchdog_module modules/ | + | #LoadModule watchdog_module modules/ |
</ | </ | ||