PowerCLI

 View Only
  • 1.  forward and reverse dns entries _powershell

    Posted Dec 11, 2018 03:36 PM

    Hi Luc,

    could you suggest the powershell way of creating some dns records .there are around 15-20 machines including esxi for which i need to create forward and reverse dns recored.

    this is not powerclibut if could suggest .



  • 2.  RE: forward and reverse dns entries _powershell
    Best Answer

    Posted Dec 11, 2018 04:58 PM

    You will need the DnsServer module.
    Note that this module is not available through the PowerShell Gallery.

    It is available on Windows Servers when you install the DNS feature, and it comes with the RSAT package when you select the DNS component.

    Once you have the DnsServer module, the cmdlets are rather straight-forward.

    Add-DnsServerResourceRecordA -Name "myhost" -ZoneName "domain.com" `

        -AllowUpdateAny -IPv4Address "192.168.1.1" -TimeToLive 01:00:00

    Add-DnsServerResourceRecordPtr -Name "1" -ZoneName "1.168.192.in-addr.arpa" `

        -AllowUpdateAny -TimeToLive 01:00:00 -AgeRecord -PtrDomainName "myhost.domain.com"



  • 3.  RE: forward and reverse dns entries _powershell

    Posted Dec 12, 2018 07:59 AM

    thanks  iam checking this on dns server.