You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-user@james.apache.org by Marc Chamberlin <ma...@easystreet.com> on 2005/08/05 00:17:08 UTC

James suddenly stopped working under Linux

Hi -  Think I am in need of a Linux guru as well as a James guru... I 
have been running a James server on a SuSE Linux system for some time 
now without too many problems. All of the sudden it has started balking 
and will not initialize on start up. (Didn't change anything that I know 
of on the server!) I am getting a "java.net.BindException:Address 
already in use" error when it tries to start up the SMTP portion of 
James.. Unfortunately, like most such error messages, this is rather 
useless and doesn't tell me much except to say that some other process 
has already bound itself to some port/address that James is trying to 
use.  (probably 25 but I cannot be certain since Sun does NOT bother to 
tell me what port/address is in conflict in their error message... Sigh 
with a few curses under my breath thrown in...)

I have looked to see if there is some other running instance of James of 
course... Nada nope all looks good, except for the usual 100's of 
processes that Linux runs that I don't have a clue about as to what they 
are doing or for... Sigh again...  So can some kind soul tell me how to 
find out which of these amazing useful processes has decided to glom 
onto a port/address that James wants to use? Is it just port 25 that is 
being fought over or some other port?  I could start killing em off and 
seeing if James will come back up. PAINFULLY slow way to figure it out 
and I figure that will also lead to an unstable system/crash giving me 
mixed results, so I am hesitant to start down that path...

Since I haven't changed anything, could something else have gone 
haywired with my Linux? Is there some place/file that it uses to keep 
track of what process is using what port?  Or a flag that says the port 
is in use and is not getting reset for some odd reason? I am thinking 
maybe something has gotten fouled up elsewhere and James/Sun/Linux only 
"thinks" the port is in use while it is not really so...

Just searching for ideas... any help much appreciated...    Marc..



---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org


Re: James suddenly stopped working under Linux

Posted by Stefano Bagnara <ap...@bago.org>.
> server!) I am getting a "java.net.BindException:Address 
> already in use" error when it tries to start up the SMTP 
> portion of James.. Unfortunately, like most such error 
> messages, this is rather useless and doesn't tell me much 
> except to say that some other process has already bound 
> itself to some port/address that James is trying to use.  
> (probably 25 but I cannot be certain since Sun does NOT 
> bother to tell me what port/address is in conflict in their 
> error message... Sigh with a few curses under my breath thrown in...)

Try using the "lsof" utility.
You should be able to run an "lsof" and grep the result to filter ports 25
and 110 and see what program is binding the port.
If you don't know what to do please run a "ps eaf" and post here your
running processes so we can guess what is the problem.

Stefano


---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org


Re: James suddenly stopped working under Linux

Posted by Marc Chamberlin <ma...@easystreet.com>.
Brian Haas wrote:

>To see a list of ports in use as well as the process using them:
>
>netstat -lnp
>
>Hope this helps,
>
>Brian
>
>
>-----Original Message-----
>From: Marc Chamberlin <ma...@easystreet.com>
>Sent: Thu Aug 04 16:17:08 MDT 2005
>Subject: James suddenly stopped working under Linux
>
>
>...  
>
>how to find out which of these amazing useful processes has decided to glom 
>onto a port/address that James wants to use? 
>
>...
>
>
>
>  
>
Thanks Brian and Stefano.   Your magical Linux incantations led me to 
discover that some program called "Master" had latched onto port 25. 
Further investigation of "Master" in the man pages  said it is a daemon 
that starts up a lot of goodies called Postfix processes.  (I am 
guessing this is somewhat akin to inetd? If so, Linux sure can use some 
simplification of its models and especially how they are presented to us 
poor users! damn confusing!) Anywise documentation on Postfix master 
processes led me to a file called master.cf and in there I found 
something related to smtp using port 25.  So the culprit was found!

Next I asked how does this Postfix master process get started, and 
searching around I found it was started during boot up via the runlevel 
manager. Looking inside my YaST tool sure enough it was enabled to start 
during boot. I KNOW I have never enabled this Postfix thingy myself, but 
I vaguely recall that SuSE sent out some security update for it a while 
back... I routinely apply all security updates, most of the time I don't 
have a clue as to what they really are for, not being a master level 
guru of Linux...  So I am wondering if they fowled up my server on me...

You KNOW my next move was to disable that baby on startup... Linux came 
up without any bellyaches so I figure that Postfix thing ain't very 
important after all... James also came up fine too.

BTW I have modified the startup scripts for James, and hacked together a 
framework for it to start up as a service, by following the 
model/example for the Tomcat JSP server. Very handy to have James start 
up automatically this way on startup and I can use the same sort of 
commands like rcjames stop, rcjames restart, etc... Haven't got  it 
working 100% perfectly yet, it doesn't handle a restart well if James 
got stopped via a crash but I think I know where the problem lies and 
will work on it some more. I think this would be a good feature for the 
James engineers to add, hope they are reading....

Anywise just an FYI and update...   Thanks again, much appreciated...    
Marc...


---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org


Re: Same account name different domain?

Posted by Stefano Bagnara <ap...@bago.org>.
> How can I set up James to handle different domains such that 
> jason@domain1.com and jason@domain2.com do not get delivered 
> to the same account?

Perhaps virtusertable can solve your problem:
http://james.apache.org/FAQ.html#7

Stefano


---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org


Same account name different domain?

Posted by Jason Long <ja...@supernovasoftware.com>.
How can I set up James to handle different domains such that
jason@domain1.com and jason@domain2.com do not get delivered to the same
account?

Thank you for your time, 

Jason Long
CEO and Chief Software Engineer
BS Physics, MS Chemical Engineering
http://www.supernovasoftware.com



---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org


Re: James suddenly stopped working under Linux

Posted by Brian Haas <br...@powdersoftware.com>.
To see a list of ports in use as well as the process using them:

netstat -lnp

Hope this helps,

Brian


-----Original Message-----
From: Marc Chamberlin <ma...@easystreet.com>
Sent: Thu Aug 04 16:17:08 MDT 2005
Subject: James suddenly stopped working under Linux


...  

how to find out which of these amazing useful processes has decided to glom 
onto a port/address that James wants to use? 

...


---------------------------------------------------------------------
To unsubscribe, e-mail: server-user-unsubscribe@james.apache.org
For additional commands, e-mail: server-user-help@james.apache.org