How to launch Databricks web terminal from VS Code

Naruto 61 Reputation points
2023-05-02T18:05:13.6966667+00:00

Hello everyone,

I'm attempting to connect a Databricks web terminal to VS code for remote development because my existing code can only be triggered via CLI commands.

I tried utilising the Databricks VS code extensions, however it does not connect to the Databricks compute terminal. Databricks power tools extensions were also employed, and the results were the same.

Azure Databricks
Azure Databricks
An Apache Spark-based analytics platform optimized for Azure.
2,514 questions
{count} votes

Accepted answer
  1. PRADEEPCHEEKATLA 90,641 Reputation points Moderator
    2023-05-03T09:08:50.47+00:00

    @Naruto - Thanks for the question and using MS Q&A platform.

    Unfortunately, there is no way to connect web terminal using Databricks VS code extension.

    Azure Databricks web terminal provides a convenient and highly interactive way for you to run shell commands and use editors, such as Vim or Emacs, on the Spark driver node. The web terminal can be used by many users on one cluster. Example uses of the web terminal include monitoring resource usage and installing Linux packages.

    Steps to enable the web terminal:

    Go to admin settings => Advanced => Web Terminal: Enabled (Switch toggle ON)
    User's image

    Steps to access the web terminal:

    Go to cluster => Select cluster which is (Running) => Apps => click on Web Terminal to access.

    Now we are able to access the web terminal as shown below:

    User's image

    For more details, refer to Azure Databricks - Web terminal.

    If you want to connect to the Databricks compute terminal using Databricks VS code extension. You can follow the steps metioned here:

    The Quick Start Guide provides an overview of common features.

    The User Guide contains comprehesive documentation about the Databricks extension.

    Summary on how to connect databricks compute terminal using Databricks VS code extension:

    Open VS Code => Install databricks vs code extension => configure extension => create a python file => Attach a running cluster => "Run" icon in the tab bar and select "Upload and Run File on Databricks" => Check the debug console for the output.

    User's image

    Hope this helps. Do let us know if you any further queries.


    If this answers your query, do click Accept Answer and Yes for was this answer helpful. And, if you have any further query do let us know.


0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.