Hi,
The following command line triggers a garbage collection via JMX:
echo 'run -b java.lang:type=Memory gc' | java -jar jmxterm-1.0-alpha-4-uber.jar
-l service:jmx:rmi:///jndi/rmi://hostname:8080/jmxrmi -n
It uses:
http://wiki.cyclopsgroup.org/jmxterm
The GC is necessary after a major compaction to trigger the deletion of stale
files.
jmxterm can also be used to query and modify beans exposed via JMX. That makes
it easy to integrate into any monitoring & maintenance scripts, e.g.:
echo 'get -b
org.apache.cassandra.db:type=ColumnFamilies,keyspace=KS1,columnfamily=CF1
ReadCount' | ...
You can also perform multiple operations as once:
echo 'domains\nbeans' | ...
If you are concerned about the start-up speed of the jar, just unpack it. You
might need to unpack & shuffle the internal jars around a bit as well.
Cheers,
T.