آپاچیابونتوانجین ایکسسورس کدسیستم عامللینوکسوب سرور

جدول دسورات خط فرمان DNS Server و تشریح عملکرد آنها

dns server commands

جدول دسورات خط فرمان DNS Server و تشریح عملکرد آنها

جدول دستورات Command Line مربوط به سرور DN
S

فانکشن DNSCMD option نمونه توضیحات
Do any dnscmd command on a remote system dnscmd [i]servername[/i] [i]command[/i] dnscmd main.barnamenevis.host /zoneprint barnamenevis.host
Create a primary zone dnscmd /zoneadd [i]zonename[/i] /primary dnscmd /zoneadd barnamenevis.host /primary
Create a secondary zone dnscmd /zoneadd [i]zonename[/i] /secondary [i]master IP address[/i] dnscmd /zoneadd barnamenevis.host /secondary 192.168.1.1
Host a zone on a server based on an existing (perhaps restored) zone file dnscmd /zoneadd [i]zonename[/i] /primary /file [i]filename[/i] /load dnscmd /zoneadd barnamenevis.host /primary /file barnamenevis.host.dns /load
Delete a zone from a server dnscmd /zonedelete [i]zonename[/i] [/f] dnscmd /zonedelete barnamenevis.host /f (without the /f, dnscmd asks you if you really want to delete the zone)
Show all of the zones on a DNS server dnscmd /enumzones dnscmd /enumzones
Dump (almost) all of the records in a zone dnscmd /zoneprint [i]zonename[/i] dnscmd /zoneprint barnamenevis.host Doesn”t show glue records.
Add an A record to a zone dnscmd /recordadd [i]zonename[/i] [i]hostname[/i] A [i]ipaddress[/i] dnscmd /recordadd barnamenevis.host mypc A 192.168.1.33
Add an NS record to a zone dnscmd /recordadd [i]zonename[/i] @ NS [i]servername[/i] dnscmd /recordadd barnamenevis.host @ dns3.barnamenevis.host
Delegate a new child domain, naming its first DNS server dnscmd /recordadd [i]zonename[/i] [i]childname[/i] NS [i]dnsservername[/i] dnscmd /recordadd barnamenevis.host test NS main.barnamenevis.host This would create the “test.barnamenevis.host” DNS child domain unter the barnamenevis.host DNS domain
Add an MX record to a zone dnscmd /recordadd [i]zonename @[/i] MX [i]priority servername[/i] dnscmd /recordadd barnamenevis.host @ MX 10 mail.barnamenevis.host
Add a PTR record to a reverse lookup zone dnscmd /recordadd [i]zonename[/i] [i]lowIP [/i]PTR [i]FQDN[/i] dnscmd /recordadd 1.168.192.in-addr.arpa 3 PTR pc1.barnamenevis.host This is the PTR record for a system with IP address 192.168.1.3
Modify a zone”s SOA record dnscmd /recordadd [i]zonename[/i] @ SOA [i]primaryDNSservername responsibleemailipaddress serialnumber refreshinterval retryinterval expireinterval defaultTTL[/i] dnscmd /recordadd barnamenevis.host @ SOA winserver.barnamenevis.host mark.barnamenevis.host 41 1800 60 2592000 7200 Ignores the serial number if it”s not greater than the current serial number
Delete a resource record dnscmd /recorddelete [i]zonename[/i] [i]recordinfo[/i] [/f] dnscmd /recorddelete barnamenevis.host @ NS main.barnamenevis.host /f Again, “/f” means “don”t annoy me with a confirmation request, just do it.”
Create a resource record and incorporate a nonstandard TTL dnscmd /recordadd [i]zonename[/i] [i]leftmostpartofrecord[/i] [i]TTL[/i] [i]restofrecord[/i] dnscmd /recordadd barnamenevis.host pc34 3200 A 192.168.1.4
Reload a zone from its zone file in windowssystem32dns dnscmd /zonereload [i]zonename[/i] dnscmd /zonereload barnamenevis.host Really only useful on primary DNS servers
Force DNS server to flush DNS data to zone file dnscmd /zonewriteback [i]zonename[/i] dnscmd /zonewriteback barnamenevis.host
Tell a primary whom to allow zone transfers to dnscmd /zoneresetsecondaries [i]zonename[/i] /nonsecure|securens dnscmd /zoneresetsecondaries barnamenevis.host /nonsecure That example says to allow anyone who asks to get a zone transfer
Enable/disable DNS NOTIFY dnscmd /zoneresetsecondaries [i]zonename[/i] /notify|/nonotify dnscmd /zoneresetsecondaries barnamenevis.host /nonotify Example disables DNS notification, which is contrary to the default settings.
Tell a secondary DNS server to request any updates from the primary dnscmd /zonerefresh [i]zonename[/i] dnscmd /zonerefresh barnamenevis.host
Enable or disable dynamic DNS on a zone dnscmd /config [i]zonename[/i] /allowupdate 1|0 ۱ enables, 0 disables, 0 is default
Stop the DNS service Either net stop dns or sc stop dns (No dnscmd command for this)
Start the DNS service Either net start dns or sc start dns (No dnscmd command for this)
Install the DNS service on a 2008 full install system servermanagercmd -install dns
Install the DNS service on a 2008 Server Core system ocsetup DNS-Server-Core-Role Case matters — [b]ocsetup dns-server-core-role[/b] would fail
Uninstall the DNS service on a 2008 Server full install system servermanagercmd -remove dns
Uninstall the DNS service on a 2008 Server Core system ocsetup /uninstall DNS-Server-Core-Role

Comment here

*

code