Migrating Mess with DNS to Use PowerDNS
Julia Evans migrated her project Mess With DNS to PowerDNS, addressing DNS issues, improving performance with SQLite, upgrading the frontend to Vue 3, and enhancing user experience in the new version.
Read original articleJulia Evans discusses the migration of her project, Mess With DNS, to utilize PowerDNS, an open-source DNS server with an HTTP API. Initially, the project faced several issues, including improper handling of domain names, CNAME records, and a lack of support for certain DNS record types. To address these problems, Evans decided to replace her original DNS implementation with PowerDNS. The transition involved overcoming various challenges, such as intercepting DNS queries, managing API access, and ensuring clear error messages for users. She also opted to switch from a Postgres database to SQLite to improve performance and reduce memory issues. Additionally, Evans upgraded the frontend framework from Vue 2 to Vue 3 and implemented a global state management store to streamline application state handling. After completing these updates, the new version of Mess With DNS was successfully launched, resolving many of the previous issues and enhancing user experience. Evans expressed satisfaction with the improvements and welcomed feedback on any new problems encountered.
- Julia Evans migrated Mess With DNS to PowerDNS to resolve various DNS implementation issues.
- The transition involved challenges such as intercepting DNS queries and managing API access.
- Evans switched from Postgres to SQLite for better performance and reduced memory usage.
- The frontend was upgraded from Vue 2 to Vue 3, and a global state management store was implemented.
- The new version of Mess With DNS has been launched, improving user experience and addressing past problems.
Related
Serving a billion web requests with boring code
The author shares insights from redesigning the Medicare Plan Compare website for the US government, focusing on stability and simplicity using technologies like Postgres, Golang, and React. Collaboration and dedication were key to success.
Our great database migration
Shepherd, an insurance pricing company, migrated from SQLite to Postgres to boost performance and scalability for their pricing engine, "Alchemist." The process involved code changes, adopting Neon database, and optimizing performance post-migration.
Show HN: Doggo – A powerful, human-friendly DNS client for the command line
The website details Doggo, a user-friendly command-line DNS client. It supports various features like color-coded output, JSON support, multiple protocols, resolver configurations, query options, web interface, shell completions, and cross-platform compatibility.
How to save $13.27 on your SaaS bill
The author discusses managing costs with Vercel's analytics, converting images to reduce charges, and building a custom API using SQLite. They faced deployment challenges but plan future enhancements.
Building an "Easy" Web Application
Rudy Faile transformed a Python utility into a web application using the Bottle micro-framework, overcoming challenges like CORS issues and ultimately focusing on user experience and error handling.
- Users express gratitude for Julia's work and recommend exploring her blog for more insights.
- There are discussions about the challenges faced with the previous Postgres setup, particularly regarding memory issues.
- Several commenters share their positive experiences with PowerDNS and its API, highlighting its reliability.
- Suggestions are made for improving error messaging to enhance user understanding and experience.
- There is curiosity about the use of CoreDNS outside of Kubernetes environments.
In this particular instance I recall the post about DNS some years ago and the callback is amply enriched.
Keep it up @jvns. You hold us all to a high standard.
I noticed that you are using our Go module to access the API. It is wonderful to see our work helping others build great software, especially for education. Thank you for that.
Please note that the upstream API sometimes changes slightly between minor releases. For example, prior to v4.9, the error response for a non-existent server was "Not Found". Starting with v4.9, it changed to "Method Not Allowed".
Unfortunately, error responses aren't always part of the API specification. I'm thinking about adding the most common cases to the module anyway.
You mentioned about your previous version:
> If there was a CNAME record for a domain name, it allowed you to create other records for that domain name, even if it shouldn’t
> you could create 2 different CNAME records for the same domain name, which shouldn’t be allowed
One suggestion... If someone makes a mistake and generates an error, it would be terrific if there were a more verbose explanation so the user may better understand why what they're trying to do won't work. I'm very much a conceptual learner. If I can understand why an error is an error, it puts me on a better path toward a more comprehensive understanding.
Thanks again for all your work.
Found this a little surprising - postgres is internet old - I'm pretty sure it was around at a time when physical servers might not have 256mb of ram?
Seems this should be possible to tune down still? (I mean, maybe not. Postgres 16 isn't postgres 6, and maybe I'm just getting old..)
Given it can read BIND files, surprised BIND is still the default in many places.
You may be able to implement the logging by using a customization of the Sqlite backend, although I think PowerDNS caching may get in your way.
I'll recommend the pipe backend to anyone looking to hack on DNS stuff. It's almost like a DNS lookup via a function in any programming language you choose. It takes a while to figure out how incoming queries are translated though.
Long before Bert was writing articles on the source code of mRNA vaccines, he helped build PowerDNS. He talks about that in a three part series starting here: https://berthub.eu/articles/posts/history-of-powerdns-1999-2...
A fascinating individual...
- dnsdist DNS application aware loadbalancer
- Opera Software dns-ui
Probably you ran out of memory (and configured the database incorrectly).
Related
Serving a billion web requests with boring code
The author shares insights from redesigning the Medicare Plan Compare website for the US government, focusing on stability and simplicity using technologies like Postgres, Golang, and React. Collaboration and dedication were key to success.
Our great database migration
Shepherd, an insurance pricing company, migrated from SQLite to Postgres to boost performance and scalability for their pricing engine, "Alchemist." The process involved code changes, adopting Neon database, and optimizing performance post-migration.
Show HN: Doggo – A powerful, human-friendly DNS client for the command line
The website details Doggo, a user-friendly command-line DNS client. It supports various features like color-coded output, JSON support, multiple protocols, resolver configurations, query options, web interface, shell completions, and cross-platform compatibility.
How to save $13.27 on your SaaS bill
The author discusses managing costs with Vercel's analytics, converting images to reduce charges, and building a custom API using SQLite. They faced deployment challenges but plan future enhancements.
Building an "Easy" Web Application
Rudy Faile transformed a Python utility into a web application using the Bottle micro-framework, overcoming challenges like CORS issues and ultimately focusing on user experience and error handling.