Skip to main content

postgresql

2024


CloudNativePG Recipe 10 - Simulating Production PostgreSQL on Kubernetes with Kind

·9 mins

This article provides a step-by-step guide to deploying PostgreSQL in Kubernetes using the kind tool (Kubernetes IN Docker) on a local machine, simulating a production-like environment. It explains how to create multi-node clusters and use node labels, specifically proposing the node-role.kubernetes.io/postgres label to designate PostgreSQL nodes. The article also demonstrates how to schedule PostgreSQL instances on these designated nodes, emphasizing the importance of workload isolation in Kubernetes environments. Thanks to Kubernetes’ portability, these recommendations apply to any cloud deployment—whether private, public, self-managed, or fully managed.

The urge of “T-shaped” profiles to smooth the challenges of running Postgres in Kubernetes

·12 mins

As Kubernetes celebrates its tenth anniversary, the integration of PostgreSQL within this ecosystem is gaining momentum, offering challenges and opportunities, rather than threats, for database administrators (DBAs). This article explores the evolution of running PostgreSQL in Kubernetes, emphasising the importance of transitioning from traditional deployment methods to a cloud-native approach. It discusses the need for DBAs to expand their skills beyond the traditional scope, advocating for a “T-shaped” or even “comb-shaped” professional profile. By understanding key Kubernetes concepts and embracing the principles of “slowification”, simplification, and amplification, DBAs can effectively collaborate with developers and infrastructure teams. This approach enhances individual expertise and contributes to the broader adoption and optimisation of PostgreSQL in Kubernetes environments. The article highlights the critical role of community and shared knowledge in breaking down silos and fostering a collaborative culture, which is essential for the successful deployment and management of PostgreSQL in modern cloud-native infrastructures.

Master PostgreSQL in Kubernetes with CloudNativePG at the PostgreSQL European Conference

·2 mins

Join me and PostgreSQL/Kubernetes expert Leonardo Cecchi in Athens on October 22 for the first-ever public training session on CloudNativePG at the 2024 PostgreSQL European Conference, where you’ll master essential day-2 operations for PostgreSQL in Kubernetes. Learn from the founders and maintainers of CloudNativePG through hands-on sessions covering monitoring, scaling, automated failover, and more.

CloudNativePG Recipe 9 - Inspecting the network and the storage in a CloudNativePG cluster

·8 mins

In this blog post, I delve into the crucial aspects of networking and storage within a CloudNativePG cluster deployed on Kubernetes. I explore how Kubernetes services manage external and internal communications for PostgreSQL clusters, ensuring high availability and seamless failover. Additionally, I examine the role of PersistentVolumeClaims in handling PostgreSQL data storage, offering insights into effective resource management. This article provides an example of the kind of knowledge DBAs need to acquire when managing PostgreSQL in cloud-native environments, highlighting the importance of collaboration with infrastructure teams and developers to ensure robust and resilient cluster operations.

Making the world my single point of failure with PostgreSQL

·14 mins

The upcoming CloudNativePG 1.24 introduces a game-changing feature: the ability to declaratively manage PostgreSQL cluster switchover across cloud regions or different Kubernetes clusters. This advancement enables the seamless demotion of a primary cluster and the promotion of a replica cluster in another region without the need to re-clone the former primary. This innovation significantly revolutionises database management practices, enhancing efficiency and reliability in multi-region and multi-cluster environments.

CloudNativePG, traditionally confined to single Kubernetes clusters, is now expanded its functionality to support distributed PostgreSQL topologies across multiple regions. This enhancement leverages declarative configurations to manage coordinated promotions, ensuring a single primary instance at any time. Based on PostgreSQL’s primary/standby architecture, this setup is designed to maintain operational continuity and cater to various deployment scenarios, including hybrid and multi-cloud environments. The new capabilities significantly improve high availability and disaster recovery by mitigating the risks associated with single points of failure in PostgreSQL deployments within Kubernetes.

Kubernetes Just Turned Ten: Where Does PostgreSQL Stand?

·14 mins

As Kubernetes marks its tenth anniversary, its influence on infrastructure management continues to grow. This article examines the increasing adoption of PostgreSQL within Kubernetes, fueled by its extensibility and AI applications. It highlights the journey of integrating PostgreSQL with Kubernetes, focusing on the CloudNativePG operator. A comparison between Kubernetes and traditional VM deployments underscores the advantages for database workloads. The article also calls for greater awareness and expertise in combining PostgreSQL with Kubernetes, aiming to enhance the adoption of this fully open-source stack across the IT landscape.

CloudNativePG Recipe 8: Participating in PostgreSQL 17 Testing Program in Kubernetes

·3 mins

Join the PostgreSQL 17 testing program using Kubernetes and CloudNativePG! With the recent release of PostgreSQL 17 Beta, our community has made operand container images available for testing. This article guides you through deploying a PostgreSQL 17 cluster, selecting specific Debian versions, and verifying installations. Perfect for developers in early stages, your participation will help identify and fix bugs before the final release. Get involved and ensure PostgreSQL 17 is robust and ready for production, even in Kubernetes!

… or thanks to Kubernetes! ;)

16 Years After The Launch of 2ndQuadrant Italy: Remembering Simon Riggs

·7 mins

Sixteen years ago, on May 21, 2008, we proudly announced the opening of the Italian branch of 2ndQuadrant, marking a milestone in PostgreSQL consulting and training in Europe. Simon Riggs, the visionary founder of 2ndQuadrant, placed immense trust in our small team from Prato, Tuscany. Tragically, Simon passed away on March 26, 2024, leaving a profound void. This article is my small tribute to Simon, his extraordinary leadership, and his invaluable contributions to the PostgreSQL community. It reflects on our journey, the challenges we faced, and the innovative spirit Simon instilled in us. Despite his passing, Simon’s legacy lives on through the values, principles, and examples he set, continuing to inspire and guide us.

CloudNativePG Recipe 7: Postgres Vertical Scaling with Storage in Kubernetes - part 2

·8 mins

This is the second article in a series that explores advanced strategies for scaling PostgreSQL databases in Kubernetes with the help of CloudNativePG. This article focuses on horizontal table partitioning and tablespaces and how they can be used to manage large datasets. By partitioning tables based on specific criteria and optimising storage with tablespaces, PostgreSQL users can achieve better scalability and performance in cloud-native environments, just like they could in traditional VMs or bare metal deployments.

CloudNativePG Recipe 6: Postgres Vertical Scaling with Storage - part 1

·8 mins

Are you worried that PostgreSQL cannot scale writes within a single node, or do you think that scaling PostgreSQL can only be done horizontally, across different Kubernetes nodes? Discover the surprising truth behind PostgreSQL’s vertical scalability in this first article of a two-part series. Explore the potential of optimizing CPU, RAM, and storage resources through meticulous measurement and benchmarking, challenging conventional scaling wisdom. Delve into the solid strategies within the CloudNativePG stack, such as separate volumes for data and transaction logs, temporary tablespaces, and I/O segregation for tables and indexes. Stay tuned for insights into aligning storage solutions with PostgreSQL’s resilience needs in the upcoming sequel.