> -----Original Message-----
> From: André Warnier [mailto:a...@ice-sa.com]
> Sent: Monday, March 11, 2013 4:34 AM
> To: Tomcat Users List
> Subject: Re: Console when running as a service.
>
> Sam Takoy wrote:
> > Hi,
> >
> > Just installed Tomcat 7 as a service (by running "service install").
> >
> > This is a change for me: historically, I've been running tomcat by
> running "startup" in "tomcat/bin", but now I want to get with the
> times.
> >
> > With my new, better way of running tomcat, how do I monitor with the
> server is writing to stdout and stderr? I know where to find the
> content (tomcat7-stderr.2013-03-11.log, etc.) but what is a good way to
> monitor it, i.e. see what's going on as it is happening?
> >
>
> Well, basically it is either the one or the other, can't have your cake
> and eat it, etc..
> A "Service" or "daemon", by definition, runs in the background and
> doesn't give you a real-time console to look at.
> Under Unix/Linux, you could use a command like "tail -f <logfile>"
> which would display the end of the logfile as it is being written.  But
> I do not know if Windows has any equivalent thing.
>

Yes, there are versions of tail for Windows; Google is our friend.  One version 
is at http://tailforwin32.sourceforge.net/.

> Talking about "getting with the times", maybe you are missing another
> evolutionary step here : virtualisation (see Vmware etc.).  Basically,
> this allows you to create a "virtual machine" in which to run Windows
> (and Tomcat), and to connect from a remote location to the (also
> virtual) console of that machine.  This would allow you to continue to
> run Tomcat in a command window (and see STDOUT/STDERR), without some of
> the inconvenients due to having to have a physical console to run it
> on.

But some of the advantages of using a service (whether on a physical or virtual 
server) are automatic startup (without having to be logged into the server) at 
boot time, and the ability to restart the service or to take other action if 
the service should stop (presuming that the cause of the stoppage was not 
something that would prevent the service from starting again).

And the console only contains a limited amount of information (even considering 
the data accessible by scrolling back in the window), so if one is not 
constantly monitoring the console, one is likely to miss events that would also 
be captured in the log files.

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


This e-mail and any attachments are intended only for the use of the 
addressee(s) named herein and may contain proprietary information. If you are 
not the intended recipient of this e-mail or believe that you received this 
email in error, please take immediate action to notify the sender of the 
apparent error by reply e-mail; permanently delete the e-mail and any 
attachments from your computer; and do not disseminate, distribute, use, or 
copy this message and any attachments.

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

Reply via email to