cassandracassandra-3.0repairreaper

how to configure and run Reaper to repair cassandra in linux( centos environment)


I'm trying to install and run Reaper 1.4 on my centos VM. And followed the same installation step as in given video (https://www.youtube.com/watch?v=0dub29BgwPI), but still no success in getting reaper started.Can anyone please help me with proper/complete document. however i have read and followed http://cassandra-reaper.io/docs/download/

Below given is my cassandra-reaper.yaml settings:

segmentCountPerNode: 16
repairParallelism: DATACENTER_AWARE
repairIntensity: 0.9
scheduleDaysBetween: 7
repairRunThreadCount: 15
hangingRepairTimeoutMins: 30
storageType: cassandra
enableCrossOrigin: true
incrementalRepair: false
blacklistTwcsTables: false
enableDynamicSeedList: true
repairManagerSchedulingIntervalSeconds: 10
activateQueryLogger: false
jmxConnectionTimeoutInSeconds: 5
useAddressTranslator: false
# purgeRecordsAfterInDays: 30
# numberOfRunsToKeepPerUnit: 10
jmxPorts:
        #127.0.0.1: 7100
        #10.X.X.X: 7199
        #127.0.0.2: 7200
        #127.0.0.3: 7300
        #127.0.0.4: 7400
        #127.0.0.5: 7500
        #127.0.0.6: 7600
        #127.0.0.7: 7700
        #127.0.0.8: 7800

jmxAuth:
        username: *****
        password: *****

server:
  type: default
  applicationConnectors:
    - type: http
      port: 8080
      bindHost: 0.0.0.0
  adminConnectors:
    - type: http
      port: 8081
      bindHost: 0.0.0.0
  requestLog:
    appenders: []
cassandra:
  clusterName: "dc1"
  contactPoints: ["10.X.X.1","10.X.X.2","10.X.X.3","10.X.X.4","10.X.X.5"]
  #contactPoints: ["127.0.0.1"]
  keyspace: "reaper_db"
  loadBalancingPolicy:
    type: tokenAware
    shuffleReplicas: true
    subPolicy:
      type: dcAwareRoundRobin
      localDC:
      usedHostsPerRemoteDC: 0
      allowRemoteDCsForLocalConsistencyLevel: false
  authProvider:
    type: plainText
    username: cass
    password: cass
  ssl:
    type: jdk

autoScheduling:
  enabled: false
  initialDelayPeriod: PT15S
  periodBetweenPolls: PT10M
  timeBeforeFirstSchedule: PT5M
  scheduleSpreadPeriod: PT6H
  excludedKeyspaces:
    - keyspace1
    - keyspace2
accessControl:
  sessionTimeout: PT10M
  shiro:
    iniConfigs: ["classpath:shiro.ini"]

log from /var/log/cassandra-reaper/reaper.log

INFO   [main] i.c.ReaperApplication - initializing runner thread pool with 15 threads
INFO   [main] i.c.ReaperApplication - initializing storage of type: cassandra
INFO   [main] c.d.d.core - DataStax Java driver 3.5.0 for Apache Cassandra
INFO   [main] c.d.d.c.GuavaCompatibility - Detected Guava >= 19 in the classpath, using modern compatibility layer
INFO   [main] c.d.d.c.ClockFactory - Using native clock to generate timestamps.
INFO   [main] c.d.d.c.NettyUtil - Found Netty's native epoll transport in the classpath, using it
INFO   [main] o.a.s.c.ReflectionBuilder - An instance with name 'authc' already exists.  Redefining this object as a new instance of type org.apache.shiro.web.filter.authc.PassThruAuthenticationFilter

log from /var/log/cassandra-reaper.err

        at org.yaml.snakeyaml.scanner.ScannerImpl.fetchMoreTokens(ScannerImpl.java:415)
        at org.yaml.snakeyaml.scanner.ScannerImpl.checkToken(ScannerImpl.java:226)
        at org.yaml.snakeyaml.parser.ParserImpl$ParseBlockMappingValue.produce(ParserImpl.java:586)
        at org.yaml.snakeyaml.parser.ParserImpl.peekEvent(ParserImpl.java:158)
        at org.yaml.snakeyaml.parser.ParserImpl.getEvent(ParserImpl.java:168)
        at com.fasterxml.jackson.dataformat.yaml.YAMLParser.nextToken(YAMLParser.java:347)
        ... 11 more
ls: cannot access server/target/cassandra-reaper-*.jar: No such file or directory
io.dropwizard.configuration.ConfigurationParsingException: /etc/cassandra-reaper/cassandra-reaper.yaml has an error:
  * Malformed YAML at line: 27, column: 11; while scanning for the next token; found character  '\t' that cannot start any token;  in 'reader', line 27, column 1:
        clusterName: "dc1"
    ^
 at [Source: (ByteArrayInputStream); line: 26, column: 10]

        at io.dropwizard.configuration.ConfigurationParsingException$Builder.build(ConfigurationParsingException.java:279)
        at io.dropwizard.configuration.BaseConfigurationFactory.build(BaseConfigurationFactory.java:96)
        at io.dropwizard.cli.ConfiguredCommand.parseConfiguration(ConfiguredCommand.java:126)
        at io.dropwizard.cli.ConfiguredCommand.run(ConfiguredCommand.java:74)
        at io.dropwizard.cli.Cli.run(Cli.java:78)
        at io.dropwizard.Application.run(Application.java:93)
        at io.cassandrareaper.ReaperApplication.main(ReaperApplication.java:99)
Caused by: com.fasterxml.jackson.dataformat.yaml.snakeyaml.error.MarkedYAMLException: while scanning for the next token; found character        '\t' that cannot start any token;  in 'reader', line 27, column 1:
        clusterName: "dc1"
    ^

Solution

    • Malformed YAML at line: 27, column: 11; while scanning for the next token; found character '\t' that cannot start any token; in 'reader', line 27, column 1: clusterName: "dc1"

    You need to remove any tab whitespaces in your yaml file and replace it with 4 spaces instead.

    See the answer here for why this is common when manipulating YAML files. A YAML file cannot contain tabs as indentation