Bug#491500: tomcat5.5: keeps open file descriptors for the terminal

Nicolas Boullis nboullis at debian.org
Sat Jul 19 22:17:15 UTC 2008


Package: tomcat5.5
Version: 5.5.26-3
Severity: normal

Hi,

When tomcat is running as a daemon, it keeps open file descriptors for 
the terminal. 

irma:~# lsof -a -c jsvc +D /dev/pts
COMMAND   PID USER   FD   TYPE DEVICE SIZE NODE NAME
jsvc    19251 root    1u   CHR  136,1         3 /dev/pts/1
jsvc    19251 root    2u   CHR  136,1         3 /dev/pts/1

I think that there is no reason why a daemon should keep the terminal 
open.
It's not very annoying when the daemon is run on startup by init. But 
when it is run over a SSH session, then the SSH session will not close 
gracefully, which is quite annoying.

Simply adding ">/dev/null 2>&1" to the $DAEMON invocation in 
/etc/init.d/tomcat5.5 would probaby solve the problem, but it might 
have some unwanted side effects. It would probably be better to fix 
jsvc to disconnect from the terminal when daemonizing, but I have not 
looked at the code.


Cheers,

Nicolas


-- System Information:
Debian Release: lenny/sid
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: powerpc (ppc)

Kernel: Linux 2.6.23-irma (PREEMPT)
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968) (ignored: LC_ALL set to C)
Shell: /bin/sh linked to /bin/bash

Versions of packages tomcat5.5 depends on:
ii  adduser              3.108               add and remove users and groups
ii  java-gcj-compat [jav 1.0.78-2            Java runtime environment using GIJ
ii  java-gcj-compat-dev  1.0.78-2            Java runtime environment with GCJ
ii  jsvc                 1.0.2~svn20061127-9 wrapper to launch Java application
ii  libecj-java          3.3.0+0728-9        Eclipse Java compiler (library)
ii  libtomcat5.5-java    5.5.26-3            Java Servlet engine -- core librar

tomcat5.5 recommends no packages.

Versions of packages tomcat5.5 suggests:
ii  gij-4.3 [java-virtual-machine 4.3.1-6    The GNU Java bytecode interpreter
ii  java-gcj-compat [java-virtual 1.0.78-2   Java runtime environment using GIJ
ii  java-gcj-compat-headless [jav 1.0.78-2   Java runtime environment using GIJ
pn  libapache2-mod-jk             <none>     (no description available)
pn  tomcat5.5-admin               <none>     (no description available)
ii  tomcat5.5-webapps             5.5.26-3   Java Servlet engine -- documentati

-- no debconf information





More information about the pkg-java-maintainers mailing list