You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ofbiz.apache.org by Michael Gawrychowski <mi...@gaatu.com> on 2014/10/30 20:24:53 UTC

Ofbiz goes down every time the terminal connection becomes inactive

Hi everyone, I start the ofbiz app by ssh-ing to the server and typing in
./ant start and in a few seconds I have it working. However every time I
close the terminal window the application stops working as well. Why is
that and how do I get it to work so it works all the time?

Re: Ofbiz goes down every time the terminal connection becomes inactive

Posted by Pranay Pandey <pr...@hotwaxmedia.com>.
Not specific to OFBiz but I think we should because it helps :)

Thanks

Pranay Pandey
Senior Manager, Enterprise Software Development
HotWax Media
http://www.hotwaxmedia.com
ApacheCon US 2014 Silver Sponsor
http://na.apachecon.com/sponsor/our-sponsors

On Oct 31, 2014, at 1:35 AM, Ron Wheeler <rw...@artifact-software.com> wrote:

> 
> Is this something that should be added to the docs?
> 
> Ron
> 
> -------- Original Message --------
> 
> It worked perfectly. Thank you!
> 
> On Thu, Oct 30, 2014 at 12:37 PM, Paul Mandeltort <pm...@gmail.com> wrote:
> 
>> Well ideally you should run it as a service.. :-)
>> 
>> But if you’re starting it from the command line for testing/whatnot, use
>> nohup ./startofbiz.sh & to keep it from getting killed when the terminal
>> closes.
>> —P
>> 
>> > On Oct 30, 2014, at 2:24 PM, Michael Gawrychowski <
>> michael.gawrych@gaatu.com> wrote:
>> >
>> > Hi everyone, I start the ofbiz app by ssh-ing to the server and typing in
>> > ./ant start and in a few seconds I have it working. However every time I
>> > close the terminal window the application stops working as well. Why is
>> > that and how do I get it to work so it works all the time?
>> 
>> 
> 
> 
> 


Fwd: Re: Ofbiz goes down every time the terminal connection becomes inactive

Posted by Ron Wheeler <rw...@artifact-software.com>.
Is this something that should be added to the docs?

Ron

-------- Original Message --------

It worked perfectly. Thank you!

On Thu, Oct 30, 2014 at 12:37 PM, Paul Mandeltort <pm...@gmail.com> wrote:

> Well ideally you should run it as a service.. :-)
>
> But if you’re starting it from the command line for testing/whatnot, use
> nohup ./startofbiz.sh & to keep it from getting killed when the terminal
> closes.
> —P
>
> > On Oct 30, 2014, at 2:24 PM, Michael Gawrychowski <
> michael.gawrych@gaatu.com> wrote:
> >
> > Hi everyone, I start the ofbiz app by ssh-ing to the server and typing in
> > ./ant start and in a few seconds I have it working. However every time I
> > close the terminal window the application stops working as well. Why is
> > that and how do I get it to work so it works all the time?
>
>




Re: Ofbiz goes down every time the terminal connection becomes inactive

Posted by Michael Gawrychowski <mi...@gaatu.com>.
It worked perfectly. Thank you!

On Thu, Oct 30, 2014 at 12:37 PM, Paul Mandeltort <pm...@gmail.com> wrote:

> Well ideally you should run it as a service.. :-)
>
> But if you’re starting it from the command line for testing/whatnot, use
> nohup ./startofbiz.sh & to keep it from getting killed when the terminal
> closes.
> —P
>
> > On Oct 30, 2014, at 2:24 PM, Michael Gawrychowski <
> michael.gawrych@gaatu.com> wrote:
> >
> > Hi everyone, I start the ofbiz app by ssh-ing to the server and typing in
> > ./ant start and in a few seconds I have it working. However every time I
> > close the terminal window the application stops working as well. Why is
> > that and how do I get it to work so it works all the time?
>
>

Re: Ofbiz goes down every time the terminal connection becomes inactive

Posted by Paul Mandeltort <pm...@gmail.com>.
Well ideally you should run it as a service.. :-) 

But if you’re starting it from the command line for testing/whatnot, use nohup ./startofbiz.sh & to keep it from getting killed when the terminal closes. 
—P

> On Oct 30, 2014, at 2:24 PM, Michael Gawrychowski <mi...@gaatu.com> wrote:
> 
> Hi everyone, I start the ofbiz app by ssh-ing to the server and typing in
> ./ant start and in a few seconds I have it working. However every time I
> close the terminal window the application stops working as well. Why is
> that and how do I get it to work so it works all the time?


Re: Ofbiz goes down every time the terminal connection becomes inactive

Posted by Ted Byers <r....@gmail.com>.
On Thu, Oct 30, 2014 at 3:24 PM, Michael Gawrychowski <
michael.gawrych@gaatu.com> wrote:

> Hi everyone, I start the ofbiz app by ssh-ing to the server and typing in
> ./ant start and in a few seconds I have it working. However every time I
> close the terminal window the application stops working as well. Why is
> that and how do I get it to work so it works all the time?
>

That is basic unix process management (and I'd assume it is similar on
Windows).

When you start a process from a terminal, or commandline session, that
process is a child of the process in which you started it.  In your case,
the ofbiz process is a child of the terminal window's process.  Killing
(closing) the parent kills (terminates) the child.

What you have to do is detach from the application once it has started.  To
take a trivial example, my favourite editor is Emacs.  If, in a terminal, I
execute 'emacs', emacs starts, and the terminal no longer has a cursor.  I
work in Emacs, save my document, close emacs, and then the cursor reappears
in the terminal.  But, if I close the terminal before I finish with emacs,
emacs is closed also.  Now, if I execute 'emacs&' (notice the trialing
'&'), I can continue to work in Emacs even if the terminal is closed for
whatever reason; and this is because I told the terminal to start emacs and
then detach from it.

It has been a while since I looked, but I would expect that there is a
script with it that will start ofbiz as a service.  If you can't find it,
try starting it and detaching from it.

HTH

Ted

-- 
R.E.(Ted) Byers, Ph.D.,Ed.D.