[ 
https://issues.apache.org/jira/browse/SOLR-8777?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15187828#comment-15187828
 ] 

Shalin Shekhar Mangar commented on SOLR-8777:
---------------------------------------------

bq. I suppose we could spin for a while waiting for the previous ephemeral node 
to disappear, and if it doesn't, error out and refuse to start?

Yeah, spinning for say 2 * sessionTimeout should do the trick. This effectively 
removes this optimisation for fast node restarts and we can look into bringing 
it back in some form at a later date.

bq. Not completely related, but it seems like there's a bug in jetty's 
SocketConnector. It uses the ServerSocket constructor that automatically binds 
the port, then attempts to set setReuseAddress(), which makes no sense. It 
should use the other constructor, set the reuse_address option, then call 
bind() manually.

Perhaps [~joakime] or [~gregw] can chime in here?

bq. In other news, I don't know that there's a way to change Jetty's startup 
sequence.. the best I could do is try to use reflection to pull the connectors 
off the Server and start them early. But that seems ungood.

Theoretically, now that we control the app server -- we could move to using 
embedded Jetty (like we do for tests with JettySolrRunner) and control the 
lifecycle pretty much exactly but that is way overkill for this issue.

> Duplicate Solr process can cripple a running process
> ----------------------------------------------------
>
>                 Key: SOLR-8777
>                 URL: https://issues.apache.org/jira/browse/SOLR-8777
>             Project: Solr
>          Issue Type: Bug
>          Components: SolrCloud
>    Affects Versions: 5.3.1
>            Reporter: Shalin Shekhar Mangar
>
> Thanks to [~mewmewball] for catching this one.
> Accidentally executing the same instance of Solr twice causes the second 
> start instance to die with an "Address already in use", but not before 
> deleting the first instance's live_node entry, emitting "Found a previous 
> node that still exists while trying to register a new live node <node> - 
> removing existing node to create another".
> The second start instance dies and its ephemeral node is then removed, 
> causing /live_nodes/<node> to be empty since the first start instance's 
> live_node was deleted by the second.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to