Tomcat under CONF server.xml file configuration information

Source: Internet
Author: User
Tags add time

Tomcat under CONF server.xml file configuration information, basically do not have to make any changes can be used, the change is the host area of some configuration, this file set port is 80.

Note: Chinese is not available in the Tomcat configuration file (that is, the Server.xml file), otherwise the service cannot be started.

[XHTML]View Plaincopy
    1. < port in the!--server listens for a request to close Tomcat, shutdown specifies the command string to send to the port
    2. <Server port="8005" shutdown="shutdown" debug="0">
    3. <Listener classname="Org.apache.catalina.mbeans.ServerLifecycleListener"
    4. debug="0"/>
    5. <Listener classname="Org.apache.catalina.mbeans.GlobalResourcesLifecycleListener"
    6. debug="0"/>
    7. <globalnamingresources>
    8. <environment name="Simplevalue" type="Java.lang.Integer " value= "/>"
    9. <Resource name="userdatabase" auth="Container "
    10. type="Org.apache.catalina.UserDatabase"
    11. description="User database that can be updated and saved">
    12. </Resource>
    13. <resourceparams name="Userdatabase">
    14. <parameter>
    15. <name>factory</name>
    16. <!--value similar to logger prefix and suffix interpretation, classname Specifies the class name used by value such as: The Org.apache.catalina.values.AccessLogValve class can record the application's access information, directory specifies the log file storage location, pattern has two values, common way to record the remote host name or IP address , the user name, the date, the first line of the requested string, the HTTP response code, and the number of bytes sent. Combined way more than common record --
    17. <value>org.apache.catalina.users.memoryuserdatabasefactory</value>
    18. </parameter>
    19. <parameter>
    20. <name>pathname</name>
    21. <value>conf/tomcat-users.xml</value>
    22. </parameter>
    23. </resourceparams>
    24. </globalnamingresources>
    25. <Service name="Catalina">
    26. <!--port in connector to create a server-side port number that listens for client requests
    27. MaxThreads maximum number of threads that can create requests
    28. The number of processes that were created to process requests when the Minsparethreads service started
    29. Enablelookups If True, you can make a DNS query by calling Request.getremotehost () to get the actual hostname of the remote client and, if False, to return its IP address instead of a DNS query
    30. REDIRECTPORT Specifies the port number that the server is redirecting when it receives an SSL transfer request when it is processing an HTTP request
    31. ACCEPTCOUNT Specifies the number of processing queues that can be placed when the processing request thread is in use, beyond what will not be processed
    32. CONNECTIONTIMEOUT specifies the number of times to time out (in milliseconds)-->
    33. <Connector port="
    34. maxthreads= "minsparethreads=" " maxsparethreads= "
    35. enablelookups="false" redirectport="8443" acceptcount="
    36. debug="0" connectiontimeout="20000"
    37. disableuploadtimeout="true" />
    38. <Connector port="8009"
    39. enablelookups="false" redirectport="8443" debug="0"
    40. protocol="ajp/1.3" />
    41. <!--engine Specifies the default processing request host name, which needs to be the same as the Name property of the host element-
    42. <Engine name= "Catalina" defaulthost="localhost" debug="0">
    43. <!--logger represents the log information classname the class name used for the specified logger this class must implement the Org.apache.catalina.Logger interface prefix specify the prefix of the log file, suffix the specified suffix, Timestamp if true, add time to the log file name--
    44. <Logger classname="Org.apache.catalina.logger.FileLogger"
    45. prefix="Catalina_log." suffix=". txt"
    46. timestamp="true"/>
    47. <!--realm holds user name password and role database, classname specifies that the class name used by realm must implement Org.apache.catalina.Realm interface--
    48. <Realm classname="Org.apache.catalina.realm.UserDatabaseRealm"
    49. debug="0" resourcename="userdatabase"/>
    50. <!--host name is the specified hostname or ip,appbase application directory, Unpackwars if True will automatically unzip the war file to run directly or not.
    51. <Host name= "192.168.4.247" debug="0" appbase="D:/project/hbgs_dddu/webapps"
    52. unpackwars="true" autodeploy="true"
    53. xmlvalidation="false" xmlnamespaceaware="false">
    54. <!--logger represents the log information classname the class name used for the specified logger this class must implement the Org.apache.catalina.Logger interface prefix specify the prefix of the log file, suffix the specified suffix, Timestamp if true, add time to the log file name--
    55. <Logger classname="Org.apache.catalina.logger.FileLogger"
    56. directory= "logs" prefix="localhost_log.zx" suffix=". txt "
    57. timestamp="true"/>
    58. <!--context A Web application is usually a war file, for specific information about the war, see the servlet specification, the path to the Docbase application, or the path to the war file, path represents the URL prefix for this web program. Reloadable if True,tomcat automatically detects changes to the application and automatically loads the new application, the change code will not have to be restarted again tomcat-->
    59. <Context path= "" docbase="D:/project/hbgs_dddu/webapps" debug="0" reloadable="true"/>
    60. </Host>
    61. </Engine>
    62. </Service>
    63. </Server>

Tomcat under CONF server.xml file configuration information

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.