News for hackers. Stuff that matters.
Re:Why is DNS still hard to learn? by tristor on Friday July 28, 2023 @01:41PM (#36910427)
I don't agree with this article. I think DNS is something few people take the time to learn, but it's not actually hard to learn. One of the great things about DNS is that the system itself will tell you about it's internal state in response to queries. It's very easy to inspect a DNS server for a known zone and understand how it works, and there's very good tooling that's free and widely available to do this (like dig).

It's always been a big surprise to me that my DNS expertise is what seems to be most memorable for a lot of folks I've worked with through my career, when I don't believe I know anything mystical or special. DNS is extremely well standardized, the most common server and client implementations rigorously follow the standard, and it's very easy to inspect with free tooling. It just takes some effort and time to learn, but it's not really hard.

Re:Why is DNS still hard to learn? by jeroenhd on Friday July 28, 2023 @02:08PM (#36910841)
I think it is hard to learn... using the tools people used to learn DNS with.

BIND is great at what it does, but its configuration files suck and its manual is long, terse, and unnecessarily complex sometimes. Dig is powerful, but abbreviates everything like we're on an 80 column terminal. At times Wireshark was a better tool debugging DNS issues than Dig was.

Give someone PowerDNS or another modern DNS server and I think they'll have a much better time configuring a working DNS server. I don't know a good modern DNS client, so I've learned to deal with Dig instead. As a user of the "--color" flag for the `ip` command, I'd love to see tools like dig produce more modern output (I'll alias the command line flags, just add it to the command!)

Seriously, "MSG SIZE rcvd: 71" did not need abbreviation. "flags: qr rd ra" could've been full words as well. I don't know what the semicolons before the lines are supposed to convey but they're only making things confusing.

I find it no wonder people get confused learning DNS with the materials provided to them.

Re:Why is DNS still hard to learn? by knome on Friday July 28, 2023 @02:22PM (#36911038)
>I don't know what the semicolons before the lines are supposed to convey but they're only making things confusing

all of the lines that aren't part of the query answer are prefixed with semicolons. so it's basically a comment character. presumably to ease processing of the data it spits out.

You know. So you can `dig google.com | grep -v '^;' | grep . | awk '{ print $5 }'` easily.

I can imagine people using it in a shell script 20 years and more ago to grab a list of IPs to do some domain's health check or whatever

Not that you would want to in any modern stack. obviously you'd just use dig's `+short` option :)

Re:Why is DNS still hard to learn? by jeroenhd on Friday July 28, 2023 @02:56PM (#36911518)
Now I just wonder what the double semicolons mean and why they're different from single semicolons :) It's fine, I can Google the answer, I just wished I didn't need to.

I already know to use +short when I just want the result(s). I use it in a script to detect and resolve my Pihole's random freezes (by timing the lookup and rebooting the VM every time a lookup fails or takes longer than 200ms, janky but it works).

Re:Why is DNS still hard to learn? by dclowd9901 on Friday July 28, 2023 @03:14PM (#36911804)
Perhaps there is info that would normally be present and isn’t, hence stacked semicolons.
Re:Why is DNS still hard to learn? by skrebbel on Friday July 28, 2023 @03:50PM (#36912326)
A precision engineering tool shouldn’t make its users guess like that.
Re:Why is DNS still hard to learn? by dclowd9901 on Friday July 28, 2023 @08:20PM (#36915279)
Totally agree.
Re:Why is DNS still hard to learn? by tux1968 on Friday July 28, 2023 @03:41PM (#36912201)
> dig google.com | grep -v '^;' | grep . | awk '{ print $5 }'`

It wasn't really your point, but hopefully you'll forgive me sharing an equivalent one-liner, without grep:

dig google.com | awk '/./ && !/^;/ {print $5}'

Re:Why is DNS still hard to learn? by redundantly on Friday July 28, 2023 @04:06PM (#36912563)
I believe both you and the parent meant to escape the dot, as to only return lines with a dot in them:

     dig example.com | awk '/\./ && !/^;/ {print $5}'
If it isn't escaped it'll just match on everything.

If matching everything was intended then you don't need it at all:

     dig example.com | awk '!/^;/ {print $5}'
Will strip out the lines beginning with a semi-colon.

However, parsing the output of `dig` this way is not needed. It can be ran to only return the answer, for example:

     dig +noall +answer example.com
Or if you just want the IP for that record:

     dig +short example.com
Re:Why is DNS still hard to learn? by knome on Friday July 28, 2023 @04:18PM (#36912705)
I was actually just using `grep .` to discard empty lines. The `grep -v '^;'` would have only left lines with answers after it discarded lines starting with `;`. That and the empty lines.

I could have combined `grep -v '^;'` and `grep .` as a nice simple `grep '^[^;]'`

Re:Why is DNS still hard to learn? by redundantly on Friday July 28, 2023 @04:24PM (#36912792)
Ahh. I was working from memory, I forgot about the empty lines it returns. That's what I get for replying from my phone. :)

However, it's still better to just have the `dig` command return only the necessary information via the +short or +noall +answer flags, rather than parsing the full output.

Re:Why is DNS still hard to learn? by pests on Friday July 28, 2023 @05:19PM (#36913484)
Remind me again where this weird syntax came from for passing arguments?
Re:Why is DNS still hard to learn? by wbl on Friday July 28, 2023 @08:41PM (#36915484)
- is allowed in domains
Re:Why is DNS still hard to learn? by knome on Friday July 28, 2023 @09:28PM (#36915806)
dash is only allowed in the middle. labels can't start or stop with it. so it wouldn't affect the command arguments.

    The labels must follow the rules for ARPANET host names.  They must
    start with a letter, end with a letter or digit, and have as interior
    characters only letters, digits, and hyphen.  There are also some
    restrictions on the length.  Labels must be 63 characters or less.
https://www.ietf.org/rfc/rfc1035.txt

it's more likely that in the late 90s they just made up their own argument parsing that they liked and the application has just used that ever since.

Re:Why is DNS still hard to learn? by chefandy on Friday July 28, 2023 @02:29PM (#36911130)
I'd conservatively estimate 90% of the people who make core FOSS software interface decisions haven't had to learn anything technical in an entirely unfamiliar domain where there existing mental models didn't apply in decades. Beyond that, many consider having learned these arbitrary, terse interfaces as a badge of honor, and for some reason thinks that makes them better technologists. I'll bet they'd be even better had they been able to focus on the core concepts rather than trying to get into some systems engineer's head who worked at Berkley in 1984.
Re:Why is DNS still hard to learn? by TheNewsIsHere on Friday July 28, 2023 @04:19PM (#36912715)
I think of this in the same way I think of documentation. I try to write documentation that is as clear as it is concise and well structured. But sometimes that’s just not realistically possible, and expressing information often _has_ to assume some level of familiarity with the underlying concepts.

I’ve never considered DNS to be a complicated technology, and I’ve never considered that tools like dig and the abbreviations they use need to change much. If there’s something that isn’t clear, it’ll be in the man page, a mailing list, Internet based documentation, StackOverflow, etc.

Personally, I value information density, and I don’t mind terseness at all.

That doesn’t necessarily mean I would design some of this stuff the same way, but after more than a decade using it, I feel like changing it now is just an appeal to futility. A tool like dig more or less looks and works the same today as it did 15 years ago, and there’s value in that kind of stability.

Re:Why is DNS still hard to learn? by chefandy on Saturday July 29, 2023 @12:11AM (#36916823)
> but after more than a decade using it, I feel like changing it now is just an appeal to futility

And that's why your learning to use these tools a decade ago was as painful as it was for me 20+ years ago, and so on. Nobody improves it because the only people with the clout to make the changes is too set in their ways to change it, and have come to believe the ridiculous notion that it's beneficial for people to learn it, despite not being related to the actual problem.

I worked in technical roles for the better part of 25 years, including 10 as a back end developer. One of the reasons I got into design was to try and break chains like this, but talking to the FOSS community about design gets nearly zero traction and a whole lot of pushback from folks who think they know a lot more about design than they do. Nothing you do matches the information density of a train schedule in a large city, and those designs are so ubiquitous and intuitive that we take them for granted. That was not always the case— someone decided to lay things out like that at some point because they knew it works be easier and more intuitive for the majority even if it might take some adjustment for existing everyday users. And designers still work to make them better, to this day.

I wrote a tutorial teaching non-technical folks to use a rest API. It required no knowledge beyond familiarity with using web browsers, and ended with people making useful queries with curl. It was short, visual, and effective- I learned that multiple non-profits at the time used it in their materials to teach folks technical literacy. Just because using a bunch of terse jargon is easier for developers to write and acceptable for other developers to read doesn't mean it's optimal... Or even good. Especially when the realm world be much more accessible to non-technical people if it was designed better.

Re:Why is DNS still hard to learn? by dahfizz on Friday July 28, 2023 @05:03PM (#36913286)
I disagree.

The CLI is inherently a super-user oriented interface. The CLI needs to let an experienced user be as productive as possible.

If you need a pretty UI with everything spelled out, you should go on GitHub and find a GUI that someone built on top of the core tool. But dumbing down the core tool is not the way to go.

The --help message should be good, and the man page needs to be good, but the tool itself should favor power and productivity over handholding someone who doesn't want to Google a how-to.

Re:Why is DNS still hard to learn? by tmpX7dMeXU on Friday July 28, 2023 @06:22PM (#36914162)
This is full of false dichotomy. Making things more understandable isn’t “dumbing them down”. There isn’t necessarily a trade-off. An application being CLI-based is not a get out of jail free card for UX critiques, nor is it an implication that it’s for power-users. You can’t just put the minimum viable effort into considering how someone will use your software without any thought to intuitive mental models and cry “it’s for power users”.

Old-school FOSS nerds have a hard time admitting that they tend to be absolutely useless at considering user experience, because then that’s something On Computers that they’re not good at. The best they can do is shoo it away by claiming that the sort of UX concerns I’m talking about only apply to software used by Lesser Beings and not Smart Computer Boys such as themselves.

It’s such an outdated user-hostile boys club attitude fuelled by insecurity and misplaced and not even well-thought-out elitism, and I’ll never pull any punches when talking about it.

Re:Why is DNS still hard to learn? by hitpointdrew on Friday July 28, 2023 @06:47PM (#36914400)
> nor is it an implication that it’s for power-users.

Yes it is. As an administrator being a CLI tool means that I can automate configs and deployment with ansible or Nix OS. I would argue doing these sorts of automation what are what “power-users” would do.

GUI’s often lack any sort of automation capability or have some half-cocked API that usually lacks features or endpoints that would be trivial if the thing was just a CLI tool with a config file.

Re:Why is DNS still hard to learn? by chefandy on Friday July 28, 2023 @11:32PM (#36916595)
Good interface design absolutely does not require a gui. When I first encountered a BSD distro that used ports, that was a huge interface improvement. Then Deb or whatever beyond that.

Using sane labels and coherent layouts isn't dumbing anything down. You can make things easier for humans while having sane interfaces for scripting. Redirecting the output of `ls` and similar commands automatically change the layout to something easy for cli i/o manipulation.

We realized long long ago that the API and human-facing interfaces are often better when separated, which is why I don't browse the web with curl... or maybe telnet.

Re:Why is DNS still hard to learn? by pravus on Saturday July 29, 2023 @09:43AM (#36920247)
> Old-school FOSS nerds have a hard time admitting that they tend to be absolutely useless at considering user experience, because then that’s something On Computers that they’re not good at.

New-school FOSS nerds don't seem to understand that all poor user experience concerns are because we are trying to be productive. The new style of of reduced information density and easy-to-remember names isn't useful when you are paid to have production systems up and running. What I need are tools that give me the exact information I need quickly and get the fuck out of my way for everything else.

> It’s such an outdated user-hostile boys club attitude fuelled by insecurity and misplaced and not even well-thought-out elitism, and I’ll never pull any punches when talking about it.

Most people that complain about this put the minimal viable effort into actually learning what they are doing. Somehow I'm the idiot after spending hours of my life to learn this professionally and for wanting expert interfaces. You can call me elite all you like but when the whirlpool of disaster is pulling us both under, I'll be in my elite raft surfing the waves while you struggle.

Re:Why is DNS still hard to learn? by chefandy on Saturday July 29, 2023 @11:57AM (#36921489)
I've been using Linux for 25 years, spent 6 or so years doing administration type work on large Unix systems and spent 10 years in a back-end developer role. I've somewhere in the high five figure range of hours spent contributing to FOSS software. More recently, I've gotten formal interface design education and worked in design roles. I am not a 'new school' FOSS nerd by any measure.

> New-school FOSS nerds don't seem to understand that all poor user experience concerns are because we are trying to be productive. The new style of of reduced information density and easy-to-remember names isn't useful when you are paid to have production systems up and running.

The reason you find them more productive is because you already know how to use them. Needlessly reduced information density is usually a bandaid applied to a shitty, confusing interface by a non-designer because they don't know how to organize it to be easily parsable, but still dense. Maybe denser than before. You don't even realize when a good designer has done a good job because it just makes sense— it's so intuitive and useful to cite users that you don't have to think about it. If it it's a utilitarian tool that "looks designed," it was probably a non-designer trying to gussy it up, or "work on UX" without realizing that means a lot more than white space, colors, and fonts. A solid understanding of visual hierarchy would solve at list half of FOSS interface problems without changing anything other than layout. The problem is project maintainers who think any attempt to remediate their non-designed cobbled-together interface is an attack by the 'new school' or what have you and either dismiss it out of hand, or reflexively bikeshed any proposal into oblivion because they're defensive, and lack the design sophistication to knowledgeably engage. As a senior developer and someone who enrolled in art school as an adult, I know how much more defensive people get about work they're not confident in. When those people are in charge of a project AND have the misguided notion that their "design" (read as cobbled-together assembly of user-facing functionality) is more functional than an expert's design, just uglier, good luck pushing change through.

> Most people that complain about this put the minimal viable effort into actually learning what they are doing. Somehow I'm the idiot after spending hours of my life to learn this professionally and for wanting expert interfaces. You can call me elite all you like but when the whirlpool of disaster is pulling us both under, I'll be in my elite raft surfing the waves while you struggle.

And fraternities keep paddling pledges and making them drink gallons of grain alcohol because they all had to do it too, so everybody else should. Complaining that nobody wants to spend time studying something that they wouldn't have to if it was properly designed is an asinine argument against progress. The only people here who should be chastised for refusing to learn new things are the people who refuse to consider better approaches and insist everybody else learn the same inscrutable incantations they did, because it's easier for them... Because they already know them. Just because you can't imagine productive ways to update these tools to a post-teletype world doesn't mean that nobody can.

Re:Why is DNS still hard to learn? by pravus on Saturday July 29, 2023 @06:27PM (#36925391)
> I've been using Linux for 25 years, spent 6 or so years doing administration type work on large Unix systems, and spent 10 years in a back-end developer role. I've somewhere in the high five figure range of hours spent contributing to FOSS software. More recently, I've gotten formal interface design education and worked in design roles. I am not a 'new school' FOSS nerd by any measure.

If you have trouble with tools like dig, you have wasted a lot of fucking time.

Re:Why is DNS still hard to learn? by chefandy on Saturday July 29, 2023 @10:10PM (#36927079)
Edgy. Asserting that my deep consideration and professional concern with usability means that I don't understand the software is the most deliberately obtuse thing I've read this week, and I browsed Slashdot comments.

Measuring usability by your own comfort level is the reason user-facing "open source alternatives" that aren't foundation-backed with dedicated designers will remain "alternative" in perpetuity.

Re:Why is DNS still hard to learn? by sdf4j on Friday July 28, 2023 @06:28PM (#36914226)
I disagree.

I'm a super-user and as such I have to use hundreds of tools to GTD. What you call “pretty UI” I call ergonomics. So I appreciate when the tooling is respectful of my time and don’t require me to visit the man page just because the developer was so situational myopic that thought sparing a few characters was a good idea.

It all smells like unconscious gatekeeping.

Re:Why is DNS still hard to learn? by phist_mcgee on Friday July 28, 2023 @08:45PM (#36915521)
And don't get me started on undocumented parts of CLIs, which are unknown unknowns, especially when they hold core parts of the API.

RTFM is usually (not always) a way to gatekeep bad UX.

Re:Why is DNS still hard to learn? by chefandy on Saturday July 29, 2023 @08:35AM (#36919666)
Right. There USED to be good reasons to have that be the way classic CLI utilities worked— your terminal had 80 character lines, you might be working over a 300 baud modem, you might be using a teletype terminal and you didn't want to waste paper, having machine-focused output and human-focused output was too resource Intensive... All of that is gone now.
Re:Why is DNS still hard to learn? by jodrellblank on Friday July 28, 2023 @09:25PM (#36915779)
You are seriously taking the position that writing “received” instead of “rcvd” is “dumbing down”?
Re:Why is DNS still hard to learn? by washadjeffmad on Sunday July 30, 2023 @04:43PM (#36935757)
Someone who knows what information to expect doesn't even need a label. Once you're past that hurdle, it's redundant.

For instance, you look at the dash of your car every time you drive, and what little is labeled is abbreviated. The expectation is that when you understand how the vehicle operates, the gauges and lights will make sense. The information is encoded behind your knowledge. dig isn't really different.

Some people want the tools to teach them everything, but that's just not appropriate or necessary, whether you're talking about a hammer, a firearm, or a computer.

Re:Why is DNS still hard to learn? by chefandy on Sunday July 30, 2023 @11:56PM (#36938658)
KPH/MPH are ubiquitous standard abbreviations that exactly zero percent of people encounter for the first time when they drive for the first time. Occasional and brand new drivers will never not know what those things mean. Kilometers Per Hour is also 600% larger than KPH, and visual clutter while driving at highway speeds is a much bigger problem than when examining DNS records.

> Once you're past that hurdle, it's redundant.

Yeah, then multiply that hurdle times the thousand others someone has to memorize to work in *nix.

> Some people want the tools to teach them everything, but that's just not appropriate or necessary, whether you're talking about a hammer, a firearm, or a computer.

Textual output on a computer is a communication medium-- hammers and firearms are not.

Re:Why is DNS still hard to learn? by chefandy on Saturday July 29, 2023 @12:22AM (#36916878)
A) dumbed-down interfaces are bad design; Most you see were made by developees trying to be designy. No shade— it's a different profession with relevant degrees and career paths, and most designers would make terrible code if they tried. B) Good interface design absolutely does not require a gui. I've been professionally using (and loving) these tips for decades, but many cross the border from negligent to user hostile. C) Download SideFX HOUDINI, which has a nice pretty interface and is fully scriptable with python and it's own language, vex, and tell me that's "dumbed down."
Re:Why is DNS still hard to learn? by chefandy on Saturday July 29, 2023 @08:28AM (#36919613)
*Loving these tools for decades
Re:Why is DNS still hard to learn? by j16sdiz on Friday July 28, 2023 @02:44PM (#36911341)
BIND expose (almost) every details of DNS. That's why learning their config would teach you 90% of the DNS system.

dig output make sense after reading the RFC. It exposes every bit flag in the protocol level

Re:Why is DNS still hard to learn? by jeroenhd on Friday July 28, 2023 @02:59PM (#36911547)
I have read the RFC. I just don't mess with DNS often enough that I know all the RFC definitions from the top of my head, and I don't want to need to find the appropriate RFC(s) every time I want to debug an issue.

It's not as if tools like wget bother you with http/3 spec fields every time you download something from the internet unless you explicitly ask for them, and even if they do, they're more descriptive than just the shortcode coming from a diagram in the RFC.

Re:Why is DNS still hard to learn? by bombcar on Friday July 28, 2023 @05:01PM (#36913267)
>I just don't mess with DNS often enough

That's the root of all this, we only deal with DNS when something breaks, and it rarely breaks.

If we did DNS all day every day it'd all be super clear and concise.

Re:Why is DNS still hard to learn? by mst on Saturday July 29, 2023 @04:14AM (#36918062)
I learned DNS a bit over 20 years ago running a BIND deployment that was authoritative for somewhere over 30k customer domains.

I still tend to use nslookup over dig (yes, I know, bad mst) because I got sufficiently used to the former that I barely notice it's even there when using it - my fingers and brain are so used to it that the interface part of nslookup is mentally invisible (though I always teach other people 'dig' and 'host' instead).

I'm not sure learning it that way was exactly easier, but being (somewhat, that was far from the only service I was responsible for) immersed in it meant I at least got through the initial mental scrabbling in a relatively compressed time frame, and once you've got a coherent model built in your head life is easier.

I think this is really a very long way to say "based on doing DNS most days for a few years, I strongly suspect you're right."

Re:Why is DNS still hard to learn? by bombcar on Saturday July 29, 2023 @09:40AM (#36920206)
Yep, and the other thing is that something like 90% of DNS is "I need to update a A record or a CNAME or a AAAA (rare)" and then waiting for caches to expire.

But that's only like 10% of DNS's surface area, there's tons of other things it can do and rarely does, but if you have to make that stuff work you can get deep in the weeds fast.

Re:Why is DNS still hard to learn? by j16sdiz on Friday July 28, 2023 @02:48PM (#36911409)
rcvd, qr, rd, ra

are defined in the RFC. It need the abbreviation to fit in the ASCII art in RFC text.

back in those days, dig users are those who read rfc

Re:Why is DNS still hard to learn? by jeroenhd on Friday July 28, 2023 @03:08PM (#36911724)
I can see that they were truncated in the block diagram, but they were also explained with one or two words just lines below that. RFC1035 calls them "query"/"response", "authoritative answer", "Truncation", "Recursion Desired", "Recursion Available", and CD/AD become "Checking Disabled" and "Authentic Data".

dig already translates things like record types from integers to strings, why not use the full, descriptive names for these flags as well? Why shouldn't I be able to dig +pretty domain.example?

I suppose dig is mostly maintenance mode these days, but it's quite annoying to see so many tools rely on it when it's so... 90s.

Re:Why is DNS still hard to learn? by alphager on Friday July 28, 2023 @08:31PM (#36915390)
You've gut the nail on the head: dig was designed with the needs of the 90s in mind, where terseness was a virtue (if your ram can be usefully conveyed in kilobytes, you need terse tools).

Due to backwards compatibility, the output won't be changed. Due to backwards compatibility, stuff is the tool that's installed by default.

Both can't be changed (it would break too many assumptions many scripts and programs have).

However, there are multiple dig alternatives. You just have to install them.

Re:Why is DNS still hard to learn? by mst on Saturday July 29, 2023 @04:24AM (#36918123)
I liked jvns' suggestion to add a +human option - plenty of tools have a -h output option which is nicer for quick interactive use, and I value their existence (e.g. I use both 'du -h' and 'du -k' semi regularly depending on if I want to read the results or throw it through an analysis script).
Re:Why is DNS still hard to learn? by zehemer on Friday July 28, 2023 @03:21PM (#36911910)
> As a user of the "--color" flag for the `ip` command, I'd love to see tools like dig produce more modern output

https://github.com/ogham/dog is pretty good in that regard

Re:Why is DNS still hard to learn? by zhfliz on Saturday July 29, 2023 @09:05AM (#36919907)
wow, didn't know about `ip --color`, that's awesome
Re:Why is DNS still hard to learn? by manuel_w on Friday July 28, 2023 @05:32PM (#36913650)

  $ ip address --color
  Command "--color" is unknown, try "ip address help".
Re:Why is DNS still hard to learn? by matteotom on Friday July 28, 2023 @05:34PM (#36913676)
try

> ip --color address

otherwise you might just have an old version

Re:Why is DNS still hard to learn? by manuel_w on Friday July 28, 2023 @05:39PM (#36913726)
That helped, thanks!
Re:Why is DNS still hard to learn? by synergy20 on Friday July 28, 2023 @06:10PM (#36914033)
or: ip -c -br a which is: ip --color --brief address add -4 if only ipv4
Re:Why is DNS still hard to learn? by mst on Saturday July 29, 2023 @04:21AM (#36918106)
Some CLI apps with subcommands accept top level options anywhere in the arguments, some - like 'ip' - expect

    <command> <command options> <subcommand name> <subcommand options> <arguments>
The advantage of that approach is that you don't have to worry about naming collisions between the command and subcommand option sets, which can be really handy - especially in applications with pluggable and/or user supplied subcommands, so you can add top level options without worrying about breaking somebody else's extensions.

The disadvantage is, well, what just happened to you.

(note that I personally really like the pedantic approach because it fits my brain, but I'm -not- trying to endorse it as better in general since it's very definitely a trade-off and one that often isn't a good one overall)

Re:Why is DNS still hard to learn? by dataflow on Friday July 28, 2023 @05:35PM (#36913682)
To the extent I learned DNS, it was via nslookup, definitely not dig.
Re:Why is DNS still hard to learn? by firexcy on Saturday July 29, 2023 @06:11PM (#36925234)
I think old CLI tools are hard to use because they were designed to be machine- and human-readable at the same time. They are effectively APIs in some scenarios (e.g., scripting and as linked libraries) and in others handholds. As a result they are restricted to be barely viable as either.
Re:Why is DNS still hard to learn? by Vaslo on Friday July 28, 2023 @02:29PM (#36911135)
You have the curse of knowledge my friend. It’s hard to learn and way more complicated than it needs to be.
Re:Why is DNS still hard to learn? by neilk on Friday July 28, 2023 @02:24PM (#36911072)
How did you learn DNS? And when?
Re:Why is DNS still hard to learn? by tristor on Friday July 28, 2023 @02:39PM (#36911272)
I had a slow day at work in the beginning of my career (I was a help desk monkey then) and I wanted to learn more about how Active Directory actually worked. One of the things that I found out and became more curious about was why DNS was so critical for Active Directory, upon where I discovered the magic of SRV records. After that I decided I wanted to learn DNS in detail, so I read the RFCs, poked around with nslookup and dig, and then set up a local copy of BIND on a Linux VM to experiment with. In the numerous intervening years I've picked up more over time and been involved in numerous situations where I had to assist someone by doing DNS spelunking, often learning something in the process. I jumped from being a help desk monkey to being an L2 sysadmin in my very next job largely on the basis of my DNS and Active Directory knowledge, all of which was learned by reading documentation and poking at things, nothing particularly difficult about either.

What always causes challenges is weird edge cases, but if you understand how things are supposed to work at a protocol level you have the basis of knowledge to troubleshoot the edge cases, which is how you learn about the more esoteric or implementation specific behaviors of things. I wouldn't expect anyone to particularly have deep knowledge of AD or DNS edge cases, but the basics of how they work aren't particularly hard knowledge to acquire and it's a constant surprise to me how few tech people understand DNS in particular, since it's a critical system for nearly every aspect of modern computing.

Re:Why is DNS still hard to learn? by Terretta on Friday July 28, 2023 @02:30PM (#36911153)
> How did you learn DNS? And when?

I wrote one of the world's first dynamic DNS servers for our dialup modem customers in the early 90s, so when connected to our Livingston Portmasters with an assigned IP address you could be username.isp.com while online.

Later updated this so you could also be http://www.username.isp.com all the time just by dropping an index.html file in your ~username/site directory.

I learned both by spelunking BSD, reading man pages, and rapid prototyping in Perl. So I'm with tristor, it felt relatively straightforward.

// I don't say I wrote the first because I don't know. I am not aware of any other regional or national commercial dialup ISP in the U.S. that offered this before we did.

Re:Why is DNS still hard to learn? by j16sdiz on Friday July 28, 2023 @02:50PM (#36911447)
Same here.

I implemented some dynamic dns system. I still remember how to handcraft a RRUPDATE request.

After reading the RFC, every bit in dig output makes sense

Re:Why is DNS still hard to learn? by mst on Saturday July 29, 2023 @04:32AM (#36918171)
It would, however, be nice if there was a tool (or, as jvns proposes, a +human option to dig) that provided output oriented to somebody who's just trying to -use- the thing rather than reading the RFC first.

(I'm very much a "read the RFC first by default" sort of person because that approach fits my brain, but I don't think everybody should have to do that for relatively simple day to day stuff)

Re:Why is DNS still hard to learn? by dahfizz on Friday July 28, 2023 @04:32PM (#36912902)
I was tasked with setting up & maintaining a dnsmasq server in college, which handled DNS, DHCP, and pxe booting.

I learned it like anything else. Googled it, read the docs, and trial & errord my way into a working setup. I was comfortable with all the technologies in a couple weeks (working part time).

Re:Why is DNS still hard to learn? by WarOnPrivacy on Friday July 28, 2023 @04:49PM (#36913109)
Setup an in-house server to sinkhole malware requests.
Re:Why is DNS still hard to learn? by mrweasel on Saturday July 29, 2023 @03:48AM (#36917904)
For me: Volunteer systems administration for a student organization. We had a subdomain under the domain of the university and wanted to add another one. We already had Bind configured with an A and MX record. No one really wanted to deal with it, so I asked some people I knew, who recommended that given we already ran qmail, then maybe tinydns would be the best option.

So I installed tinydns, read the documentation, experimented with the subdomain we didn't use yet. Took a few tries, but not really difficult.

Later one we added more stuff, like zone transfers, all of it is pretty easy once everything is running.

One of the things that scare people away from running DNS servers is Bind and it's configuration language, it's not great. You just don't have to use Bind, or you can switch to it once you understand the concepts of DNS better.

Re:Why is DNS still hard to learn? by dogleash on Friday July 28, 2023 @02:49PM (#36911435)
> I think DNS is something few people take the time to learn

I kinda agree and think DNS one of those technologies where you can go an entire career without picking up more than bits and peices here and there. Those things gains a sense of mystique in industry as more complicated than it otherwise would if more people had to tackle it full on.

Re:Why is DNS still hard to learn? by WarOnPrivacy on Friday July 28, 2023 @04:43PM (#36913039)
> I kinda agree and think DNS one of those technologies where you can go an entire career without picking up more than bits and peices here and there.

As far as that's true it's weird, because DNS basically does one straightforward thing. But then you get into all the places where that one thing has to be done in different ways.

Where I wouldn't mind some more magic is with reverse DNS. Too many tables don't know a name pointing to an IP until something tries to resolve that name.

Reliably historical rdns would be even more awesome but that's more of a service than a spec thing.

Re:Why is DNS still hard to learn? by josho on Friday July 28, 2023 @02:58PM (#36911544)
If you read the article the author points out why it's hard to learn. The concept is easy, but when teaching the concepts we don't include all the details of the modern internet.

As an example what are the rules that your browser uses to cache and expire DNS entries? Are those rules consistent between browsers?

Re:Why is DNS still hard to learn? by antonjs on Friday July 28, 2023 @03:37PM (#36912153)
And does your browser have settings which bypass or supplement the host's DNS configuration. Secure DNS (DoH etc) is great, but damn that's confusing when you first run across it. Not to mention how phones do it; you can't override a DoH DNS server when connecting to a VPN which offers internal DNS on Android, for instance.
Re:Why is DNS still hard to learn? by TheNewsIsHere on Friday July 28, 2023 @04:25PM (#36912798)
Aren’t all of those concerns out of scope for DNS itself, though? DNS can only give you a TTL, for example, it cannot require you follow it.

Ideally that’s what RFCs are for, but even organizations that pay smart people to come up with clever standards don’t always follow them. Implementations frequently disregard or guess about the things standards cover.

Re:Why is DNS still hard to learn? by tikhonj on Friday July 28, 2023 @04:47PM (#36913088)
From the point of view of the standard, maybe, but not from the point of view of somebody learning or using DNS.
Re:Why is DNS still hard to learn? by TheNewsIsHere on Friday July 28, 2023 @04:54PM (#36913178)
I don’t disagree, and I think that’s why we need to make it clear that there’s a difference between implementation and standard.

My education is a mix of formal and autodidactic. One of the best things I got from formal education is the structured introduction to fundamentals like the OSI model.

If you don’t have that kind of foundation, it can be much, much harder to understand the “why” of the endless differences between documented standards and in-the-wild implementations. It’s good to know where you are in the stack to help inform what you’re seeing.

Re:Why is DNS still hard to learn? by WarOnPrivacy on Friday July 28, 2023 @04:36PM (#36912954)
> you can't override a DoH DNS server when connecting to a VPN which offers internal DNS on Android, for instance.

True. I set my VPN server to force DNS thru the tunnel to an intercepting DNS server - and it replies as if it were the intended DNS server.

DNS server is setup this way in response to LAN devices that have their own DNS configured, but it handles Android's private DNS too.

Re:Why is DNS still hard to learn? by f1shy on Friday July 28, 2023 @03:19PM (#36911895)
Absolutely agree. Back in the days, I was very inexperienced, I was thrown to the task of administering DNS (with BIND) and Sendmail. I had 100+ servers. The first couple of month was a lot of reading, and understanding things, but relatively fast I got a good understanding of it. After 6 month I was teaching DNS to other teams in other countries for the same company. It was not at all hard. I'm a very average engineer, and from 0 to explaining to others in 6 month, is by no means a difficult topic.
Re:Why is DNS still hard to learn? by pessimizer on Friday July 28, 2023 @04:39PM (#36912993)
DNS isn't at all hard, it only takes two months to learn when you're being paid to, and after only 6 months you'll be knowledgeable enough to teach!

> from 0 to explaining to others in 6 month, is by no means a difficult topic.

You should have seen almost anything else. Many things can be learned within days.

Re:Why is DNS still hard to learn? by jvns on Friday July 28, 2023 @06:57PM (#36914493)
Hello! I wrote this post and I have a couple of things to say about this "DNS is not actually hard" take. It took me many years to feel totally comfortable debugging DNS problems, and I wrote this post to explain why I think it was hard for me.

I also used to think that "no, actually, it's easy!" was an encouraging response to "this is hard to learn". And I kind of get it! I love DNS! I think it is surprisingly simple in many ways, and I've written about that a lot, for example in https://implement-dns.wizardzines.com which shows you how to implement a toy DNS resolver from scratch in some pretty simple Python code.

But over the years I've learned that "no, it's easy to learn!", instead of coming off as an encouraging comment ("you can do it!"), often gets received as "no, it's not hard, actually the problem is that you're dumb". Like, I've been confused about this for years, and you're telling me that, no, actually it's easy? Not that helpful!

So I've stopped telling people that, and instead I put a huge amount of work into trying to understand _why_ people find certain things hard and work to help remove some of those barriers.

Re:Why is DNS still hard to learn? by anyfoo on Friday July 28, 2023 @07:20PM (#36914710)
Maybe everyone sees this differently? Or maybe is more than one viewpoint to it.

For example, if someone tells me that something is "actually really simple", and I did not get it yet, I tend to think that I likely (not certainly, but likely) have not found the right approach to that something yet, and once I found that way to look at it, things will resolve itself.

But if people assure me that something is "hard to learn" or "hard to get", I'm rather suspecting that that thing is full of unwieldy complexity and/or unintuitive aspects, and unless I'm either up for the challenge (definitely the case sometimes), or learning it is crucial for achieving a certain goal (in which case it may turn out to be fun after all, even if still hard), I might think twice if I want to put the time and energy into it.

In the case of DNS, which I've learned in the nineties, I found the principle simple and elegant, the tools and software unwieldy and sometimes arcane, and a large multitude of little details that are not strictly necessary for understanding and using DNS in basic ways, but that can get important when either debugging or working at scale.

So, in the case of DNS, I'd say the answer is "depends on how deep you want to go", but don't shy away from the simple and elegant principle, even if the arcane software (it has gotten better, though) stands in the way.

I think that matches the content of your article overall?

Re:Why is DNS still hard to learn? by saghm on Friday July 28, 2023 @08:33PM (#36915410)
> Maybe everyone sees this differently? Or maybe is more than one viewpoint to it.

> For example, if someone tells me that something is "actually really simple", and I did not get it yet, I tend to think that I likely (not certainly, but likely) have not found the right approach to that something yet, and once I found that way to look at it, things will resolve itself.

At least in my experience, people asserting that something lots of people have trouble understanding is "not hard" are doing so as a flex at least as often as they are trying to be helpful, so I'm surprised that a lot of people don't make the same hypothesis you do. When someone does so while also touting their status among their peers due to their knowledge and talking about how anyone could do it by just putting in the work, it's not surprising that people might interpret that as implying that people who don't have the same knowledge are either too lazy to put in the effort or not capable of it, regardless of whether that was the intended message. If the goal is to try to help people, it's more effective to communicate in a way that conveys understanding and not judgment; if someone doesn't care to improve their methodology of helping people, that's fine, but it does raise more doubts about whether they're being honest about their intentions.

Re:Why is DNS still hard to learn? by zhte415 on Friday July 28, 2023 @11:25PM (#36916556)
Your post reminds me of three things -

The nature of what's being learnt. Some things require a continuity - to understand B, prior A is needed (or helps, to understand faster).

The method of learning. Book/theory-based, or practical? For either, what's the nature of scaffolding (self, or via resources) to help leap the chasm? If testing one's self, what's the complexity and can that complexity be broken down into simpler (or more discrete) parts, (perhaps testing working better in smaller parts)? Perhaps A isn't fully (or at all) required to 'know' B, depending on how it's learnt. Which goes on to -

The nature of the learner. Someone that's looking to solve a task, somewhat surface, or someone that's interested and will go deeper into edge cases or approach with greater curiosity?

[I'm skipping the nature of the learning/knowledge, since 'resolving DNS' is a pretty externally verifiable result. However it might be fruitful to consider the nature of the learning is not only 'resolving DNS', and even if 'resolving DNS' fails, learning always happens (intended/unintended, positive/negative, a can of worms there).]

You point out that 'easy' and 'hard' are motivators that might have unexpected, or the reverse, effects vs. intended, depending on the reader. When putting it into those 3 parts, perhaps this shows the usefulness of framing.

Re:Why is DNS still hard to learn? by vasco on Saturday July 29, 2023 @07:35AM (#36919208)
> anyone could do it by just putting in the work, it's not surprising that people might interpret that as implying that people who don't have the same knowledge are either too lazy to put in the effort or not capable of it

Not spending time on something doesn't mean you're lazy or stupid, that seems like your own leap. If you choose to interpret in a charitable way it just says: "if you haven't looked here don't worry, it's not that hard, you'll just need to spend some time".

I haven't looked under many rocks I've walked by, talked to everyone, read every book I encountered, doesn't mean I'm stupid or lazy, I just haven't done it.

Re:Why is DNS still hard to learn? by saghm on Saturday July 29, 2023 @05:23PM (#36924793)
My point is that if your goal is to teach people, you should care about framing things in a way that's conducive to the people who you want to teach. Dismissing fairly common insecurities because you don't happen to have them will significantly reduce your effectiveness at teaching, and if you don't find it worth the time to take into account feedback about how to craft your messaging more effectively, I'd argue that your priority never really was teaching in the first place.
Re:Why is DNS still hard to learn? by riffic on Friday July 28, 2023 @08:44PM (#36915504)
an aside your content is top notch in quality and I always point to your site(s) when I want to share how this stuff works with an easy explainer. You make it seem easy :)
Re:Why is DNS still hard to learn? by 13of40 on Friday July 28, 2023 @09:30PM (#36915827)
Just my 2 cents: I worked on the DNS in Windows Server back in the 200x's (validating the UI and back-end functionality, not dev work), so I did have to learn about it at one point and I recall that there was a vicious level of complexity to it compared to what we ask it to do. The 99% scenario is turning a domain into an IP via an A record. Next after that is doing the same with an MX record. Beyond that is this deep well of other things people thought someone might want to do with DNS, but that almost nobody takes advantage of in real life. So DNS is probably easy to understand if you're just concerned about the one or two first class scenarios, but if you had to implement an RFC-correct instance of a DNS server, it's a bit of a brain melter.
Re:Why is DNS still hard to learn? by syntheweave on Friday July 28, 2023 @10:09PM (#36916097)
This is the comment I wanted to make. DNS is one of those technologies that has a simple explanation - "it's indirection" - with consequential ramifications that turn it into someone's job. Most people will not interact with it often enough to know how to perform the job, so they remain hesitant and try not to do anything at all with it, because it burned them once before.

Git is analogous - most uses of Git are formulaic, and the underlying concepts are simple enough - but actually accessing the right lever to pull when disaster strikes is unclear and hard to experiment with. I'm in this latter category with DNS: I get it at a high level, but it's like a student who has only done the simple example project.

I'm of the opinion that we're at a good moment to redo the things DNS does with better separation of concerns by going towards "put those records on a blockchain, streamline it for known applications, reframe the hard problem around bootstrapping access to on-chain data". It's already been explored in varying degrees(e.g. Ethereum Name Service, Symbol namespaces) but it's not really something that has to be the monopoly of any specific chain.

Re:Why is DNS still hard to learn? by zx8080 on Saturday July 29, 2023 @12:07AM (#36916796)
> Git is analogous - most uses of Git are formulaic, and the underlying concepts are simple enough - but actually accessing the right lever to pull when disaster strikes is unclear and hard to experiment with.

Would you mind sharing some examples of hard-to-recover git related disaster? I ask because I previously worked with applying hundreds of patches on top of chromium (yes, Opera). This resulted in __multiple__ merge‐conflicts. However not anything close to what I would call a git related disaster. Anything could be undone nicely.

What is important is that git is very verbose by default. It guides through not only a repo current state but also options user has.

I've met many developers not caring to read any of a git output and then claiming git is too complex and git broke their repo and it's "too complex to use". I'm sure it's not the case for you though.

So I'm just curious what kind of disaster was mentioned above.

Re:Why is DNS still hard to learn? by unmole on Saturday July 29, 2023 @01:04AM (#36917124)
> I've met many developers not caring to read any of a git output and then claiming git is too complex and git broke their repo and it's "too complex to use".

This a hundred times over.

Re:Why is DNS still hard to learn? by AlotOfReading on Saturday July 29, 2023 @01:42AM (#36917288)
Not OP, but I've encountered a few situations where the solution was modifying .git/ manually. The one that comes to mind was having two branches with names separated only by case on a case sensitive system, and then checking out both on a case insensitive system.
Re:Why is DNS still hard to learn? by pmontra on Saturday July 29, 2023 @09:54AM (#36920352)
Wouldn't be easier to rename the branches on the case sensitive system (a throw away Linux VM would do), push, pull?

Of course if the solution is editing .git/config, that's even easier, but it probably takes more than that.

Re:Why is DNS still hard to learn? by AlotOfReading on Saturday July 29, 2023 @12:00PM (#36921515)
It's been awhile so my memory is fuzzy, but this was at a windows-only shop back before WSL was a thing and getting a VM involved an annoying months-long requisition process. I think the repo state was actually corrupted too, so pull may not have been working.
Re:Why is DNS still hard to learn? by zx8080 on Sunday July 30, 2023 @01:04AM (#36927996)
> I've encountered a few situations where the solution was modifying .git/ manually

Would be very interesting to know the purpose of modifying .git/ manually.

Re:Why is DNS still hard to learn? by cyberax on Saturday July 29, 2023 @12:15AM (#36916842)
ANYTHING that has the word "blockchain" is automatically disqualified from pretty much any real use.

In particular, pretty much nobody wants to trust DNS names that can cost hundreds of millions to blockchain. Because if you lose (or compromise) your private key, then that's it. The domain is gone.

With regular DNS this would be solved by a couple of irate phone calls to registrars. At worst, via a court case.

Re:Why is DNS still hard to learn? by da39a3ee on Saturday July 29, 2023 @08:46AM (#36919755)
> and hard to experiment with.

Just on the topic of git: git makes it extremely easy to experiment! But far too many people, including those writing tutorials and blog posts, don't understand this. Whenever you're in doubt, just commit your work and make a temporary branch and switch to it. Then you can mess about with merging and rebasing and dealing with the conflicts to your heart's content.

This should be among the very first things we teach to new git users.

Re:Why is DNS still hard to learn? by redog on Friday July 28, 2023 @11:34PM (#36916602)
I get it. Your take resonates with me. Playing piano is easy too right? Right after you can do it. Until then it's mystically hard.

It just takes practice. Training helps but nothing can replace practice.

We can't jus b gud

Re:Why is DNS still hard to learn? by parentheses on Friday July 28, 2023 @11:46PM (#36916664)
jvns, your articles and conversational writing style are great. I hear you saying "'X is hard' is a way to not lose a reader by insulting their intelligence". My immediate reaction is "'X is easy' is a reminder that things that look hard upon first examination can be quite easy".

I think in general this level of "kid-gloves" is overall unhealthy for society. It encourages mental weakness.

At the same time, I understand that your aim is to reach as large an audience as possible so your educational material can have max impact. For this reason, I can justify you having this stance. That said, I don't think it applies globally.

Re:Why is DNS still hard to learn? by emmelaich on Friday July 28, 2023 @11:56PM (#36916732)
Perfect response!

My own response to "X is actually hard to learn" is ... compared to what?

   1. compared to your first impressions?
   2. compared to general opinions that you're aware of?
   3. are you talking about general principles or deep down stuff?
   4. are you talking about the learning curve?  Is it irregular? Steep? Shallow?
"X is not hard to learn" is ultimately a pretty empty statement.
Re:Why is DNS still hard to learn? by emmelaich on Saturday July 29, 2023 @12:03AM (#36916767)
My own hassles with DNS, some of which are mentioned.

    1. windows and apache httpd and others cache things
       for a long time, seemingly forever.
    2. The 'A' record is used in case of missing MX records. Who knew that?
    3. (in the olden days) confusion with winbios and other naming schemes
    4. The defn of 'authoritative'
    5. the misleading semantics of 'domain' in resolv.conf
    6. (minor) the casual use of CNAME to mean alias, whereas it fact
       means the opposite and is used to refer to the record, not the name.
    7. That DNS can use tcp/53.  The number of misconfigured firewalls I've
       dealt with argh.
    8. Split vs forwarding DNS.  e.g. impact on the .dev
       domain.
    9. The urge of some to put underscores in their names.
       I believe that some (early?) implementations allowed
       them.
    10. Someone putting in a lower 'serial' in named.conf and
        the struggle to restore sanity.
Re:Why is DNS still hard to learn? by maccard on Saturday July 29, 2023 @07:47AM (#36919276)
DNS's caching behaviour in the wild is incredibly infuriating. We have one team member at my company who is stuck with a stale DNS record for one of our internal services in our application, but their browser works just fine. I've absolutely no idea how to actually fix it, so for that one persons benefit we bought a whole new domain and ported everything to that.

Split DNS has let us do some cool things, and simultaneously caused no end of headaches. See above for the sorts of headaches.

Re:Why is DNS still hard to learn? by sitzkrieg on Saturday July 29, 2023 @12:05AM (#36916788)
i thought to post about how i thought "dns looks fairly straightforward" (which i guess it is on paper) then learned all the nuances over the years of maintaining a few services across a few domains and debugging network issues as a networking fw dev. i paused and the difference is perfectly between the the parent and grandparent post really.

some things seem deceptively easy and you can get by for years on basic features. then it happens, you try something new you learned you can do with $THING , add to it and things start to break and you dig in and realize you never fundamentally understood how the basic features that got you here worked. and thats ok

Re:Why is DNS still hard to learn? by codeisawesome on Saturday July 29, 2023 @02:50AM (#36917600)
Julia, I agree with your take here, thank you for bringing this thought process into the mainstream. There are many other concepts this happens with and in other ways: people sing praises of the pedagogic excellence in Skiena’s & Sedgewick’s algorithm textbooks (and the awful EPI book by Aziz et al) but I hate reading them, they’re actually written horribly to explain things, IMO. I think this form of difficult writing on top of already difficult concepts is a weird type of gate keeping (perhaps sometimes unintentional?) and it should be tackled all over Computer Science by better writers who have an explanation style like yours.
Re:Why is DNS still hard to learn? by einichi on Saturday July 29, 2023 @03:01AM (#36917654)
Simple is not always easy. Too simple can be difficult to grasp and sometimes adding a little complexity can actually make something more intuitive and easier.

DNS is simple, but it is not necessarily easy to understand.

Re:Why is DNS still hard to learn? by txutxu on Saturday July 29, 2023 @07:22AM (#36919110)
As always, thanks for the article (and the debate).

DNS itself, as an internet protocol, is "easy" in principle.

I did implement and maintain DNS services at the beginning of my career, for more than 200 customers, without any title and without help, except "the internet".

Everybody understands "you ask for a name, you get an address to connect as response", or "you can have more than one MX entry and play with the weight".

But as every internet protocol... as soon as you add to the recipe: historical changes and more than one RFC, upgrades to the protocol, cryptography, different client and server implementations, vendors, operative systems and libraries (and versions), levels of compliance, software applications, misconfiguration, bugs, layers (client side issues, intermediate server(s) issues, final server issues), cache!, enterprise interests (from client to server side) and wild global (or local) enterprise positioning, government and agencies interests, ageing, all issues related to the main long running opensource projects related to the protocol, all issues related to the "new is better" opensource projects (client and server) related to the protocol, user/developers/customers/managers asking (or assuming) impossible things or that there are no limitations, a long history (and a future one) of known attacks and known defenses or mitigations, clients that implement from the last century /etc/hosts to mdns and avahi, clients that act as servers (developed by enterprise bug creators)... you know... not easy anymore... things gonna be wild.

If there are complementary protocols, let's multiply the complexity: for DNS issues, there is also domain registration issues, whois, DHCP, VPNs, intermediate firewalls, rate limits, anycast, replication, IP, ARP...

With any internet protocol, or anything related to computers:

1) While it works, it's fine (and everybody is happy)

2) While we get an issue previously seen, understood and fixed, it's still calm

3) While we get an issue that we can quickly search by symptoms and fix, maybe ok

The "not easy" comes after that.

When we get a new and unknown problem, a weird issue, unexpected things, and there are 20 or 30 possibly failing actors around the protocol, or XX involved parts.

We could say exactly the same against any issue related to any internet protocol:

HTTP? it's easy or hard

Depends. It's easy to explain in a sentence what it does.

But you don't want to be the guy fixing issues against a float of load balancers used by all the customers, with a legacy (non compliant) device from a high priority customer at 4 A.M. oncall.

Re:Why is DNS still hard to learn? by tristor on Saturday July 29, 2023 @10:57AM (#36920907)
Howdy Julia,

I debated whether I should respond to you at all, however I feel that I must. You and I don't know each other, and based on the last sentence of your reply I suspect we agree with one another more than we disagree. Nonetheless, your reply seems to imply that my comment and my earlier disagreement were done out of malice or arrogance. A different commenter used the term "gatekeeping".

Fundamentally most of the building blocks of the Internet that people interact with regularly, including DNS, are well-defined and relatively easy to understand /relative to other technical things/. Protocols like DNS are effectively shoving text into packet. All of the hard stuff isn't in the bare protocol, it's in understanding the complete stack of abstractions the protocol relies on, the abstractions that allow the protocol to be simple but can sometimes not work in unexpected ways. If there is anything I've learned in my life, it's that integrations and scaling are what make technical things hard, the basic protocols are generally very simple and they are robust primarily because they are simple. They are simple primarily because they get to rely on all the underlying abstractions to be there. Technology now exists in a world of abstractions on top of abstractions, and understanding the basic building blocks is now rare since many technologists focus on mastering a particular layer of abstraction, yet if you understand the basic building blocks, even in an incomplete sense, it can greatly empower you to be more capable and comfortable with the abstractions.

"Hard" and "Easy" are relative terms, and I do believe that saying things are hard can lead people to avoid them altogether. I have spent a considerable portion of my life working diligently to mentor people in their technical careers, foster technical understanding, and bring people along with me on knowledge journeys. I have done this through extensive written documentation (internal to companies), teaching classes (internal to companies), public conference talks, guest lecturing at universities, and mentorship of people who are interested in learning technology but come from non-traditional backgrounds. I myself come from a non-traditional background. I've also worked hard to improve the UX and accessibility of every piece of software I touch, because I think that technology as a tool and the information about how it works should be accessible.

I really appreciated your article and I think you have a great writing style to explain things in an understandable way. Your Implement DNS project is really great, and I will be linking it to others in the future as they go through the process of learning DNS. In no way was my disagreement before or this reply meant to throw shade on you, your article, or otherwise. It's because I believe saying things are hard actually discourages people from learning them, leads to avoidance, and in particular I believe DNS is one of the more simple of the many possible things someone can learn about how the Internet works. I am /very much/ not trying to in any way disparage the intelligence of anyone who is struggling with learning any technology. I believe that learning technology is much like learning anything else, it requires interest and time. Saying that some of the simpler things are hard can discourage people from having the interest, and if people do not have the interest they will not invest the time.

Very specifically, I think for the audience here on HN, they've had to learn and use technologies that are far more difficult than DNS in their lives and careers with an almost certainty. In a relative sense, I do not believe DNS is difficult to learn. DNS has a /lot/ of edge cases though, which can be hard to troubleshoot, understand, and resolve, so from this perspective it is hard to master and I wouldn't claim to have fully mastered it myself. As an example of what I mean, another commenter mentioned Git. I have a pretty deep understanding of Git as well, yet I consider it significantly more difficult to learn and understand than DNS, largely because DNS is better documented, easier to inspect, and doesn't require the technologist to understand complex algorithms like merkle trees. Yet almost every tech worker in the world uses Git every day, often with many frustrations and weird edge cases, as in regular usage it fails far more often than simpler technologies like DNS. The entire strength of DNS from a robustness, adoption, and resilience perspective is largely its simplicity, which is why I think relative to the many other things that exist that it's not hard to learn.

Our opinions are always colored by our experiences, as is mine, which I stand by. One of those experiences I'll recount here, which is that I have known a woman for a little over 6 years now who is currently working in IT and finishing a bachelor's in IT through WGU. She's one of the top performer's on her team and has a gift with understanding and explaining abstract concepts to users, which has made her well-liked by all at her company. Not long after I met her she shared with me that she'd always wanted to go into IT, but felt like she couldn't do it because everyone she'd met along the way had told her it was too hard for her because she suffers from a learning disorder called dyscalculia which interferes in her ability to do math. For reasons I don't fully understand, math ability is used by many technical people as a determinant of your ability to learn and work with technology. I was one of the first people she'd met in her life that encouraged her to pursue her interest in technology and told her she could do it. I did so by pointing out that many of the things people were saying were hard were concepts she already understood in the abstract and offering to go on the journey with her. She had been so dejected by others telling her things were too hard for her she never pursued a college education. I invested significantly in learning with her and 3 years ago she finished an associates and multiple certifications and started her first IT job, and she's been excelling in it the entire way.

I've continued to mentor her, along with many others, because I legitimately do believe that much of the technology around us is much easier to learn and understand than people commonly believe, and that understanding how it works is a key to understanding how our world works now and is incredibly empowering even for people who don't work with technology every day. I am adamantly opposed to any sort of gatekeeping of technology knowledge, and in no way am advocating that gatekeeping or trying to disparage those who struggle to learn. If anything, one of my existential fears is that as a society we fall into a situation where so few people understand the technology we rely on every day that it creates a new and more dire social gap beyond the wealth gap, a knowledge gap that fundamentally separates those who can effectively participate in the levers of power (including democratically) from those who cannot. I am heavily invested in ensuring that knowledge is free, accessible, and that there is an open pathway for people to learn and it's one of my core optimisms about the Internet.

Re:Why is DNS still hard to learn? by AB1908 on Monday July 31, 2023 @12:39AM (#36938871)
This is one of the kindest comments I've read on any social media site. Thanks for taking the time.
Re:Why is DNS still hard to learn? by nvahalik on Saturday July 29, 2023 @03:54PM (#36923911)
Seems like maybe you are both saying: DNS the protocol is easy to understand well. DNS in he wild is much harder to understand well.
Re:Why is DNS still hard to learn? by yencabulator on Saturday July 29, 2023 @04:43PM (#36924353)
Actually, DNS the protocol is a horribly complex beast with various compression mechanism, tricky encoding rules, workarounds for MTU limits, etc. Most people "learning DNS" never even attempt to learn the protocol.

What is reasonably easy is a high-level understanding of e.g. "given this question, this is what one expects an authoritative DNS server to respond" in the human-friendly form, covering the basic kinds of questions (A/AAAA/MX/TXT/CNAME).

Re:Why is DNS still hard to learn? by acheron on Friday July 28, 2023 @07:02PM (#36914548)
I wish I had jobs where people cared that I knew DNS.
Re:Why is DNS still hard to learn? by Aeolun on Friday July 28, 2023 @08:18PM (#36915254)
DNS itself is easy to learn. Trying to figure out why domain x doesn’t resolve to ip y is a hard problem.

Like the article points out, there’s so many layers of potential caches in between you starting a lookup and that lookup being resolved.

Re:Why is DNS still hard to learn? by temporallobe on Friday July 28, 2023 @10:19PM (#36916154)
Likewise, a lot of people know (and use) me for my supposedly deep knowledge of Git, even though it took me years to fully understand and feel comfortable enough with it so that I’m no longer terrified when using the CLI — I can cherry-pick and rebase with the best of them. YET, I still feel it’s a bit intimidating and that there’s some mysteries behind the internals I don’t fully grasp. I suppose like DNS, it does take time and effort to learn, and when I really think about it, it’s actually not that hard, but for some reason, so many devs struggle with it, mostly (front what I’ve observed) because it’s intimidating due to o it’s somewhat odd terminology and unintuitive workflow, but also because there are so many GUI/IDE tools that hide a lot of the complexity, which simultaneously good and bad.
Re:Why is DNS still hard to learn? by mekoka on Saturday July 29, 2023 @12:03AM (#36916773)
> I don't agree with this article.

But you address none of the article's points. You're basically disagreeing with the title. And I'd say that your answer seems to conflate DNS is hard and DNS is hard to learn.

> It just takes some effort and time to learn.

How much effort, how much time? Many people in these threads say that they learned by implementing a server. Some mention that it only took them some months to grasp, but then just echo in unison that "once you understand it, it's actually pretty easy". So can we agree that for something as ubiquitous and conceptually simple, it's actually hard to learn?

Re:Why is DNS still hard to learn? by kmoser on Saturday July 29, 2023 @01:32AM (#36917247)
> I think DNS is something few people take the time to learn, but it's not actually hard to learn.

Hard disagree. For me, DNS is like doing taxes: I touch it once a year or so, find it Byzantine, know enough to be dangerous, but am always frustrated that I don't use it often enough to remember exactly how to configure things without having to consult poorly written and/or overly technical tutorials.

I'd like to see a better version of web-based tools like mxtoolbox.com that will analyze DNS records, let you know what's wrong, and give you actual examples of what settings you need for things like DMARC/DKIM/SPF records. In my experience, online tutorials for setting them up come tantalizingly close to giving me what I need, but I often end up getting stuck with the last few details (usually the weird punctuation required) because, again, I touch this stuff so infrequently I just don't remember from one time to the next. Ideally I'd want a form-based tool that gives you drop-downs to select from and, when submitted, just gives you the actual record you need.

Re:Why is DNS still hard to learn? by denton-scratch on Saturday July 29, 2023 @05:51AM (#36918565)
I also don't agree with the article. Many aspects of sysadmin are far more difficult than DNS.

> the most common server and client implementations rigorously follow the standard

Not servers! in particular, many servers mess with the TTL (as author notes). It's not that these servers are defective; it's that the hostmaster has interfered with the configuration, presumably to reduce the load.

Re:Why is DNS still hard to learn? by lazyant on Saturday July 29, 2023 @01:28PM (#36922484)
DNS _protocol_ and _servers_ are conceptually easy. In practice, the implementations and what actually happens is not. When you type google.com in your browser, do you know exactly the workflow in your computer and the different caches it uses (browser, OS etc) and how they work?

Do you know which Linux tools use gethostbyname vs getaddrinfo and why they could give different results?