質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.51%
Eclipse

Eclipseは、IBM社で開発された統合開発環境のひとつです。2001年11月にオープンソース化されました。 たくさんのプラグインがあり自由に機能を追加をすることができるため、開発ツールにおける共通プラットフォームとして位置づけられています。 Eclipse自体は、Javaで実装されています。

Tomcat

TomcatはApache Software Foundation (ASF)で開発されたオープンソースのWebコンテナです。

Q&A

解決済

5回答

170088閲覧

tomcatの始動失敗について

pokkapokalemon

総合スコア11

Eclipse

Eclipseは、IBM社で開発された統合開発環境のひとつです。2001年11月にオープンソース化されました。 たくさんのプラグインがあり自由に機能を追加をすることができるため、開発ツールにおける共通プラットフォームとして位置づけられています。 Eclipse自体は、Javaで実装されています。

Tomcat

TomcatはApache Software Foundation (ASF)で開発されたオープンソースのWebコンテナです。

0グッド

5クリップ

投稿2015/11/10 08:59

編集2023/07/19 18:14

初歩的な質問を失礼いたします。
エクリプスのマーズを用いて、webアプリの初歩を学んでいる者です。

題名の通り、本日ある時点からサーバーを始動しようとしても失敗するようになりました。
思い当たる点としましては、サーブレットの修正をしており、確認用にテストサーブレットを作成、使用後不要なので削除、そののちにこの症状が出るようになりました。
一応、わからないなりに現在までにした対応は、
・トムキャットの使用ポートを確認、コマンドプロンプトでそれが使用されていないか確認。
→デフォルトの8080、8009であり、未使用みたいでした。
・サーバー環境の作り直し(今までのものの削除、新しいサーバー作成)
→同じメッセージが出る。
です。
なお、サーバを用いて動かしたいプロジェクトをサーバから除外すると起動しました。

皆様にお聞きしたいことといたしましては、
・(可能であれば)このエラーの原因
・サーバーを再び動かすためにどのような対処があるか
の二点です。
よろしくお願いいたします。

最後に、コンソールに表示されるメッセージを添付いたします。

Java

