Support Article

Cassandra start script error on AIX

SA-39337

Summary



When configuring a DDS node, Pega installs a Cassandra instance and tries to start it.

The cassandra script calls Cassandra-env.sh script in which the following line is included:

jvm=`echo "$java_ver_output" | grep -A 1 'java version' | awk 'NR==2 {print $1}'`

-A is not a valid parameter for grep on AIX, therefore the script throws an error and terminates (returns control to the calling cassandra script), which eventually is able to start CassandraDeamon.

It seems the scripts have been taken as-is from a Cassandra tarball installation package, and not adopted to run on AIX.

If this is supposed to be a supported operating system, the script needs to be changed accordingly.

In their environment, Cassandra writes core dumps to the file system a few seconds after this message.

As a lot of JAVA_OPT settings (including memory settings) is defined after the line that causes an error, this might be directly related to the incorrect startup scripts.

Error Messages



[3/15/17 11:04:12:758 CET] 000001d0 SystemOut O /usr/IBM/WebSphere/AppProperties/DAKampa_ITEST1/Temp/cassandra/bin/cassandra[124]: <: unknown test operator
[3/15/17 11:04:12:758 CET] 000001d0 SystemOut O /usr/IBM/WebSphere/AppProperties/DAKampa_ITEST1/Temp/cassandra/bin/cassandra[124]: <: unknown test operator
[3/15/17 11:04:12:758 CET] 000001d0 SystemOut O grep: illegal option -- A
[3/15/17 11:04:12:759 CET] 000001d0 SystemOut O usage: grep [-r] [-R] [-H] [-L] [-E|-F] [-c|-l|-q] [-insvxbhwyu] [-p[parasep]] -e pattern_list...
[3/15/17 11:04:12:759 CET] 000001d0 SystemOut O [-f pattern_file...] [file...]
[3/15/17 11:04:12:759 CET] 000001d0 SystemOut O usage: grep [-E|-F] [-c|-l|-q] [-insvxbhwyu] [-p[parasep]] [-e pattern_list...]
[3/15/17 11:04:12:759 CET] 000001d0 SystemOut O -f pattern_file... [file...]
[3/15/17 11:04:12:759 CET] 000001d0 SystemOut O usage: grep [-E|-F] [-c|-l|-q] [-insvxbhwyu] [-p[parasep]] pattern_list [file...]
[3/15/17 11:04:12:772 CET] 000001d0 SystemOut O /usr/IBM/WebSphere/AppProperties/DAKampa_ITEST1/Temp/cassandra/bin/cassandra[124]: <: unknown test operator


Steps to Reproduce



Add DDS node or start Cassandra directly with script.


Root Cause



IBM AIX environment does not support all commands used in cassandra startup script, which causes errors during startup.

Resolution



Apply HFix-33533.

Published June 13, 2017 - Updated August 1, 2017

Have a question? Get answers now.

Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.