Tech ONTAP Blogs
Tech ONTAP Blogs
The open-source PostgreSQL is one of today’s most relied-upon databases. While much of the popularity of PostgreSQL can be attributed to its license-free and open-source nature, it’s also complemented by sophisticated, enterprise-grade features.
How can you get started with your own PostgreSQL database using AWS storage?
BlueXP™ workload factory for AWS now supports automated deployments of PostgreSQL aligned with industry best practices. This blog will provide a step-by-step guide to deploying PostgreSQL via workload factory, explaining all the settings and configurations you’ll need to know.
Read on as we cover:
PostgreSQL is an open-source database, which means it’s license free. Eliminating the high costs of licensing is extremely appealing to large enterprises and small organizations alike. Its robust feature set, including advanced SQL capabilities and support for complex data types, presents a versatility across a wide range of applications.
That’s all part of why organizations are increasingly replatforming databases to PostgreSQL as part of application modernization efforts. Plus, there is a major use case for PostgreSQL with today’s all-important generative AI applications. With extensions such as pgvector, users have a way to leverage PostgreSQL as a vector database. A vector database efficiently stores vector data, which is key to the large language models (LLMs) that AI applications rely on, providing similarity search, recommendation systems, and other AI/ML tasks. Using PostgreSQL as a vector database will give you a place to store embedded data and make it queryable.
Now there’s an easier and more optimized way to deploy PostgreSQL databases. Workload factory is an intelligent optimization and automation service that helps design, set up, and operate key workloads that rely on Amazon FSx for NetApp ONTAP storage. Databases that run on FSx for ONTAP, including PostgreSQL, gain enhanced features that provide instant and lightweight cloning, higher resiliency, and cost optimization.
With its new support for automated PostgreSQL deployment, workload factory makes it easier for organizations to get started with this powerful database so that it follows design principles to make the best use of available resources and to align with industry best practices.
Let’s take a look at how to perform a PostgreSQL host deployment from workload factory.
From the BlueXP workload factory console, go to the Databases option on the menu bar to the left (storage discs icon). From the Databases screen, head to the blue “Deploy database host” button on the right side of the screen. Click it, and select “PostgreSQL server” from the drop-down menu.
You’ll now be in the “Create new PostgreSQL Server” wizard. Here, select the deployment model.
Landing zone
The wizard will next take you to the landing zone screen. Here you’ll provide details of the landing zone for the deployment.
Select the AWS credentials to be used, AWS Region and VPC, Availability Zone, and the security group.
Application settings
Scroll down to the Application setting section. Here, select the PostgreSQL version, set the database server name, and provide your credentials.
Connectivity
In the Connectivity section, select the key pair which is used to securely connect to your instance.
Infrastructure Settings
In the Infrastructure settings section, you’ll see that the information is automatically filled in based on default values and best practices for postgreSQL.
The database instance type has been prefilled with the optimal type, but you have the flexibility to update that if required.
You can either select an existing FSx for ONTAP system or create a new instance for the PostgreSQL server.
By default, your NetApp® Snapshot™ policy is pre-enabled, following a daily snapshot policy with a retention period of seven days.
Next, you can select the data drive size. You just need to enter the capacity, and the wizard will auto-calculate the configurations for data volume, log volume, and other system volumes (LUNs) based on best practices for PostgreSQL. This makes life much simpler for admins, as they don’t need to be experts in FSx for ONTAP to make the right decisions around disk configurations.
For example, the data volume in the screenshot below is configured with 10% headroom, and the log volume is configured as 25% of data volume size (i.e., 35% headroom over total capacity), so the total SSD capacity is configured to accommodate these requirements.
If you’re using an existing FSx for ONTAP system, the provisioned IOPS, throughput capacity, and encryption already set for the file system will be used. However, if you’re creating a new FSx for ONTAP, these settings will be automatically configured based on the best practices (with the option for you to adjust as needed).
The default recommended throughput capacity is 128 MBps, but you have the option to increase it.
Next, you will select the keys to be used to encrypt the database storage.
If you use AWS tags to organize resources, you can add the appropriate key-value pairs next. The max number of tags you can add is 40.
By default, the Simple Notification Service (SNS) is disabled, but you can enable and configure it if required.
Codebox
On the right-hand side of the wizard, you can see the Codebox. This resource automatically generates code that can be used in AWS CloudFormation templates, AWS CLI scripts, or while making Restful API calls to automate deployment of resources.
With Codebox, even administrators without deep expertise in automation can integrate templates in the DevTest tools, eliminating the possibility of errors that could creep in manual deployments.
You also get an option to save the configuration that you have just created, so that you can use it for redeployments.
Summary
In the Summary section of the wizard, the estimated charge incurred by the deployment of the PostgreSQL instance will be shown, along with detailed cost breakdown of compute, storage including the breakdown between FSx for ONTAP and Amazon EBS storage.
And that’s it—your new PostgreSQL database configuration is ready for deployment.
Select the Create button, and your new PostgreSQL database will be up and running. And you didn’t need an expert skill set to configure PostgreSQL, understand the best practices, or calculate the associated costs. Thanks to workload factory the entire process is simple and automated.
Workload factory simplifies and optimizes the deployment and management of PostgreSQL using FSx for ONTAP, offering the following benefits:
It incorporates the best practices for deployment of PostgreSQL using the configuration wizard with pre-configured options. Note that in addition to the prefilled settings, additional configurations such as muti-path IO, 100% SSD configuration, set Snapshot tiering, and more are managed in the backend by default, which sees that best practices are adhered to.
The Codebox feature creates automation templates and scripts that help standardize the deployment process. This helps automate repeated deployments and eliminate manual errors.
Workload factory focuses on the outcome of workloads such as PostgreSQL, abstracting the complexities of the configuration. It democratizes the knowledge of FSx for ONTAP deployment, and hence your team doesn’t need specialized skill sets while deploying PostgreSQL thereby fast tracking the process.
The summary section provides a detailed description of the estimated cost for the resources, and that allows you to explore possible cost savings based on the selected configuration.
Using workload factory to deploy PostgreSQL on FSx for ONTAP provides a robust solution for organizations seeking a high-performance database environment in the cloud that doesn’t require deep expertise or contracting pricey consultancy services. By combining the strengths of PostgreSQL, the efficiency of FSx for ONTAP, and the intelligent automation of workload factory, you can streamline your PostgreSQL deployments, optimize performance, minimize costs, and accelerate innovation on AWS.
Explore the capabilities of workload factory today to unlock these transformative benefits for your PostgreSQL deployments.
Learn more about BlueXP workload factory or get started now.