1情報: Server version: Apache Tomcat/8.0.26 [11 10 17:26:11 JST 2015] 2情報: Server built: Aug 18 2015 11:38:37 UTC [11 10 17:26:11 JST 2015] 3情報: Server number: 8.0.26.0 [11 10 17:26:11 JST 2015] 4情報: OS Name: Windows 8.1 [11 10 17:26:11 JST 2015] 5情報: OS Version: 6.3 [11 10 17:26:11 JST 2015] 6情報: Architecture: amd64 [11 10 17:26:11 JST 2015] 7情報: Java Home: C:\Users\Me\Downloads\pleiades-e4.5-java-jre_20151002\pleiades\java\8\jre [11 10 17:26:11 JST 2015] 8情報: JVM Version: 1.8.0_60-b27 [11 10 17:26:11 JST 2015] 9情報: JVM Vendor: Oracle Corporation [11 10 17:26:11 JST 2015] 10情報: CATALINA_BASE: C:\Users\Me\workspace.metadata.plugins\org.eclipse.wst.server.core\tmp0 [11 10 17:26:11 JST 2015] 11情報: CATALINA_HOME: C:\Users\Me\Downloads\pleiades-e4.5-java-jre_20151002\pleiades\tomcat\8 [11 10 17:26:11 JST 2015] 12情報: Command line argument: -Dcatalina.base=C:\Users\Me\workspace.metadata.plugins\org.eclipse.wst.server.core\tmp0 [11 10 17:26:11 JST 2015] 13情報: Command line argument: -Dcatalina.home=C:\Users\Me\Downloads\pleiades-e4.5-java-jre_20151002\pleiades\tomcat\8 [11 10 17:26:11 JST 2015] 14情報: Command line argument: -Dwtp.deploy=C:\Users\Me\workspace.metadata.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps [11 10 17:26:11 JST 2015] 15情報: Command line argument: -Djava.endorsed.dirs=C:\Users\Me\Downloads\pleiades-e4.5-java-jre_20151002\pleiades\tomcat\8\endorsed [11 10 17:26:11 JST 2015] 16情報: Command line argument: -Dfile.encoding=UTF-8 [11 10 17:26:11 JST 2015] 17情報: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\Users\Ryo\Downloads\pleiades-e4.5-java-jre_20151002\pleiades\java\8\bin;C:\WINDOWS\Sun\Java\bin;C:\WINDOWS\system32;C:\WINDOWS;C:/Users/Me/Downloads/pleiades-e4.5-java-jre_20151002/pleiades/eclipse/jre/bin/../jre/bin/server;C:/Users/Me/Downloads/pleiades-e4.5-java-jre_20151002/pleiades/eclipse/jre/bin/../jre/bin;C:/Users/Me/Downloads/pleiades-e4.5-java-jre_20151002/pleiades/eclipse/jre/bin/../jre/lib/amd64;C:\ProgramData\Oracle\Java\javapath;C:\Program Files (x86)\Intel\iCLS Client\;C:\Program Files\Intel\iCLS Client\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files (x86)\ATI Technologies\ATI.ACE\Core-Static;C:\Program Files (x86)\Common Files\lenovo\easyplussdk\bin;C:\ProgramData\Lenovo\ReadyApps;C:\Program Files (x86)\MySQL\MySQL Fabric 1.5 & MySQL Utilities 1.5\;C:\Program Files (x86)\MySQL\MySQL Fabric 1.5 & MySQL Utilities 1.5\Doctrine extensions for PHP\;C:\Program Files (x86)\Skype\Phone\;C:\Users\Me\Downloads\pleiades-e4.5-java-jre_20151002\pleiades\eclipse;;. [11 10 17:26:11 JST 2015] 18情報: Initializing ProtocolHandler ["http-nio-8080"] [11 10 17:26:12 JST 2015] 19情報: Using a shared selector for servlet write/read [11 10 17:26:12 JST 2015] 20情報: Initializing ProtocolHandler ["ajp-nio-8009"] [11 10 17:26:12 JST 2015] 21情報: Using a shared selector for servlet write/read [11 10 17:26:12 JST 2015] 22情報: Initialization processed in 718 ms [11 10 17:26:12 JST 2015] 23情報: サービス Catalina を起動します [11 10 17:26:12 JST 2015] 24情報: Starting Servlet Engine: Apache Tomcat/8.0.26 [11 10 17:26:12 JST 2015] 25重大: A child container failed during start [11 10 17:26:12 JST 2015] 26重大: A child container failed during start [11 10 17:26:12 JST 2015] 27重大: The required Server component failed to start so Tomcat is unable to start. [11 10 17:26:12 JST 2015] 28情報: Pausing ProtocolHandler ["http-nio-8080"] [11 10 17:26:12 JST 2015] 29情報: Pausing ProtocolHandler ["ajp-nio-8009"] [11 10 17:26:12 JST 2015] 30情報: サービス Catalina を停止します [11 10 17:26:12 JST 2015] 31情報: Destroying ProtocolHandler ["http-nio-8080"] [11 10 17:26:12 JST 2015] 32重大: Failed to destroy end point associated with ProtocolHandler ["http-nio-8080"] [11 10 17:26:12 JST 2015] 33情報: Destroying ProtocolHandler ["ajp-nio-8009"] [11 10 17:26:12 JST 2015] 34重大: Failed to destroy end point associated with ProtocolHandler ["ajp-nio-8009"] [11 10 17:26:12 JST 2015]

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

eripong

2015/11/10 11:14

C:\Users\Me\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\conf\server.xmlというファイルはありますか?その内容を提示できませんか?
pokkapokalemon

2015/11/11 02:40

依頼をありがとうございます。 該当ファイル、ありました! 内容を追記しておきます。
pokkapokalemon

2015/11/11 02:53

