Introducing Crunchy Data Warehouse: A next-generation Postgres-native data warehouse. Crunchy Data Warehouse Learn more

  • PostgreSQL Benchmarks: Apple Intel MacBook Pro, 2011-2019

    Greg Smith

    Apple's Intel-based laptops are very popular among developers, and that's as true of people who work on PostgreSQL as other groups. Tomorrow, the first shipping Apple laptops running on ARM CPUs instead of Intel are expected. That is likely to include at least a 13" MacBook Pro. I decided to prepare for that with a survey of PostgreSQL performance on my small herd of Apple laptops. Mine are all the 15" or newer 16" models. Crunchy Data has already started digging into PostgreSQL on ARM performan...

    Read More
  • 10 min read

    Election Night Prediction Modeling using PL/R in Postgres

    Joe Conway

    I was sent a link to a tweet regarding election night forecasting using R, and of course the default question was ... could it be run under PL/R inside Postgres? Like almost everything at Crunchy Data , we believe all things are better with Postgres. So I decided to give it a shot, and a bit of a database spin as it were. Since I had to get this blog done quickly, it is going to be mostly code -- sorry about that! The code in this blog (please see a small but important correction at the end)...

    Read More
  • Postgres in the Cloud for Django Apps

    Kat Batuigas

    Several weeks ago, we tried our hand at building a basic Dungeons and Dragons player application powered by Django . Last time, we hooked up the app to a containerized Postgres instance. In this post I'll walk through the steps to connect a Django app to PostgreSQL in the cloud via Crunchy Bridge . Note that in this scenario we're not actually taking the original database and moving it to Crunchy Bridge. We may have a follow-up blog post on migrating this existing database but for now we'll...

    Read More
  • 7 min read

    Using PostgreSQL and SQL to Randomly Sample Data

    Steve Pousty

    In the last post of this series we introduced trying to model fire probability in Northern California based on weather data. We showed how to use SQL to do data shaping and preparation. We ended with a data set that was ready with all the fire occurrences and weather data in a single table almost prepped for logistic regression. There is now one more step: sample the data. If you have worked with logistic regression before you know you should try to balance the number of occurrences (1) with a...

    Read More
  • Online Upgrades in Postgres

    James Chanco Jr.

    In our previous blog post, we talked about upgrading a PostgreSQL cluster to a new major version with pg_upgrade . This can be fast and with little downtime even for large databases, but in some instances zero downtime may be essential for doing a major upgrade. This method is called an "online upgrade" and can be achieved through logical replication . While logical replication can help to achieve a zero-downtime, online upgrade, there are still some things to consider. For some hands-on exp...

    Read More
  • Tuning Your Postgres Database for High Write Loads

    Tom Swartz

    As a database grows and scales up from a proof of concept to a full-fledged production instance, there are always a variety of growing pains that database administrators and systems administrators will run into. Very often, the engineers on the Crunchy Data support team help support enterprise projects which start out as small, proof of concept systems, and are then promoted to large scale production uses. As these systems receive increased traffic load beyond their original proof-of-concept s...

    Read More
  • PostgreSQL Monitoring for App Developers: Alerts & Troubleshooting

    Jonathan S. Katz

    We've seen an example of how to set up PostgreSQL monitoring in Kubernetes . We've looked at two sets of statistics to keep track of it in your PostgreSQL cluster: your vitals (CPU/memory/disk/network) and your DBA fundamentals . While staring at these charts should help you to anticipate, diagnose, and respond to issues with your Postgres cluster, the odds are that you are not staring at your monitor 24 hours a day. This is where alerts come in: a properly set up alerting system will let...

    Read More
  • PostgreSQL Monitoring for Application Developers: The DBA Fundamentals

    Jonathan S. Katz

    I am an accidental DBA, with a huge emphasis on "accidental." I came to PostgreSQL as an application developer who really liked to program with SQL and use the database to help solve my problems. Nonetheless, these systems would enter into production, and as such I had to learn to support them. PostgreSQL monitoring and performance optimization is a vast topic . In fact, I'll read content like what my colleague Greg Smith wrote on benchmarking PostgreSQL 13 on Ubuntu and be reminded that I h...

    Read More
  • PostgreSQL Monitoring for Application Developers: The Vitals

    Jonathan S. Katz

    My professional background has been in application development with a strong affinity for developing with PostgreSQL (which I hope comes through in previous articles ). However, in many of my roles, I found myself as the "accidental" systems administrator, where I would troubleshoot issues in production and do my best to keep things running and safe. When it came to monitoring my Postgres databases, I initially took what I knew about monitoring a web application itself, i.e. looking at CPU, m...

    Read More
  • How to Setup PostgreSQL Monitoring in Kubernetes

    Jonathan S. Katz

    You don't need monitoring until you need it. But if you're running anything in production, you always need it. This is particularly true if you are managing databases. You need to be able to answer questions like "am I running out of disk?" or "why does my application have degraded performance?" to be able to troubleshoot or mitigate problems before they occur. When I first made a foray into how to monitor PostgreSQL in Kubernetes , let alone in a containerized environment, I learned that a l...

    Read More