|
| 1 | +--- |
| 2 | +title: 'Quickstart: Create an Azure Data Explorer cluster and database' |
| 3 | +description: 'In this quickstart, you learn how to create an Azure Data Explorer cluster and database, and ingest (load) data.' |
| 4 | +services: data-explorer |
| 5 | +author: mgblythe |
| 6 | +ms.author: mblythe |
| 7 | +ms.reviewer: mblythe |
| 8 | +ms.service: data-explorer |
| 9 | +ms.topic: quickstart |
| 10 | +ms.date: 09/24/2018 |
| 11 | + |
| 12 | +#Customer intent: As a database administrator, I want to create an Azure Data Explorer cluster and database so that I can understand whether Azure Data Explorer is suitable for my analytics projects. |
| 13 | +--- |
| 14 | + |
| 15 | +# Quickstart: Create an Azure Data Explorer cluster and database |
| 16 | + |
| 17 | +Azure Data Explorer is a fast and highly scalable data exploration service for log and telemetry data. To use Azure Data Explorer, you first create a *cluster*, and create one or more *databases* in that cluster. Then you *ingest* (load) data into a database so that you can run queries against it. In this quickstart, you create a cluster and a database. In subsequent articles, we show you how to ingest data. |
| 18 | + |
| 19 | +If you don't have an Azure subscription, create a [free Azure account](https://azure.microsoft.com/free/) before you begin. |
| 20 | + |
| 21 | +## Sign in to the Azure portal |
| 22 | + |
| 23 | +Sign in to the [Azure portal](https://portal.azure.com/). |
| 24 | + |
| 25 | +## Create a cluster |
| 26 | + |
| 27 | +You create an Azure Data Explorer cluster in an Azure resource group, with a defined set of compute and storage resources. |
| 28 | + |
| 29 | +1. Select the **Create a resource** button (+) in the upper-left corner of the portal. |
| 30 | + |
| 31 | +1. Search for *Azure Data Explorer*, then select **Azure Data Explorer**. |
| 32 | + |
| 33 | +  |
| 34 | + |
| 35 | +1. In the lower-right corner, select **Create**. |
| 36 | + |
| 37 | +1. Enter a unique name for your cluster, select your subscription, and create a resource group named *test-resource-group*. |
| 38 | + |
| 39 | +  |
| 40 | + |
| 41 | +1. Fill out the form with the following information. |
| 42 | + |
| 43 | +  |
| 44 | + |
| 45 | + **Setting** | **Suggested value** | **Field description** |
| 46 | + |---|---|---| |
| 47 | + | Cluster name | A unique cluster name | Choose a unique name that identifies your cluster. For example, *mytestcluster*. The domain name *[region].kusto.windows.net* is appended to the cluster name you provide. The name can contain only lowercase letters and numbers. It must contain from 3 to 22 characters. |
| 48 | + | Subscription | Your subscription | Select the Azure subscription that you want to use for your cluster.| |
| 49 | + | Resource group | *test-resource-group* | Create a new resource group. | |
| 50 | + | Location | *West US* | Select *West US* for this quickstart. For a production system, select the region that best meets your needs. |
| 51 | + | Compute specification | *D13_v2* | Select the lowest price specification for this quickstart. For a production system, select the specification that best meets your needs. |
| 52 | + | | | |
| 53 | + |
| 54 | +1. Select **Create** to provision the cluster. Provisioning typically takes about ten minutes. Select **Notifications** on the toolbar (the bell icon) to monitor the provisioning process. |
| 55 | + |
| 56 | +1. When the process is complete, select **Notifications**, then **Go to resource**. |
| 57 | + |
| 58 | +  |
| 59 | + |
| 60 | +## Create a database |
| 61 | + |
| 62 | +You're now ready for the second step in the process: database creation. |
| 63 | + |
| 64 | +1. On the **Overview** tab, select **Create database**. |
| 65 | + |
| 66 | +  |
| 67 | + |
| 68 | +1. Fill out the form with the following information. |
| 69 | + |
| 70 | +  |
| 71 | + |
| 72 | + **Setting** | **Suggested value** | **Field description** |
| 73 | + |---|---|---| |
| 74 | + | Database name | *TestDatabase* | The database name must be unique within the cluster. |
| 75 | + | Retention period | *3650* | The time span for which it's guaranteed that the data is kept available to query. The time span is measured from the time that data is ingested. |
| 76 | + | Cache period | *31* | The time span for which to keep frequently-queried data available in SSD storage or RAM, rather than in longer-term storage. |
| 77 | + | | | | |
| 78 | + |
| 79 | +1. Select **Save** to create the database. Creation typically takes less than a minute. When the process is complete, you're back on the cluster **Overview** tab. |
| 80 | + |
| 81 | +## Run basic commands in the database |
| 82 | + |
| 83 | +Now that you have a cluster and database, you can run queries and commands. You don't have any data in the database yet, but you can still see how the tools work. |
| 84 | + |
| 85 | +1. Under your cluster, select **Query**. |
| 86 | + |
| 87 | +  |
| 88 | + |
| 89 | +1. Paste the following command into the query window: `.show databases`, then select **Run**. |
| 90 | + |
| 91 | +  |
| 92 | + |
| 93 | + The result set shows **TestDatabase**, the only database in the cluster. |
| 94 | + |
| 95 | +1. Paste the following command into the query window: `.show tables`, then select that command in the window. Select **Run**. |
| 96 | + |
| 97 | + This command returns an empty result set because you don't have any tables yet. You add a table in the next article in this series. |
| 98 | + |
| 99 | +## Stop and restart the cluster |
| 100 | + |
| 101 | +You can stop and restart a cluster depending on business needs. |
| 102 | + |
| 103 | +1. To stop the cluster, at the top of the **Overview** tab, select **Stop**. |
| 104 | + |
| 105 | + When the cluster is stopped, data is not available for queries, and you can't ingest new data. |
| 106 | + |
| 107 | +1. To restart the cluster, at the top of the **Overview** tab, select **Start**. |
| 108 | + |
| 109 | + When the cluster is restarted, it takes about ten minutes for it to become available (like when it was originally provisioned). It takes additional time for data to load into the hot cache. |
| 110 | + |
| 111 | +## Clean up resources |
| 112 | + |
| 113 | +If you plan to follow our other quickstarts and tutorials, keep the resources you created. If not, clean up **test-resource-group**, to avoid incurring costs. |
| 114 | + |
| 115 | +1. In the Azure portal, select **Resource groups** on the far left, and then select the resource group you created. |
| 116 | + |
| 117 | + If the left menu is collapsed, select  to expand it. |
| 118 | + |
| 119 | +  |
| 120 | + |
| 121 | +1. Under **test-resource-group**, select **Delete resource group**. |
| 122 | + |
| 123 | +1. In the new window, type the name of the resource group to delete (*test-resource-group*), and then select **Delete**. |
| 124 | + |
| 125 | +## Next steps |
| 126 | + |
| 127 | +> [!div class="nextstepaction"] |
| 128 | +> [Quickstart: Ingest data from Event Hub into Azure Data Explorer](ingest-data-event-hub.md) |
| 129 | +
|
| 130 | + |
0 commit comments