質問そのものに追記しようとしたところ文字数制限にかかったので、こちらで失礼いたします。 <?xml version="1.0" encoding="UTF-8"?> <!-- Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to You under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. --> <!-- Note: A "Server" is not itself a "Container", so you may not define subcomponents such as "Valves" at this level. Documentation at /docs/config/server.html --> -<Server shutdown="SHUTDOWN" port="8005"> <Listener className="org.apache.catalina.startup.VersionLoggerListener"/> <!-- Security listener. Documentation at /docs/config/listeners.html <Listener className="org.apache.catalina.security.SecurityListener" /> --> <!--APR library loader. Documentation at /docs/apr.html --> <Listener className="org.apache.catalina.core.AprLifecycleListener" SSLEngine="on"/> <!-- Prevent memory leaks due to use of particular java/javax APIs--> <Listener className="org.apache.catalina.core.JreMemoryLeakPreventionListener"/> <Listener className="org.apache.catalina.mbeans.GlobalResourcesLifecycleListener"/> <Listener className="org.apache.catalina.core.ThreadLocalLeakPreventionListener"/> <!-- Global JNDI resources Documentation at /docs/jndi-resources-howto.html --> -<GlobalNamingResources> <!-- Editable user database that can also be used by UserDatabaseRealm to authenticate users --> <Resource type="org.apache.catalina.UserDatabase" pathname="conf/tomcat-users.xml" name="UserDatabase" factory="org.apache.catalina.users.MemoryUserDatabaseFactory" description="User database that can be updated and saved" auth="Container"/> </GlobalNamingResources> <!-- A "Service" is a collection of one or more "Connectors" that share a single "Container" Note: A "Service" is not itself a "Container", so you may not define subcomponents such as "Valves" at this level. Documentation at /docs/config/service.html --> -<Service name="Catalina"> <!--The connectors can use a shared executor, you can define one or more named thread pools--> <!-- <Executor name="tomcatThreadPool" namePrefix="catalina-exec-" maxThreads="150" minSpareThreads="4"/> --> <!-- A "Connector" represents an endpoint by which requests 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/TLS HTTP/1.1 Connector on port 8080 --> <Connector port="8080" redirectPort="8443" protocol="HTTP/1.1" connectionTimeout="20000"/> <!-- A "Connector" using the shared thread pool--> <!-- <Connector executor="tomcatThreadPool" port="8080" protocol="HTTP/1.1" connectionTimeout="20000" redirectPort="8443" /> --> <!-- Define a SSL/TLS HTTP/1.1 Connector on port 8443 This connector uses the NIO implementation that requires the JSSE style configuration. When using the APR/native implementation, the OpenSSL style configuration is required as described in the APR/native documentation --> <!-- <Connector port="8443" protocol="org.apache.coyote.http11.Http11NioProtocol" maxThreads="150" SSLEnabled="true" scheme="https" secure="true" clientAuth="false" sslProtocol="TLS" /> --> <!-- Define an AJP 1.3 Connector on port 8009 --> <Connector port="8009" redirectPort="8443" protocol="AJP/1.3"/> <!-- An Engine represents the entry point (within Catalina) that processes every request. The Engine implementation for Tomcat stand alone analyzes the HTTP headers included with the request, and passes them on to the appropriate Host (virtual host). Documentation at /docs/config/engine.html --> <!-- You should set jvmRoute to support load-balancing via AJP ie : <Engine name="Catalina" defaultHost="localhost" jvmRoute="jvm1"> --> -<Engine name="Catalina" defaultHost="localhost"> <!--For clustering, please take a look at documentation at: /docs/cluster-howto.html (simple how to) /docs/config/cluster.html (reference documentation) --> <!-- <Cluster className="org.apache.catalina.ha.tcp.SimpleTcpCluster"/> --> <!-- Use the LockOutRealm to prevent attempts to guess user passwords via a brute-force attack --> -<Realm className="org.apache.catalina.realm.LockOutRealm"> <!-- This Realm uses the UserDatabase configured in the global JNDI resources under the key "UserDatabase". Any edits that are performed against this UserDatabase are immediately available for use by the Realm. --> <Realm className="org.apache.catalina.realm.UserDatabaseRealm" resourceName="UserDatabase"/> </Realm> -<Host name="localhost" unpackWARs="true" autoDeploy="true" appBase="webapps"> <!-- SingleSignOn valve, share authentication between web applications Documentation at: /docs/config/valve.html --> <!-- <Valve className="org.apache.catalina.authenticator.SingleSignOn" /> --> <!-- Access log processes all example. Documentation at: /docs/config/valve.html Note: The pattern used is equivalent to using pattern="common" --> <Valve className="org.apache.catalina.valves.AccessLogValve" suffix=".txt" prefix="localhost_access_log" pattern="%h %l %u %t "%r" %s %b" directory="logs"/> <Context reloadable="false" path="" docBase="C:\Users\Me\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\ROOT"/> <Context reloadable="true" path="/knntw" docBase="C:\Users\Me\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\knntw" source="org.eclipse.jst.jee.server:knntw"/> </Host> </Engine> </Service> </Server>
guest

回答5

0

私も同じ現象が起きて、この質問にたどり着いたのですがクリーンではうまく行きませんでした。
私の場合は以下の方法で解決できました。

