mirror of https://github.com/apache/cassandra
Remove bashisms for mx4j tool in cassandra-env.sh
/bin/sh (our shebang in bin/cassandra) does not recognize the `if` construct which is available in /bin/bash only hence if MX4J_ADDRESS or MX4J_PORT was not commented out, the script would fail to execute it. patch by Stefan Miklosovic; reviewed by Brandon Williams for CASSANDRA-19416
This commit is contained in:
parent
505f5af645
commit
98d0e181d5
|
|
@ -1,4 +1,5 @@
|
|||
4.0.13
|
||||
* Remove bashisms for mx4j tool in cassandra-env.sh (CASSANDRA-19416)
|
||||
* Add new concurrent_merkle_tree_requests config property to prevent OOM during multi-range and/or multi-table repairs (CASSANDRA-19336)
|
||||
Merged from 3.11:
|
||||
Merged from 3.0:
|
||||
|
|
|
|||
|
|
@ -287,7 +287,7 @@ JVM_OPTS="$JVM_OPTS -Dcom.sun.management.jmxremote.password.file=/etc/cassandra/
|
|||
JVM_OPTS="$JVM_OPTS -Djava.library.path=$CASSANDRA_HOME/lib/sigar-bin"
|
||||
|
||||
if [ "x$MX4J_ADDRESS" != "x" ]; then
|
||||
if [[ "$MX4J_ADDRESS" == \-Dmx4jaddress* ]]; then
|
||||
if [ "$(echo "$MX4J_ADDRESS" | grep -c "\-Dmx4jaddress")" = "1" ]; then
|
||||
# Backward compatible with the older style #13578
|
||||
JVM_OPTS="$JVM_OPTS $MX4J_ADDRESS"
|
||||
else
|
||||
|
|
@ -295,7 +295,7 @@ if [ "x$MX4J_ADDRESS" != "x" ]; then
|
|||
fi
|
||||
fi
|
||||
if [ "x$MX4J_PORT" != "x" ]; then
|
||||
if [[ "$MX4J_PORT" == \-Dmx4jport* ]]; then
|
||||
if [ "$(echo "$MX4J_PORT" | grep -c "\-Dmx4jport")" = "1" ]; then
|
||||
# Backward compatible with the older style #13578
|
||||
JVM_OPTS="$JVM_OPTS $MX4J_PORT"
|
||||
else
|
||||
|
|
|
|||
Loading…
Reference in New Issue