DNS in ISP networks and why you should care

If you are not familiar with how DNS works, please go and read this article and watch the accompanying video.

In this article we will talk about the different types of DNS servers an ISP will encounter and the design considerations of implementing them into your network. Let’s jump into the three types.

Cache servers
local DNS (LDNS) servers
authoritative DNS (ADNS) servers, of which the Root and Top Level Domain (gTLD) servers are special cases

Let’s go into detail on what each of these is.  We will start at the top and work our way down.

Authoritative Name Servers

An authoritative name server, just like the name says, is the authority on the website or resource it is responsible for. Without authoritative name servers, the DNS hierarchy would not function. You would have no way of telling an incorrect answer from a real answer.

A special kind of authoritative name server is the root nameservers, which are responsible for the Top Level Domains (TLD).  These are better known as .com,.net,.org, and so on.

Local DNS resolvers
These are servers run by Internet Service Providers (ISPs) and other entities such as Google (8.8.8.8) and Cloudflare (1.1.1.1). These are machines running BIND, Tiny DNS, or other software.  It is best practice to not run your authoritative name server on the same instance as your resolver.

Local DNS resolvers sit on the ISPs Internet backbone on fast connections to the Internet.

Caching servers
Caching servers are more typical in a larger ISP network with large concentrations of customers n certain geographic areas. .  Since DNS is such an important function, ISPs want their clients to have the quickest access to DNS lookups possible. In larger networks, this means putting caching servers as close to customers as possible. DNS lookups do not take up much bandwidth, but a slow DNS lookup can affect the user experience. If you have ever entered an address or clicked a link and experienced a “Looking up xyz.com” message for more than a second or two you are experiencing a slow DNS.

So why is this important in an ISP network?
As mentioned above the quicker you can get DNS lookups done and over with the better user experience your customers will have. You do not want your clients waiting 3-4 seconds for each lookup.  While you might have the fastest Internet on the planet, your customers will always be waiting on these requests, which will cause them to think things are slow.  And technically they would be right.

To speed up a large ISP network you will need to design DNS resolvers/caches into your design.  These can be at major traffic points on your network, or at each POP location. Part of this depends on your IP design, while some of it depends on the overall design of your infrastructure.  As networks flatten out due to things like VPLS and EVPN the need for lots of resolvers in an ISP network fades away. A general rule of thumb is to deploy DNS resolvers at each customer gateway.  This can be the wireless tower they receive their signal from, the local DSLAM, or a fiber node at the edge of your network.  By deploying resolvers at the customer gateway you are giving them fast access to cached DNS lookups. This can also lead to more complex troubleshooting should a cache server fail

What do I mean by cached?
A DNS resolver has two major functions in life.  It takes a request for a website, in our case j2sw.com, to look up the appropriate IP address and returns that information to the client.  The whole www stuff is for us, dumb humans. DNS translates www.j2sw.com to 209.209.44.4. This is what the computer and routers understand.

Secondly, a DNS resolver caches previous lookups.  This can be configured for minutes, hours, or days.  This speeds up any subsequent lookups because the resolver can serve it up locally without having to go clear across the internet to look it up and wait for the return. Once it has done one lookup, it will cache that lookup for any client who requests it after.

So, how does an ISP implement all of these?

Many modern routers have the ability to cache lookups and act as a DNS resolver.  Mikrotik, Cisco, and others all have this ability.   Even a Raspberry PI has enough horsepower to be a DNS resolver.  These can be deployed at each POP site and customers can point to them as their primary DNS servers.  This means their routers or PCs will look to the closest DNS resolver first.  If the resolver has the answer in its cache, it will serve it up right away.  If not, the resolver can go on to the next step up.

The next step is local resolvers the ISP typically runs.  There are lots of arguments for why an ISP should run their own instead of pointing to Google (8.8.8.8) or someone else. We won’t go into these here.  Let’s just say it is beneficial for the ISP to run their own resolvers with root hints.

It’s all about the trickle-down or trickle-up effect. The Local resolvers cache what they can for their subset of customers.  These resolvers then look to the name server resolvers, which have larger caches, and those name server resolvers finally look up the information directly.

 

The arguments against 0.0.0.0/8

The arguments against using 0.0.0.0/0 have been pretty much quashed by the following:

Allow 0.0.0.0/8 as a valid address rangeThe longstanding prohibition against using 0.0.0.0/8 dates back to two issues with the early internet.

There was an interoperability problem with BSD 4.2 in 1984, fixed in BSD 4.3 in 1986. BSD 4.2 has long since been retired.

