Problem with Add-VPNConnection to create VPN Phonebook Entry

Welcome Forums General PowerShell Q&A Problem with Add-VPNConnection to create VPN Phonebook Entry

Viewing 0 reply threads
  • Author
    Posts
    • #132845
      Participant
      Topics: 1
      Replies: 0
      Points: 13
      Rank: Member

      I’m writing a very simply PowerShell script to create a VPN Phonebook entry for all users on the computer, but I cannot figure out how to enable the option to register this  connection’s addresses in DNS.  Microsoft doesn’t include that as a switch with Add-VPNConnection, and I am stuck on how else to accomplish this.  I really don’t want to simply create a phonebook file (PBK) and push it out.  That is old school, and it will step on existing entries in the PBK file.

      The closest I’ve come is the following:

      Set-DNSClient -InterfaceAlias ‘VPN Name’ -RegisterThisConnectionsAddress:$True

      That doesn’t really work, though, because the VPN must be connected.  I think it is only temporary for that session, and it isn’t really updating the phonebook entry.

      Any ideas?

       

Viewing 0 reply threads
  • The topic ‘Problem with Add-VPNConnection to create VPN Phonebook Entry’ is closed to new replies.