Details
-
Bug
-
Status: Open
-
Normal
-
Resolution: Unresolved
-
None
-
Windows with powershell
-
Normal
Description
In our test env we run our client application on the same host as Cassandra nodes. When we restart the Cassandra node when the application is still running it fails in VerifyPortsAreAvailable function of bin\cassandra.ps1:98 with the below error:
VerifyPortsAreAvailable : Found a port already in use. Aborting startup
At C:\apache-cassandra-2.2.7\bin\cassandra.ps1:98 char:9
+ VerifyPortsAreAvailable
+ ~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorException
+ FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,VerifyPortsAreAvailable
VerifyPortsAreAvailable : TCP xxx.xx.xx.171:61936 xxx.xx.xx.24:9042 ESTABLISHED
It looks like VerifyPortsAreAvailable is picking a remote 9042 port and refuses to start Cassandra.
The VerifyPortsAreAvailable function should be fixed so that it only looks for LISTENING ports.