Wulo Awọn apeere Aṣẹ ti o wulo fun wiwa Awọn Lookups DNS
Aṣẹ gbalejo jẹ iwulo CLI ti o rọrun ati irọrun lati lo fun ṣiṣe awọn iṣawari DNS eyiti o tumọ awọn orukọ ìkápá si awọn adirẹsi IP ati ni idakeji. O tun le ṣee lo lati ṣe atokọ ati ṣayẹwo ọpọlọpọ awọn oriṣi awọn igbasilẹ DNS gẹgẹbi NS ati MX, ṣe idanwo ati jẹrisi olupin ISP DNS ati sisopọ Ayelujara, àwúrúju ati awọn igbasilẹ atokọ dudu, wiwa ati laasigbotitusita awọn ọran olupin DNS laarin awọn miiran.
Ninu nkan yii, a yoo kọ bi a ṣe le lo aṣẹ alejo pẹlu awọn apẹẹrẹ diẹ ti o wulo ni Lainos lati ṣe awọn iṣawari DNS. Ninu awọn nkan ti tẹlẹ, a fihan awọn ofin 8 Nslookup ti a lo julọ fun idanwo ati laasigbotitusita awọn olupin DNS ati lati beere awọn igbasilẹ orisun DNS kan pato (RR) bakanna.
A tun ṣalaye awọn aṣẹ 10 Linux Dig (Groper Information Information) lati beere alaye DNS, o ṣiṣẹ diẹ sii bi ọpa Nslookup. IwUlO ogun tun ṣiṣẹ ni ọna kanna ati pe o wa ni fifi sori ẹrọ lori pupọ ti kii ba ṣe gbogbo Linux distros akọkọ.
Pẹlu eyi ti o sọ, jẹ ki a wo awọn aṣẹ ogun 14 wọnyi ni isalẹ.
Wa Adirẹsi IP Agbegbe
Eyi ni aṣẹ ogun ti o rọrun julọ ti o le ṣiṣẹ, o kan pese orukọ ìkápá kan bii google.com
lati gba awọn adirẹsi IP ti o ni nkan.
$ host google.com google.com has address 216.58.201.46 google.com has address 216.58.201.46 google.com has address 216.58.201.46 google.com has IPv6 address 2a00:1450:4009:80b::200e google.com mail is handled by 20 alt1.aspmx.l.google.com. google.com mail is handled by 30 alt2.aspmx.l.google.com. google.com mail is handled by 10 aspmx.l.google.com. google.com mail is handled by 40 alt3.aspmx.l.google.com. google.com mail is handled by 50 alt4.aspmx.l.google.com.
Wa Awọn olupin Orukọ Agbegbe
Lati wa awọn olupin orukọ orukọ ašẹ lo aṣayan -t.
$ host -t ns google.com google.com name server ns1.google.com. google.com name server ns2.google.com. google.com name server ns3.google.com. google.com name server ns4.google.com.
Wa Igbasilẹ CNAME ase
Lati wa ibugbe CNAME, ṣiṣe.
$ host -t cname mail.google.com mail.google.com is an alias for googlemail.l.google.com.
Wa Agbegbe MX Igbasilẹ
Lati wa awọn igbasilẹ MX fun agbegbe kan.
$ host -n -t mx google.com ogle.com mail is handled by 50 alt4.aspmx.l.google.com. google.com mail is handled by 10 aspmx.l.google.com. google.com mail is handled by 40 alt3.aspmx.l.google.com. google.com mail is handled by 30 alt2.aspmx.l.google.com. google.com mail is handled by 20 alt1.aspmx.l.google.com.
Wa ase TXT Igbasilẹ
Lati wa awọn igbasilẹ TXT fun ibugbe kan.
$ host -t txt google.com google.com descriptive text "v=spf1 include:_spf.google.com ~all"
Wa Agbegbe SOA Igbasilẹ
O le ṣe igbidanwo agbalejo lati ṣafihan awọn igbasilẹ SOA fun agbegbe ti a ṣalaye, lati gbogbo awọn olupin orukọ aṣẹ aṣẹ ti a ṣe akojọ fun agbegbe naa pẹlu asia -C
.
$ host -C google.com Nameserver 216.239.38.10: google.com has SOA record ns1.google.com. dns-admin.google.com. 156142728 900 900 1800 60 Nameserver 216.239.32.10: google.com has SOA record ns3.google.com. dns-admin.google.com. 156142728 900 900 1800 60 Nameserver 216.239.34.10: google.com has SOA record ns4.google.com. dns-admin.google.com. 156142728 900 900 1800 60 Nameserver 216.239.36.10: google.com has SOA record ns2.google.com. dns-admin.google.com. 156142728 900 900 1800 60
Ibeere Olupin Orukọ Kan pato
Lati beere olupin olupin orukọ pataki.
$ host google.com ns4.google.com Using domain server: Name: ns4.google.com Address: 216.239.38.10#53 Aliases: google.com has address 172.217.19.46 google.com has address 172.217.19.46 google.com has address 172.217.19.46 google.com has IPv6 address 2a00:1450:4005:808::200e google.com mail is handled by 30 alt2.aspmx.l.google.com. google.com mail is handled by 20 alt1.aspmx.l.google.com. google.com mail is handled by 50 alt4.aspmx.l.google.com. google.com mail is handled by 10 aspmx.l.google.com. google.com mail is handled by 40 alt3.aspmx.l.google.com.
Wa Gbogbo Alaye ti Awọn Igbasilẹ Agbegbe ati Awọn agbegbe
Lati ṣe ibeere ti eyikeyi NKAN, lo aṣayan -a
(gbogbo) eyiti o jẹ deede si eto aṣayan -v
.
$ host -a google.com Trying "google.com" ;; ->>HEADER<
Gba Alaye TTL Alaye
Lati wa alaye agbegbe TTL.
$ host -v -t a google.com Trying "google.com" ;; ->>HEADER<
Lo Boya IPv4 tabi IPv6
Aṣayan -4
tabi -6
aṣayan ipa ogun lati lo IPv4 nikan tabi ọkọ irin-ajo IPV6 nikan lẹsẹsẹ.
$ host -4 google.com OR $ host -6 google.com
Ṣe Awọn ibeere ti kii ṣe atunṣe
Aṣayan -r
ṣe awọn ibeere ti kii ṣe atunkọ, ṣe akiyesi pe siseto aṣayan yii n mu RD kuro (atunṣe ti o fẹ), diẹ ninu ibeere ti alejo gba.
$ host -rR 5 google.com google.com has address 216.58.201.46 google.com has address 216.58.201.46 google.com has address 216.58.201.46 google.com has IPv6 address 2a00:1450:4009:80b::200e google.com mail is handled by 30 alt2.aspmx.l.google.com. google.com mail is handled by 40 alt3.aspmx.l.google.com. google.com mail is handled by 50 alt4.aspmx.l.google.com. google.com mail is handled by 20 alt1.aspmx.l.google.com. google.com mail is handled by 10 aspmx.l.google.com.
Ṣeto Awọn igbidanwo UDP fun Iwadii kan
Nipa aiyipada nọmba UDP gbidanwo jẹ 1, lati yi pada, lo asia -R
.
$ host -R 5 google.com google.com has address 216.58.201.46 google.com has address 216.58.201.46 google.com has address 216.58.201.46 google.com has IPv6 address 2a00:1450:4009:80b::200e google.com mail is handled by 30 alt2.aspmx.l.google.com. google.com mail is handled by 40 alt3.aspmx.l.google.com. google.com mail is handled by 50 alt4.aspmx.l.google.com. google.com mail is handled by 20 alt1.aspmx.l.google.com. google.com mail is handled by 10 aspmx.l.google.com.
Ṣeto Akoko Ibeere Duro fun Idahun
Lilo iyipada -W
, o le kọ olugbalejo lati duro fun esi fun akoko kan ni iṣẹju-aaya ati ti o ba ti lo asia -w
, o jẹ ki alejolejo duro de lailai fun esi:
$ host -T -W 10 google.com google.com has address 216.58.201.46 google.com has address 216.58.201.46 google.com has address 216.58.201.46 google.com has IPv6 address 2a00:1450:4009:80b::200e google.com mail is handled by 10 aspmx.l.google.com. google.com mail is handled by 40 alt3.aspmx.l.google.com. google.com mail is handled by 30 alt2.aspmx.l.google.com. google.com mail is handled by 20 alt1.aspmx.l.google.com. google.com mail is handled by 50 alt4.aspmx.l.google.com.
O n niyen! Ninu nkan yii, a kọ bi a ṣe le lo pipaṣẹ ogun pẹlu awọn apẹẹrẹ diẹ ti o wulo ni Lainos. Lo fọọmu esi ni isalẹ lati pin eyikeyi awọn ero pẹlu wa nipa itọsọna yii.