Cancelled

Create .BAT File that removes list or "A" records or "PTR" records for multiple DNS server

I need a PowerShell script created.. Fast!! I'm fixing an issue for a client right now and few things are broken until I remove these records. I have a list of 200 PTR entries.

NOTE: This should be a simple process for someone that has the skills and should not take much time.

REM ======== Batch File Beginning ===========

@echo on

set cachedentry=123.1.168.192.in-addr.arpa.

del [url removed, login to view]

for /f %%i in ([url removed, login to view]) do (dnscmd %%i /recorddelete /cache %cachedentry% PTR /f) >> [url removed, login to view]

REM ====== Batch File Ending ==============

I need this batch file modified to accept multiple records like "123.1.168.192.in-addr.arpa."

They will be many records but one per line. So for each record the way it is hard coded will only delete one record. Then there is the "[url removed, login to view]" that has 20 or so IP's for the DNS servers to delete the record from. So I need an input file called "[url removed, login to view]" that will contain multiple PTR records that will need to be delete from each of the 20 servers.

In the end I should have two input files. One for the DNS server IP's and another input file for the record to be deleted.

Example ([url removed, login to view])

192.168.1.5

[url removed, login to view]

Example ([url removed, login to view])

101.1.168.192.in-addr.arpa.

102.1.168.192.in-addr.arpa.

So in this example it should go to the PTR txt file and delete the first entry from all the DNS servers in that complete list. The it needs to move on to the second PTR record, etc, etc... So only one PTR is being deleted from all list of DNS servers.

This can be done in powershell or *.bat file. I would prefer Powershell.. Then just have it run the "dnscmd" command. We can set a variable for "cachedEntry = Get-Content to make the process work.

Kemahiran: Pengaturcaraan C++, DOS, Powershell

Lihat lagi: dos on line, 192 168.1.1

Tentang Majikan:
( 20 ulasan ) Tomball, United States

ID Projek: #10099028

2 pekerja bebas membida secara purata $94 untuk pekerjaan ini

$157 USD dalam 5 hari
(2 Ulasan)
3.1
reubenmejia

Hi, Thank you for posting this project. I have extensive experience in PowerShell and Batch file (*.bat & *.cmd) coding. I can complete this quickly. Thank you, Reuben Mejia

$30 USD dalam sehari
(0 Ulasan)
0.0