bashazurecommand-linedatabricks

Restarting a cluster on databricks


I'm trying to restart an existing cluster in Databricks on Azure using databricks-cli.

I'm using the following command:

databricks clusters restart {"cluster_id": "0710-121255-liner30"}

But it gives giving me this error

Error: Missing option "--cluster-id".

What am I doing wrong?


Solution

  • You may check the syntax to restart the databricks cluster:

     restart          Restarts a Databricks cluster.
        Options:
          --cluster-id CLUSTER_ID  Can be found in the URL at https://<databricks-instance>/?o=<16-digit-number>#/setting/clusters/$CLUSTER_ID/configuration.
    

    Invalid syntax: databricks clusters restart {"cluster_id": "0710-121255-liner30"}

    Correct syntax: databricks clusters restart --cluster-id 0802-090441-honks846

    enter image description here

    Reference: Azure Databricks - Cluster CLI