Uploaded image for project: 'Cassandra'
  1. Cassandra
  2. CASSANDRA-14897

In mixed 3.x/4 version clusters write tracing and repair history information without new columns

    XMLWordPrintableJSON

Details

    • Normal

    Description

      In CASSANDRA-14841 I stopped it from writing to those tables so it wouldn't generate any errors. Aleksey pointed out I could write just the old columns.

      If a user manually adds the new columns to the old version nodes before upgrade they will be able to query this information across the cluster. This is a better situation then making it completely impossible for people to run repairs or perform tracing in mixed version clusters.

      This would avoid breaking repair and tracing in mixed version clusters.

      The missing columns can be added by following these instructions
      For 3.0.15 and 3.11.1 and older versions:

      cqlsh> ALTER TABLE system_distributed.repair_history ADD coordinator_port int;
      cqlsh> ALTER TABLE system_distributed.repair_history ADD participants_v2 set<text>;
      

      For 3.0.16 and 3.11.2 and newer:

      cqlsh> INSERT INTO system_schema.columns (keyspace_name , table_name , column_name , clustering_order , column_name_bytes , kind , position , type ) VALUES ( 'system_distributed', 'repair_history', 'coordinator_port', 'none', 0x636f6f7264696e61746f725f706f7274, 'regular', -1, 'int');
      cqlsh> INSERT INTO system_schema.columns (keyspace_name , table_name , column_name , clustering_order , column_name_bytes , kind , position , type ) VALUES ( 'system_distributed', 'repair_history', 'participants_v2', 'none', 0x7061727469636970616e74735f7632, 'regular', -1, 'set<text>');
      cqlsh> exit
      $ nodetool reloadlocalschema
      

      Remember that the INSERT's and nodetool reloadschema must be done on the same node.

      Attachments

        1. 14897.diff
          10 kB
          Ariel Weisberg

        Issue Links

          Activity

            People

              aweisberg Ariel Weisberg
              aweisberg Ariel Weisberg
              Ariel Weisberg
              Jason Brown
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: