Re: Tomcat stopped and Debug can't be done in Eclipse

2018-02-25 Thread Karen Goh


On Wed, 2/21/18, Konstantin Kolinko  wrote:

 Subject: Re: Tomcat stopped and Debug can't be done in Eclipse
 To: "Karen Goh" 
 Cc: "Tomcat Users List" 
 Date: Wednesday, February 21, 2018, 5:43 AM
 
 2018-02-20 17:57 GMT+03:00 Karen
 Goh :
 >
 > Hi Konstantin,
 >
 > Can you point me some
 useful resources where I can learn about setting the Tomcat
 launch configuration.
 
 1. On
 the topic of debugging, see the following page:
 https://wiki.apache.org/tomcat/FAQ/Developing
 
 The following two items on
 that page should be interesting for you:
 a)
 "Official Eclipse IDE Web Tools FAQ for Tomcat"
 
 with links to Eclipse
 documentation
 
 b) "How
 do I configure Tomcat to support remote debugging?"
 
 This is for the use case when
 you start Tomcat separately and attach a
 debugger to an already running Tomcat.
 
 
 2. On a topic
 of simply running Tomcat (not debugging), official
 documentation is "RUNNING.txt"
 file.
 
 There is also
 http://tomcat.apache.org/tomcat-8.5-doc/setup.html
 
 Environment variables used by
 launch scripts are documented in a
 comment
 at the top of those scripts (catalina.bat, catalina.sh).
 
 
 >
 Currently, I have the below inside my arguments :
 >
 >
 
-Dcatalina.base="C:\Users\Karen.Goh\workspace3\.metadata\.plugins\org.eclipse.wst.server.core\tmp0"
 -Dcatalina.home="C:\Program
 Files\Apache\apache-tomcat-9.0.4-windows-x64\apache-tomcat-9.0.4"
 
-Dwtp.deploy="C:\Users\Karen.Goh\workspace3\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\wtpwebapps"
 -Djava.endorsed.dirs="C:\Program
 Files\Apache\apache-tomcat-9.0.4-windows-x64\apache-tomcat-9.0.4\endorsed"
 >
 > Is this the part that
 is causing Tomcat to just hang ? Or I have missed out
 something I am not aware of.  Kindly highlight please.
 
 3. When Tomcat starts, its
 actual arguments are printed by
 VersionLoggerListener.
 
 You can see them in your previous e-mail,
 Search for "Command line argument"
 http://markmail.org/message/tgymk3r43ox5ggps
 
 > Cos I can't proceed
 with any debugging at all as in run the green button :
 Please see this attachment at https://imgur.com/OQLyJFb
 
 4. In your image I see that
 your Tomcat is not running
 
 (The "Console" view at the bottom
 says "". The
 "Servers"
 view says
 "[Stopped, Synchronized]".)
 
 How did you start it?
 
 5. My recipe will be:
 - In the
 "Servers" view select the server and deploy you
 application
 onto it (right click ->
 context menu -> ...)
 - Then click the
 small green "bug" button in the toolbar of this
 view
 (in the small toolbar right above
 "Servers" view, not the one in the
 main toolbar). The server should launch in
 debug mode.
 
It is not working following your step above.  If I started Tomcat and then 
click the green 'debug' button I will have problem going back to the Java EE 
view to click on the tutorRegister.jsp page for it to run in debug mode.

Last time, when I did debug - it was so simple.  I just click on 
tutorRegister.jsp and Eclipse will prompt me for change to debug perspective.  
After that, when I complete the form and hit submit, the IDE will then go to 
the breakpoint and allows debugging from there.

Can I know how to make this happen again ?



 HTH
 
 > Is there any other changes I need to make
 since I am also using a maven plug in as below :
 >
 > 
 >            
 org.apache.maven.plugins
 >            
 maven-war-plugin
 >            
 3.2.0
 > 
        
 >
 > It used to be very easy for me to do
 debugging and now things are so much complicated now.
 >
 
 Best
 regards,
 Konstantin Kolinko
 
 -
 To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
 For additional commands, e-mail: users-h...@tomcat.apache.org
 

-
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org



Re: [External] RE: Tomcat 8.5.23

2018-02-25 Thread Felix Schumacher
Am Freitag, den 23.02.2018, 15:26 + schrieb Lawrence Lim:
> I installed tomcat via untar, something tar -zxf apache-tomcat-
> 8.5.23.tar.gz. 

Any reason for not using the latest available tomcat?

> 
> I am running Java 8 and no security manager I know of. 

OK

> 
> I already did a chmod 777 in the tomcat directory.  

It is probably not a good idea to set any directory to word-writable,
especially if it contains server software.

The permissions on the directories of the unpacked tar should be
correct for the user that unpacked it.


What have you done after unpacking tomcat?

