If you are gathering Domain Name System(DNS) information, chances are you use dig, kdig, drill, nslookup or something else. But there is a new kid in the block, dnsi and it is promising. Built by NLnet Labs, the team behind NSD, Unbound and other open source tools.
The tool is part of their domain project and is in its early stage. At the moment, dnsi supports only three commands; dnsi query, dnsi lookup and dnsi help.
First install it. There are binary packages for Debian and Ubuntu Red Hat Enterprise Linux (RHEL) or compatible distros such as AlmaLinux and Rocky Linux.
The Debian versions supports amd64 and x86_64 on both Debian Bullseye 11 and Bookworm 12. There is an armhf version for Debian/Raspbian(Raspberry Pi OS) Bullseye and an arm64 support for Debian Buster.
I am testing on a Raspberry Pi, with Bookworm 12, so I have to build it from the source code. I used Cargo, the build system and package manager for Rust. NLnetLabs domain project is written in Rust.
Installing Rust
You machine may have Rust as a system package but dnsi needs to have Rust verion 1.78 and above. Let use the cacninical Rust installer, rustup and you can install it by:
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
Once your installation is finish, you can install dnsi.
cargo install --locked dnsi
You can update your dnsi installation with rustup update and you can use the --force option to overwrite an existing version with the latest one:
cargo install --locked --force dnsi.
To query a domain, run dnsi query example.org and you may specify the resource record you want results for; dnsi query example.org ns.
If you are familiar with dig, you will notice that the dnsi query outputs are just like dig’s.
If you are a nslookup fan, dnsi lookup is all you need; dnsi lookup example.org.