Azure Database for PostgreSQL

Introduction

Azure Database for PostgreSQL is very powerful, open source, object-relational database system that has the capability of handling workloads ranging from small, single-machine applications, to large Internet-facing applications. It’s a database service based on the open-source PostgreSQL database engine, which offers a fully-managed database-as-a-service and is capable of handling mission-critical workloads with predictable performance, security, high availability, and dynamic scalability.

By using PostgreSQL Community edition, developers can easily lift and shift to the Cloud, using languages and frameworks. PostgreSQL also provides benefit from the unparalleled security and compliance. In this article, I will walk you through creating an Azure database for PostgreSQL on the Azure portal.

Creating an Azure DB for PostgreSQL

Log in to your Azure account, or create a free account if you are new to Azure.

Select the “New+” button on the left side corner of the Azure portal, then choose Databases >> Azure database for PostgreSQL or search “postgre” in the all service search box. This is shown in Figure 1.

Searching PostgreSQL in Azure Services
Figure 1: Searching PostgreSQL in Azure Services

From the Azure database for PostgreSQL server window, click Add. Refer to Figure 2.

Create New PostgreSQL in Azure Portal
Figure 2: Create New PostgreSQL in Azure Portal

Next, start by filling in the server name. Select the subscription level and create a resource group or select an existing one.

Enter the server admin login name, password, and confirm the password details. This server admin login name and password will be required to log in to the server and its databases.

Select the Location and the version number, as shown in Figure 3.

Create New PostgreSQL (Enter all required details)
Figure 3: Create New PostgreSQL (Enter all required details)

Next, click “Pricing Tier”. On the “Pricing Tier” tab, specify the service tier and performance level for your database. I have used basic pricing tier for creating a PostgreSQL database with 1 vCore unit and 5 GB of included storage. You can see this in Figure 4.

Create New PostgreSQL (Pricing tier)
Figure 4: Create New PostgreSQL (Pricing tier)

Click “OK” and click on “Create”. Remember, you also can put a check on “Pin to dashboard” for easy tracking of your deployment on your dashboard.

Next, click “Notifications” on the toolbar to track the deployment progress (see Figure 5).

PostgreSQL DB Creation in Progress
Figure 5: PostgreSQL DB Creation in Progress

After successful deployment, PostgreSQL Server will be created; that is shown in the overview tab. This is depicted in Figure 6.

PostgreSQL DB Deployed Successfully
Figure 6: PostgreSQL DB Deployed Successfully

Next, we have to configure the firewall to connect from the client network. By default, it rejects the connection to the server and the database. To configure the IP, click connection security and then click “Add My IP” to add your IP to PostgreSQL server. Click the save button; your IP is shown under the firewall rules in Figure 7.

PostgreSQL DB Firewall Configurations
Figure 7: PostgreSQL DB Firewall Configurations

Next, on the connection string tab, you will see the various connection strings to connect the created PostgreSQL server and the database from the application you want. Refer to Figure 8.

PostgreSQL DB Connection Strings
Figure 8: PostgreSQL DB Connection Strings

Finally, our Azure database for PostgreSQL Server is created and configured to access from client systems.

Conclusion

That was all about the Azure PostgreSQL server. I hope this article was helpful! That’s all for today; happy reading!

More by Author

Get the Free Newsletter!

Subscribe to Developer Insider for top news, trends & analysis

Must Read