Create Azure Arc-enabled PostgreSQL server using Azure Data Studio
This document walks you through the steps for using Azure Data Studio to provision Azure Arc-enabled PostgreSQL servers.
Prerequisites
Before you can proceed with the tasks in this article, you need to have the necessary tools. All deployments require the following tools:
Azure Data Studio
Azure Arc extension for Azure Data Studio
Azure CLI (
az
)arcdata
extension for Azure CLIkubectl
Additional client tools depending your environment. For a more comprehensive list, see Client tools.
In addition to the required tools, to complete the tasks, you need an Azure Arc data controller.
Note
As a preview feature, the technology presented in this article is subject to Supplemental Terms of Use for Microsoft Azure Previews.
The latest updates are available in the release notes.
Preliminary and temporary step for OpenShift users only
Implement this step before moving to the next step. To deploy PostgreSQL server onto Red Hat OpenShift in a project other than the default, you need to execute the following commands against your cluster to update the security constraints. This command grants the necessary privileges to the service accounts that will run your PostgreSQL server. The security context constraint (SCC) arc-data-scc is the one you added when you deployed the Azure Arc data controller.
oc adm policy add-scc-to-user arc-data-scc -z <server-name> -n <namespace name>
Server-name is the name of the server you will deploy during the next step.
For more details on SCCs in OpenShift, please refer to the OpenShift documentation. You may now implement the next step.
Create an Azure Arc-enabled PostgreSQL server
- Launch Azure Data Studio
- On the Connections tab, Click on the three dots on the top left and choose "New Deployment"
- From the deployment options, select PostgreSQL server - Azure Arc
Note
You may be prompted to install the (
arcdata
) extension for Azure (az
) CLI here if it is not currently installed. - Accept the Privacy and license terms and click Select at the bottom
- In the Deploy PostgreSQL server - Azure Arc blade, enter the following information:
- Enter a name for the server
- Enter and confirm a password for the postgres administrator user of the server
- Select the storage class as appropriate for data
- Select the storage class as appropriate for logs
- Select the storage class as appropriate for backups
- Click the Deploy button
This starts the creation of the Azure Arc-enabled PostgreSQL server on the data controller.
In a few minutes, your creation should successfully complete.
Storage class considerations
It is important you set the storage class right at the time you deploy a server as this cannot be changed after you deploy. If you were to change the storage class after deployment, you would need to extract the data, delete your server, create a new server, and import the data. You may specify the storage classes to use for the data, logs and the backups. By default, if you do not indicate storage classes, the storage classes of the data controller will be used.
- to set the storage class for the data, indicate the parameter
--storage-class-data
followed by the name of the storage class. - to set the storage class for the logs, indicate the parameter
--storage-class-logs
followed by the name of the storage class. - setting the storage class for the backups has been temporarily removed as we temporarily removed the backup/restore functionalities as we finalize designs and experiences.
Related content
-
* In the documents above, skip the sections Sign in to the Azure portal, & Create an Azure Database for PostgreSQL. Implement the remaining steps in your Azure Arc deployment. Those sections are specific to the Azure Database for PostgreSQL server offered as a PaaS service in the Azure cloud but the other parts of the documents are directly applicable to your Azure Arc-enabled PostgreSQL server.
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for