Get the App
SLTechnology News&Howtos  ›  Development  › 

How to use the dig command in Linux

Shulou Source: shulou.com Published: 2022-06-02 00:27:39 10月03日 Update

This article "how to use dig command in Linux" Most people don't understand it except for program members. In order to make everyone understand "how to use dig command in Linux" better, Xiaobian summarizes the following contents for everyone, which has certain reference value. The detailed steps are clear and the details are properly handled. I hope everyone will gain something through this article. Let's take a look at the specific contents together.

Linux common command dig is a commonly used domain name query tool, which can be used to test whether the domain name system works properly.

dig Domain Name Query Tool

Syntax dig(option)(parameter) option @: Specify the domain name server for domain name resolution; -b: When the host has multiple IP addresses, specify which IP address of the host is used to send domain name query requests to the domain name server; -f: Specify dig to run in batch mode, and the specified file stores DNS task information that needs batch query; -P: Specify the port number used by the domain name server; -t: Specify the DNS data type to be queried; -x: Perform reverse domain name queries;-4: Use IPv4;-6: Use IPv6;-h: Display command help information. Parameter Host: Specify the host to query domain name;

Query Type: Specifies the type of DNS query;

Query class: Specify the class of DNS query;

Query Options: Specify query options.

Example [root@localhost ~]# dig www.jsdig.com; > DiG 9.3.6-P1-RedHat-9.3.6-20.P1.el5_8.1 > www.jsdig.com;; global options: printcmd ;; Got answer: ;;->HEADERLinux What versions of Linux are: Deepin, UbuntuKylin, Manjaro, LinuxMint, Ubuntu, etc. Deepin is one of the best Linux distributions in China; Ubuntu Kylin is a derivative distribution based on Ubuntu;Manjaro is a Linux distribution based on Arch;LinuxMint's default Cinnamon desktop is similar to Windows XP and easy to use;Ubuntu is a Linux operating system based on desktop applications.

Thank you for reading, I hope you have a certain understanding of the key issue of "how to use dig command in Linux", the specific use situation also needs to be used by you to understand, try it quickly, if you want to read more articles related to knowledge points, welcome to pay attention to the industry information channel!

Tags: Query domain name command host content server version type release service information parameter address tool common desktop system proper operating system value Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno vpn Shulou Technology OPPO Reno Microsoft Apple