IP address change via PowerShell
I found this excellent article here showing how to deploy a PowerShell script to change IP address settings. http://www.adminarsenal.com/admin-arsenal-blog/using-powershell-to-set-static-and-dhcp-ip-addresses-part-2/
One small problem, after the script runs, the PDQ job eventually times out with the error "Package returned no error code", which makes sense because it just successfully changed the IP address!
I can live with it, but does anybody have a suggestion for fixing this?
Thanks, John
0
Comments
I would use GPO logon script for that, put it under run once key.
I second this, using PDQ Deploy to change IP address settings is not going to be your best option, especially in a domain environment. This being that the runner service needs connectivity throughout the process to report status information back to the console.
A GPO to update the network settings on devices in question, in this case, is going to be your best practice.
Thanks to all. The PowerShell script is doing the trick, so I'll probably stick with it. The error is really just an inconvenience, and I have to verify all of the changes anyway.
John