Get the App
SLTechnology News&Howtos  ›  Servers  › 

Linux basic command-host domain name query tool

Shulou Source: shulou.com Published: 2022-06-02 06:38:39 11月01日 Update

Host

Host is a commonly used DNS query tool, which is often used to query domain names and check whether domain name resolution is correct.

The scope of application of this command: RedHat, RHEL, Ubuntu, CentOS, Fedora.

1. Grammar

Host [options] name [server]

2. List of options

Option

Description

-a

Query all the information

-c

Set query type

-C

Query the complete SOA record

-d |-v

Show detailed procedures

-l

List mode

-t

Select query type: CNAME NS SOA SIG KEY AXFR

-w

Wait forever

-W

Set wait timeout

3. Examples

1) query domain name

[root@localhost ~] # host www.baidu.com / / query domain name information, display aliases and ip

Www.baidu.com is an alias for www.a.shifen.com.

Www.a.shifen.com has address 111.13.100.91

Www.a.shifen.com has address 111.13.100.92

2) query all information

[root@localhost ~] # host-a www.baidu.com / / query all the information of the domain name

Trying "www.baidu.com"

;;-> > HEADER

Tags: Query domain name information type command tool alias instance password commonly used platform pattern scope syntax procedure scope link prototype permanent reference Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno OPPO Reno Linux vpn Shulou Technology Apple