3

This is probably really simple, but it's really annoying! When using the Cassandra.BAT file, we can set the min / max heap size via the JAVA_OPTS parameter inside said bat file; where can we do that for the Windows Service? I thought it launched Cassandra using prunsrv using the same bat file but it seems that is not the case as it doesn't pick up any of the params set there.

Thanks

Allan

4

1 回答 1

4

正确,prunsrv 直接运行 java 进程(不确定通过 bat 使用间接调用时启动和停止服务是否会正常工作)。您可以使用此位置(64 位)更改注册表中的设置:

HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Apache Software Foundation\Procrun 2.0\DataStax_Cassandra_Community_Server\Parameters\Java\Options

您也可以使用它(见下文),但我没有尝试过。它将附加选项,因此 Java 应该忽略之前提到的任何附加选项。不要使用 --JvmOptions,因为它会用新选项替换现有的完整选项集。

prunsrv.exe //美国//DataStax_Cassandra_Community_Server ++JvmOptions=-Xms2G

于 2013-07-22T20:20:09.073 回答