Secondly, addresses of the form 0.x.y.z were initially defined only as a source address in an ICMP datagram, indicating “node number x.y.z on this IPv4 network”, by nodes that know their address on their local network, but do not yet know their network prefix, in RFC0792 (page 19). This usage of 0.x.y.z was later repealed in RFC1122 (section 3.2.2.7), because the original ICMP-based mechanism for learning the network prefix was unworkable on many networks such as Ethernet (which have longer addresses that would not fit into the 24 “node number” bits). Modern networks use reverse ARP (RFC0903) or BOOTP (RFC0951) or DHCP (RFC2131) to find their full 32-bit address and CIDR netmask (and other parameters such as default gateways). 0.x.y.z has had 16,777,215 addresses in 0.0.0.0/8 space left unused and reserved for future use, since 1989.

This patch allows for these 16m new IPv4 addresses to appear within a box or on the wire. Layer 2 switches don’t care. 0.0.0.0/32 is still prohibited, of course.

Source: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=96125bf9985a&fbclid=IwAR2W03PZN8b7ZzAL1jsvxe0wuI9qOWKpeWdAnMMjvgLGE7x5f48RIaCtYUw

Musings of an ISP Engineer part 2

Part 1 can be viewed here

-Always check layer1 first. Your momma told you it’s the simplest things in life.  Most times it is that simple.

-After that check layer 2. If a backhaul or fiber link can’t push data due to no connectivity then the fanciest written config in the world won’t mean a thing.

-Use a password manager. 16 character passwords should be the norm with two-factor authentication to the password manager.

-Make a decision and act on it.  Too many times I see network by committee.  By the time it’s actually implemented the parameters have changed. Do the best you can, with the information you have, in the time you have.

-Have a second and third way into your network

yo dawg i heard you like redundancy so i put redundancy in your redundancy  so you can be redundant while you're redundant! - xzibit-yo-dawg | Meme  Generator

-Get used to reading release notes and scanning forums/mailing lists for bug reports

-Your network probably is not hacked

-Quit spending time trying to navigate your network on your phone’s small screen.  Break down and buy a tablet or break out your laptop. Your phone is for quick assessments using the data you are fed.  It’s too inefficient to make config changes.

32,619 Phone Frustration Stock Photos, Pictures & Royalty-Free Images -  iStock

-This Dilbert comic strip cracks my ass up

Dilbert had it right back in 1995 : r/linuxmasterrace

-Just emphasizing how it’s the simplest things at times

-It’s fine if you know how to program in binary but you don’t need to know the inner workings of hardware for 95% of the job. A racecar driver probably knows about engines but spends 99% of his or her time just driving the car.

-Get to know your sales reps for your hardware. They are the unsung heroes in this industry. a good salesperson picks up tidbits of knowledge and lets their customers know. Things like bad hardware runs, bugs other customers have come across, and the like.

A successful maintenance window is 75% labor and 25% documentation. An unsuccessful one is 75% labor and 25% rolling into backups.

-You only know what you know and that’s okay

-The big companies are just as clueless as you. Sometimes they are worse. They just have more people who know just enough to get by.

-There are work gadgets and fun gadgets. Keep the two separate.

Hilarious Comics With Unexpected Endings By “Wtframecomics” (47 Pics) –  Global Circulate

-That optic you should have replaced when you were cleaning the fiber cable will probably haunt you tomorrow.

Part 3? Maybe…..

Auto mapping your Cisco Network

This content is for Patreon subscribers of the j2 blog. Please consider becoming a Patreon subscriber for as little as $1 a month. This helps to provide higher quality content, more podcasts, and other goodies on this blog.
To view this content, you must be a member of Justin Wilson's Patreon
Already a qualifying Patreon member? Refresh to access this content.

Yet another case for IPv6 for service providers

So recently I have been posting about the Cambium Networks QOE box I have been testing. After having this run for about a week I figured I would share this tidbit about usage.

55.39% of my traffic is IPV6 traffic. Most of this would be streaming traffic to various folks like NetFlix and Amazon and gaming traffic. My household consists of three people. No kids.

Implement IPV6 now if you are a service provider and thank me later. https://blog.j2sw.com/networking/wisps-ipv6-is-the-answer-to-some-of-your-issues/

#packetsdownrange

Globe Ed Network Fundamentals

https://www.globed.net/courses/back-to-networking-basics

In this Networking Basics Workshop we will be learning the following:

REFERENCE MODELS
ETHERNET STANDARDS AND SPECS
TRANSMISSION METHODS
TOPOLOGIES
 NETWORKING DEVICES
IPV4 ADDRESSING
HEX CONVERSION
CISCO ROUTER AND SWITCH BASIC
CISCO ROUTER AND SWITCH CONFIGURATION
LAYER 2 SWITCHING  
LAYER 3 ROUTING
LAYER 3 ROUTING USING L3 SWITCHING

RECORDINGS OF THE WORKSHOP WILL BE SENT TO ALL THAT REGISTER – Even to those that could not attend