I am experimenting with the Set-AzureStaticVNetIP powershell command to allocate a static IP address to VMs. I can get the command to work and allocate an IP address correctly to a VM, either on creation or once it is running, but nothing I do will persuade the VMs to continue to use this allocated IP address once the machine has been stopped and deallocated in the Azure console .

Am I doing something wrong - or is my understanding of this command wrong ? I thought it was designed specifically to allow a persistent IP to be allocated to domain controllers etc, as described in the azure documentation here


To answer the question below - I am calling UpdateVm after making the change, if applied to a running VM. This restarts the VM in question and it comes up correctly with the assigned IP address - the issue still remains that this IP address is not retained after a stop and de-allocate from the azure console.

Further update - it is the internal IP address which is changing, and I've tried calling Set-AzureStaticVNetIP both on create and update of VMS.



  • Are you executing Update-AzureVM after? Note: This will restart the VM. – Henry Erich III Mar 20 '14 at 14:21
  • Just to clarify (please edit your question): Are you seeing the external IP address changing, or the internal IP address changing? Also, please clarify whether you called Set-AzureStaticVNetIP when first creating the VM. – David Makogon Mar 24 '14 at 1:21

Interesting - the command works as expected if everything is in the EastUS region, but not in the European regions.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.