You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Steven White <sw...@gmail.com> on 2015/10/29 01:12:47 UTC
Closing Windows CMD kills Solr
Hi Folks,
I don't understand if this is an expected behavior or not.
On Windows, I start Solr from a command prompt like so:
bin\solr start -p 8983 -s C:\MySolrIndex
Now, once I close the command prompt the Java process that started Solr is
killed. is this expected? How do I keep Solr alive when I close the
command prompt?
This dose not happen on Linux.
Thank in advanced.
Steve
Re: Closing Windows CMD kills Solr
Posted by Timothy Potter <th...@gmail.com>.
would launching the java process with javaw help here?
On Thu, Oct 29, 2015 at 4:03 AM, Zheng Lin Edwin Yeo
<ed...@gmail.com> wrote:
> Yes, this is the expected behaviour. Once you close the command window,
> Solr will stop running. This has happened to me several times. Just to
> check, which version of Solr are you using?
>
> I have tried NSSM before, and it works for Solr 5.0 and Solr 5.1. However,
> when I move up to Solr 5.3.0, I wasn't able to use the same method to start
> it as a service using NSSM.
>
> Do let me know if you managed to set up NSSM for Solr 5.3.0?
>
> Regards,
> Edwin
>
>
> On 29 October 2015 at 17:22, Charlie Hull <ch...@flax.co.uk> wrote:
>
>> On 29/10/2015 00:12, Steven White wrote:
>>
>>> Hi Folks,
>>>
>>> I don't understand if this is an expected behavior or not.
>>>
>>> On Windows, I start Solr from a command prompt like so:
>>>
>>> bin\solr start -p 8983 -s C:\MySolrIndex
>>>
>>> Now, once I close the command prompt the Java process that started Solr is
>>> killed. is this expected? How do I keep Solr alive when I close the
>>> command prompt?
>>>
>>> This dose not happen on Linux.
>>>
>>> Thank in advanced.
>>>
>>> Steve
>>>
>>> Yes, this is expected behaviour. If you want to prevent it you either
>> need to keep the command window open, or run Solr as a Windows Service
>> (kinda like a Unix daemon, but more annoying). To do the latter I would
>> recommend NSSM - here are some links that will help:
>>
>> http://mikerobbins.co.uk/2014/11/07/install-solr-as-windows-service-for-sitecore-content-search/
>> (from step 2)
>> http://www.norconex.com/how-to-run-solr5-as-a-service-on-windows/
>>
>> HTH
>>
>> Charlie
>>
>>
>>
>> --
>> Charlie Hull
>> Flax - Open Source Enterprise Search
>>
>> tel/fax: +44 (0)8700 118334
>> mobile: +44 (0)7767 825828
>> web: www.flax.co.uk
>>
Re: Closing Windows CMD kills Solr
Posted by Zheng Lin Edwin Yeo <ed...@gmail.com>.
Yes, this is the expected behaviour. Once you close the command window,
Solr will stop running. This has happened to me several times. Just to
check, which version of Solr are you using?
I have tried NSSM before, and it works for Solr 5.0 and Solr 5.1. However,
when I move up to Solr 5.3.0, I wasn't able to use the same method to start
it as a service using NSSM.
Do let me know if you managed to set up NSSM for Solr 5.3.0?
Regards,
Edwin
On 29 October 2015 at 17:22, Charlie Hull <ch...@flax.co.uk> wrote:
> On 29/10/2015 00:12, Steven White wrote:
>
>> Hi Folks,
>>
>> I don't understand if this is an expected behavior or not.
>>
>> On Windows, I start Solr from a command prompt like so:
>>
>> bin\solr start -p 8983 -s C:\MySolrIndex
>>
>> Now, once I close the command prompt the Java process that started Solr is
>> killed. is this expected? How do I keep Solr alive when I close the
>> command prompt?
>>
>> This dose not happen on Linux.
>>
>> Thank in advanced.
>>
>> Steve
>>
>> Yes, this is expected behaviour. If you want to prevent it you either
> need to keep the command window open, or run Solr as a Windows Service
> (kinda like a Unix daemon, but more annoying). To do the latter I would
> recommend NSSM - here are some links that will help:
>
> http://mikerobbins.co.uk/2014/11/07/install-solr-as-windows-service-for-sitecore-content-search/
> (from step 2)
> http://www.norconex.com/how-to-run-solr5-as-a-service-on-windows/
>
> HTH
>
> Charlie
>
>
>
> --
> Charlie Hull
> Flax - Open Source Enterprise Search
>
> tel/fax: +44 (0)8700 118334
> mobile: +44 (0)7767 825828
> web: www.flax.co.uk
>
Re: Closing Windows CMD kills Solr
Posted by Charlie Hull <ch...@flax.co.uk>.
On 29/10/2015 00:12, Steven White wrote:
> Hi Folks,
>
> I don't understand if this is an expected behavior or not.
>
> On Windows, I start Solr from a command prompt like so:
>
> bin\solr start -p 8983 -s C:\MySolrIndex
>
> Now, once I close the command prompt the Java process that started Solr is
> killed. is this expected? How do I keep Solr alive when I close the
> command prompt?
>
> This dose not happen on Linux.
>
> Thank in advanced.
>
> Steve
>
Yes, this is expected behaviour. If you want to prevent it you either
need to keep the command window open, or run Solr as a Windows Service
(kinda like a Unix daemon, but more annoying). To do the latter I would
recommend NSSM - here are some links that will help:
http://mikerobbins.co.uk/2014/11/07/install-solr-as-windows-service-for-sitecore-content-search/
(from step 2)
http://www.norconex.com/how-to-run-solr5-as-a-service-on-windows/
HTH
Charlie
--
Charlie Hull
Flax - Open Source Enterprise Search
tel/fax: +44 (0)8700 118334
mobile: +44 (0)7767 825828
web: www.flax.co.uk
RE: Closing Windows CMD kills Solr
Posted by "Routley, Alan" <Al...@bl.uk>.
Hi Steve,
This is expected behaviour.
I get around this by creating a scheduled task, set to run at startup to start Solr.
Hope this helps
Alan
-----Original Message-----
From: Steven White [mailto:swhite4141@gmail.com]
Sent: 29 October 2015 00:13
To: solr-user@lucene.apache.org
Subject: Closing Windows CMD kills Solr
Hi Folks,
I don't understand if this is an expected behavior or not.
On Windows, I start Solr from a command prompt like so:
bin\solr start -p 8983 -s C:\MySolrIndex
Now, once I close the command prompt the Java process that started Solr is killed. is this expected? How do I keep Solr alive when I close the command prompt?
This dose not happen on Linux.
Thank in advanced.
Steve
******************************************************************************************************************
Experience the British Library online at www.bl.uk<http://www.bl.uk/>
The British Library’s latest Annual Report and Accounts : www.bl.uk/aboutus/annrep/index.html<http://www.bl.uk/aboutus/annrep/index.html>
Help the British Library conserve the world's knowledge. Adopt a Book. www.bl.uk/adoptabook<http://www.bl.uk/adoptabook>
The Library's St Pancras site is WiFi - enabled
*****************************************************************************************************************
The information contained in this e-mail is confidential and may be legally privileged. It is intended for the addressee(s) only. If you are not the intended recipient, please delete this e-mail and notify the postmaster@bl.uk<ma...@bl.uk> : The contents of this e-mail must not be disclosed or copied without the sender's consent.
The statements and opinions expressed in this message are those of the author and do not necessarily reflect those of the British Library. The British Library does not take any responsibility for the views of the author.
*****************************************************************************************************************
Think before you print