cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Karl Hiramoto <>
Subject Re: How to determine if repair need to be run
Date Wed, 30 Mar 2011 07:29:51 GMT
On 03/30/11 00:31, Peter Schuller wrote:
>   set -e # important
>   touch /path/to/flagfile.tmp
>   nodetool -h localhost repair
>   mv /path/to/flagfile.tmp /path/to/flagfile
Note this script doesn't work if your repair takes hours, and in the
middle of the repair cassandra was restarted, nodetool will exit and the
flagfile will be updated.   Another case, if repair hangs, and day later
cassandra is restarted.

if nodetool returns an error this might work:

 nodetool -h localhost repair && touch /path/to/flagfile.tmp


View raw message