Uploaded image for project: 'HBase'
  1. HBase
  2. HBASE-16044

Fix 'hbase shell' output parsing in graceful_stop.sh

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 2.0.0
    • Fix Version/s: 2.0.0
    • Component/s: scripts, shell
    • Labels:
      None

      Description

      In some of our bash scripts we are piping command in hbase shell and then parsing response to define variables. Since 'hbase shell' output format is changed we are picking wrong values from output Here is example form gracful_stop.sh:

      HBASE_BALANCER_STATE=$(echo 'balance_switch false' | "$bin"/hbase --config "${HBASE_CONF_DIR}" shell | tail -3 | head -1)
      

      this will return "balance_switch true" instead of previous balancer state.

        Attachments

        1. HBASE-16044.master.002.patch
          3 kB
          Apekshit Sharma
        2. HBASE-16044.master.001.patch
          2 kB
          Apekshit Sharma

          Issue Links

            Activity

              People

              • Assignee:
                appy Apekshit Sharma
                Reporter:
                asamir Samir Ahmic
              • Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: