启动不了tomcat,报Socket bind failed: [730049] 错误

错误原因:端口冲突,仔细检查配置文件server.xml中如下红颜色标注地方,改动重复项,问题即可解决。

  1、 把默认8080修改为别的端口,重启tomcat,问题没能解决

 2、 把端口修改为“8087”,问题解决

<?xml version='1.0'encoding='utf-8'?> 
<!-- 
  Licensed to the Apache Software Foundation (ASF)under one or more 
  contributor licenseagreements.  See the NOTICE file distributedwith 
  this work for additional information regardingcopyright ownership. 
  The ASF licenses this file to You under theApache License, Version 2.0 
  (the "License"); you may not use this fileexcept in compliance with 
  the License.  You may obtain acopy of the License at 

     http://www.apache.org/licenses/LICENSE-2.0 

  Unless required by applicable law or agreed toin writing, software 
  distributed under the License is distributed onan "AS IS" BASIS, 
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,either express or implied. 
  See the License for the specific languagegoverning permissions and 
  limitations under theLicense. 
--&gt 
<!-- Note:  A "Server" is notitself a "Container", so you maynot 
    define subcomponents such as "Valves" at thislevel. 
    Documentation at/docs/config/server.html 
--&gt 
 
  <!--APRlibrary loader. Documentation at /docs/apr.html--&gt 
   
  <!--Initialize Jasper prior towebapps are loaded. Documentation at /docs/jasper-howto.html--&gt 
   
  <!-- Prevent memory leaks due touse of particular java/javaxAPIs--&gt 
   
  <!-- JMX Support for the Tomcatserver. Documentation at /docs/non-existent.html--&gt 
   
   

  <!-- Global JNDIresources 
      Documentation at/docs/jndi-resources-howto.html 
 --&gt 
  
   <!-- Editable user database that can also be usedby 
        UserDatabaseRealm to authenticateusers 
   --&gt 
    
             type="org.apache.catalina.UserDatabase" 
             description="User database that can be updated andsaved" 
             factory="org.apache.catalina.users.MemoryUserDatabaseFactory" 
             pathname="conf/tomcat-users.xml"/> 
  

  <!-- A "Service" is a collectionof one or more "Connectors" thatshare 
      a single "Container" Note:  A "Service" is notitself a "Container", 
      so you may not define subcomponents such as "Valves" at thislevel. 
      Documentation at/docs/config/service.html 
  --&gt 
   
  
   <!--The connectors can use a shared executor, youcan define one or more named threadpools--&gt 
   <!-- 
    
       maxThreads="150"minSpareThreads="4"/> 
   --&gt 
    
    
   <!-- A "Connector" represents an endpoint by whichrequests are received 
        and responses are returned. Documentation at: 
        Java HTTP Connector: /docs/config/http.html (blocking&non-blocking) 
        Java AJP  Connector:/docs/config/ajp.html 
        APR (HTTP/AJP) Connector:/docs/apr.html 
        Define a non-SSL HTTP/1.1 Connector on port8080 
   --&gt 
   
              connectionTimeout="20000"  
              redirectPort="8443"/>  
    <!-- A "Connector" using the shared threadpool--&gt 
   <!-- 
    
              port="8080"protocol="HTTP/1.1" 
              connectionTimeout="20000" 
              redirectPort="8443"/> 
   --&gt           
   <!-- Define a SSL HTTP/1.1 Connector on port8443 
        This connector uses the JSSE configuration, when using APR,the 
        connector should be using the OpenSSL styleconfiguration 
        described in the APR documentation--&gt 
   <!-- 
    
              maxThreads="150" scheme="https"secure="true" 
              clientAuth="false" sslProtocol="TLS"/> 
   --&gt 

   <!-- Define an AJP 1.3 Connector on port 8009--&gt 
       


    <!-- An Engine represents the entry point(within Catalina) thatprocesses 
        every request.  The Engine implementation forTomcat stand alone 
        analyzes the HTTP headers included with the request, and passesthem 
        on to the appropriate Host (virtualhost). 
        Documentation at /docs/config/engine.html--&gt 

   <!-- You should set jvmRoute to supportload-balancing via AJP ie : 
            
   --&gt 
    

     <!--For clustering, please take a look atdocumentation at: 
         /docs/cluster-howto.html  (simple howto) 
         /docs/config/cluster.html (reference documentation)--&gt 
     <!-- 
      
     --&gt        

     <!-- The request dumper valve dumps useful debugginginformation about 
          the request and response data received and sent byTomcat. 
          Documentation at: /docs/config/valve.html--&gt 
     <!-- 
      
     --&gt 

     <!-- This Realm uses the UserDatabase configured inthe global JNDI 
          resources under the key "UserDatabase".  Anyedits 
          that are performed against this UserDatabase areimmediately 
          available for use by the Realm. --&gt 
      
            resourceName="UserDatabase"/> 

     <!-- Define the default virtualhost 
          Note: XML Schema validation will not work with Xerces2.2. 
      --&gt 
      
           unpackWARs="true" 
           xmlValidation="false"xmlNamespaceAware="false"> 

       <!-- SingleSignOn valve, share authenticationbetween web applications 
            Documentation at: /docs/config/valve.html--&gt 
       <!-- 
        
       --&gt 

       <!-- Access log processes allexample. 
            Documentation at: /docs/config/valve.html--&gt 
       <!-- 
        
              prefix="localhost_access_log." suffix=".txt" pattern="common"resolveHosts="false"/> 
       --&gt 

      
    
  

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/25253744/viewspace-729951/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/25253744/viewspace-729951/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值