1.サーバーから全てのプロジェクトを削除し、サーバー単体で起動するか確認する。
2.した場合、該当プロジェクトのどのファイルでエラーが起きているのかを知るために削除しながら起動を繰り返す。
3.コピペによる弊害を発見し、解決。

遅いレスですが誰かの役に立つなら嬉しいです。

投稿2018/01/09 02:57

vinoism

総合スコア18

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

0

ベストアンサー

C:\Users\Me\workspace.metadata.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps\knntw
というディレクトリは存在しますか?

このあたりのファイルが壊れている可能性があるので、
Eclipseのサーバビューで、Tomcat(おそらく「ローカル・ホスト の Tomcat8 (Java8)」)を
右クリックして、クリーンを実行した後、改めて実行したいプロジェクトを右クリックして
実行したら、改善しないでしょうか?

###改善方法の提案の理由

重大: A child container failed during start

というのは、server.xmlのchild containerの起動に失敗したということです。
Tomcat8のリファレンスにある様に、

Containers - Represent components whose function is to process incoming requests, and create the corresponding responses. An Engine handles all requests for a Service, a Host handles all requests for a particular virtual host, and a Context handles all requests for a specific web application.

Engine、Host、Contextが該当します。Engine、Hostなどはあまり変更されないので、
壊れる可能性があるとすると、Contextに書かれた内容か、そこから参照されるディレクトリなどと思います。

実際に、ContextのdocBaseにあるディレクトリを手動で削除すると、
質問と同じエラーとなりましたが、上に書いた手順により回復しました。

もちろん、別の可能性もありますが。

###一時的なログの出し方
どうも、例外が発生している様なのにスタックトレースが出ていなかったので、
ちょっと調べて、Tomcatのコンソールログをもう少し詳細に出す方法が
分かったので、書いておきます。

1.メニューの[実行]-[実行構成]でApache Tomcatの下のサーバ設定を選び、引数タブに、以下を追加する。
-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager -Djava.util.logging.config.file="C:\Users\Me\Downloads\pleiades-e4.5-java-jre_20151002\pleiades\java\8\conf\logging.properties"
(C:\Users\Me\Downloads\pleiades-e4.5-java-jre_20151002\pleiades\java\8\confは環境に合わせて変更する。)
2.そのまま、[実行]ボタンで起動する。

投稿2015/11/11 03:47

編集2015/11/11 06:51
eripong

総合スコア1546

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

pokkapokalemon

2015/11/11 05:09

丁寧に理由を書いていただきありがとうございます。 該当箇所が壊れている可能性があるということが第一点、くわえて該当ディレクトリが現在練習中のプロジェクトであることがわかりました。 現状クリーンだけでは治せませんでしたが、プログラム修正過程であちこち試行錯誤した時に書き換えてしまった記憶があります。 ですので、この後engine,host,contextを調べ、相当する箇所で何かしなかったか調べてみようと思います。 ありがとうございます。
退会済みユーザー

退会済みユーザー

2016/08/24 23:13

サーバー(Server)プロジェクトや サーバーウィンドウでそのファイル見れたような
eripong

2016/08/24 23:15

おお、そうでしたか?
guest

0

I am grateful that you have provided such helpful information. I haven't been able to think of very many questions pertaining to this subject for some time. I'm going to stand by your side! capybara clikcer

投稿2023/07/19 09:14

lily167

総合スコア24

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

0

お二方ありがとうございました。
BAはより詳しく回答をいただけたeripongさんでお願いいたします。
また、eripongさんのアドバイスに従ってよく調べたところ、問題点が見つかり解決できました。
Nさんの回答もお手軽にできるものなので、今後似たような状況が起こったら始めに試してみようと思います。
ありがとうございました。

投稿2015/11/11 05:54

pokkapokalemon

総合スコア11

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

eripong

2015/11/11 06:22 編集

解決できてよかったです。 できれば簡単にでも問題点を書いていただけると、 teratailに情報が蓄積されるので良いと思います。
guest

0

プロジェクトのコンパイル(ビルド)が正常に行われず、そのキャッシュが残っていて・・・ということはないでしょうか。
プロジェクトのキャッシュの削除とかリビルドは試されましたか?

投稿2015/11/11 03:54

N-Mercurius

総合スコア14

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

pokkapokalemon

2015/11/11 05:12

アドバイスありがとうございます。 リビルドは一応試してみました。 が、現状解決できません。。。 再度、試してみます。 ありがとうございます。
guest

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.51%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問