Did you configure the Realm (for example by having a look at
conf/tomcat-users.xml and adding the required users, roles and
passwords)?

There is quite some documentation available under http://tomcat.apache.
org/tomcat-8.5-doc/manager-howto.html

Have you looked at all log files in the logs dir?

Regards,
 Felix

> 
> Regards,
> 
> Lawrence Lim  
> Software Developer
> —
> 
> ENBRIDGE
> TEL: 780-969-6208
> 10175 101 St NW,  Edmonton, Alberta T5J 0H3
> 
> enbridge.com
> Integrity. Safety. Respect.
> 
> 
> -Original Message-
> From: Felix Schumacher [mailto:felix.schumac...@internetallee.de] 
> Sent: Thursday, February 22, 2018 11:45 PM
> To: Tomcat Users List
> Subject: [External] RE: Tomcat 8.5.23
> 
> 
> 
> Am 15. Februar 2018 19:25:24 MEZ schrieb Lawrence Lim  nbridge.com>:
> > 
> > Red Hat Enterprise Linux Server release 6.9 (Santiago)
> How did you install tomcat? 
> Are you running tomcat with some kind of security manager enabled
> (Java or system wide)? 
> Can the tomcat user (running the process) write to the filesystem?
> 
> Regards,
> Felix 
> 
> > 
> > 
> > Yes. I did check the logs. It does not log anything when I deploy.
> > But, 
> > it logs something when I undeploy.
> > 
> > Lawrence Lim
> > Software Developer
> > -
> > 
> > ENBRIDGE
> > TEL: 780-969-6208
> > 10175 101 St NW,  Edmonton, Alberta T5J 0H3
> > 
> > enbridge.com
> > Integrity. Safety. Respect.
> > 
> > -Original Message-
> > From: Satish Chhatpar 02 [mailto:chhatp...@cpwplc.com]
> > Sent: Thursday, February 15, 2018 10:58 AM
> > To: users@tomcat.apache.org
> > Subject: [External] Re: Tomcat 8.5.23
> > 
> > Which operating system?
> > Did you check the logs?
> > 
> > Sent using OWA for iPhone
> > 
> > From: Lawrence Lim 
> > Sent: Thursday, February 15, 2018 11:09:54 PM
> > To: users@tomcat.apache.org
> > Subject: Tomcat 8.5.23
> > 
> > Hi,
> > 
> > 
> > 
> > I just installed tomcat 8.5.23. I am having problems deploying web
> > apps 
> > via manager. To reproduce:
> > 
> > 
> > 
> > 1.   Login to tomcat manager
> > 
> > 
> > 
> > 2.   Go to " WAR file to deploy"
> > 
> > 
> > 
> > 3.   Pick a war file
> > 
> > 
> > 
> > 
> > 
> > Error message: FAIL - File upload failed, no file
> > 
> > 
> > 
> > 
> > 
> > Workaround: Copy war file to the tomcat webapps directory
> > 
> > 
> > 
> > 
> > 
> > I also tried using localhost:8080, same result. So, it's not some
> > weird 
> > networking constraint.
> > 
> > 
> > Lawrence Lim
> > Software Developer
> > -
> > 
> > ENBRIDGE
> > TEL: 780-969-6208
> > 10175 101 St NW,  Edmonton, Alberta T5J 0H3
> > 
> > enbridge.com
> > Integrity. Safety. Respect.
> > 
> > ::DISCLAIMER::
> > ___
> > 
> > _
> > Confidentiality Notice from Dixons Carphone plc (registered in
> > England 
> > & Wales No.07105905) of 1 Portal Way, London, W3 6RS ("Dixons 
> > Carphone"). The information contained in this e-mail and any 
> > attachments may be legally privileged, proprietary and/or
> > confidential.
> > If you received this e-mail in error, please notify the sender by 
> > return, permanently delete the e-mail and destroy all hard copies 
> > immediately. No warranty is made as to the completeness or accuracy
> > of 
> > the information contained in this e-mail. Opinions, conclusions
> > and 
> > statements of intent in this e-mail are those of the sender and
> > will 
> > not bind any Dixons Carphone group company (Dixons Carphone Group) 
> > unless confirmed by an authorised representative independently of
> > this 
> > e-mail. We do not accept responsibility for viruses; you must scan
> > for 
> > these. E-mails sent to and from Dixons Carphone Group are
> > routinely 
> > monitored for record keeping, quality control, training purposes,
> > to 
> > ensure regulatory compliance and to prevent viruses and
> > unauthorised 
> > use of our computer systems. The Carphone Warehouse Limited
> > (registered 
> > in England & Wales No.02142673) is a member of the Dixons Carphone 
> > Group and is authorised and regulated by the Financial Conduct 
> > Authority.
> > ___
> > 
> > _
> > 
> > -
> > 
>