Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Exam Ref AZ-104 Microsoft Azure Administrator Certification and Beyond

You're reading from   Exam Ref AZ-104 Microsoft Azure Administrator Certification and Beyond A pragmatic guide to achieving the Azure administration certification

Arrow left icon
Product type Paperback
Published in Jul 2022
Publisher Packt
ISBN-13 9781801819541
Length 776 pages
Edition 2nd Edition
Tools
Arrow right icon
Authors (2):
Arrow left icon
Donovan Kelly Donovan Kelly
Author Profile Icon Donovan Kelly
Donovan Kelly
Riaan Lowe Riaan Lowe
Author Profile Icon Riaan Lowe
Riaan Lowe
Arrow right icon
View More author details
Toc

Table of Contents (30) Chapters Close

Preface 1. Part 1: Managing Azure Identities and Governance
2. Chapter 1: Managing Azure Active Directory Objects FREE CHAPTER 3. Chapter 2: Managing Role-Based Access Control 4. Chapter 3: Creating and Managing Governance 5. Chapter 4: Managing Governance and Costs 6. Chapter 5: Practice Labs – Managing Azure Identities and Governance 7. Part 2: Implementing and Managing Storage
8. Chapter 6: Understanding and Managing Storage 9. Chapter 7: Securing Storage 10. Chapter 8: Practice Labs – Implementing and Managing Storage 11. Part 3: Deploying and Managing Azure Compute Resources
12. Chapter 9: Automating VM Deployments Using ARM Templates 13. Chapter 10: Configuring Virtual Machines 14. Chapter 11: Creating and Configuring Containers 15. Chapter 12: Creating and Configuring App Services 16. Chapter 13: Practice Labs – Deploying and Managing Azure Compute Resources 17. Part 4: Configuring and Managing Virtual Networking
18. Chapter 14: Implementing and Managing Virtual Networking 19. Chapter 15: Securing Access to Virtual Networks 20. Chapter 16: Configuring Load Balancing 21. Chapter 17: Integrating On-Premises Networks with Azure 22. Chapter 18: Monitoring and Troubleshooting Virtual Networking 23. Chapter 19: Practice Labs – Configuring and Managing Virtual Networking 24. Part 5: Monitoring and Backing Up Azure Resources
25. Chapter 20: Monitoring Resources with Azure Monitor 26. Chapter 21: Implementing Backup and Recovery Solutions 27. Chapter 22: Practice Labs – Monitoring and Backing Up Azure Resources 28. Chapter 23: Mockup Test Questions and Answers 29. Other Books You May Enjoy

Create private and public IP addresses

In the previous section, we had a brief look at IP addressing, such as public and private IP addressing and also static and dynamic IP addresses. This section focuses on how to configure private and public IP addresses.

Let's first look at how to configure a private IP address for a VM from dynamic to static via the Azure portal. In order to do this, we are going to reference a VM we created earlier in this book:

  1. Navigate to the Azure portal by opening a web browser and navigating to https://portal.azure.com.
  2. In the left menu, select Resource groups and choose an RG with a VM. In this case, we're going to select the Az-104 RG:
Figure 14.10 – Selecting a previously deployed RG that has a VM

Figure 14.10 – Selecting a previously deployed RG that has a VM

  1. Next, select the VM:
Figure 14.11 – Selecting a previously deployed VM

Figure 14.11 – Selecting a previously deployed VM

  1. Under the Settings tab, select Networking and click on the Network Interface Card (NIC) associated with the VM:
Figure 14.12 – Select the NIC for the VM

Figure 14.12 – Select the NIC for the VM

  1. Next, click on IP configurations and select Private IP address:
Figure 14.13 – Select the private IP address associated with the VM

Figure 14.13 – Select the private IP address associated with the VM

  1. Finally, under Assignment, select Static instead of Dynamic, and click Save:
Figure 14.14 – Select Static and save the configuration

Figure 14.14 – Select Static and save the configuration

That is how we configure private IP addresses to be static instead of dynamic.

Next, we are going to look at how to create a public IP address via PowerShell:

  1. In PowerShell, use the following command to connect to our Azure tenant:
    Connect-AzAccount

The following screenshot shows the output of the command:

Figure 14.15 – Authenticating to the Azure tenant via PowerShell

  1. Next, the following code will create a new static public IP address in the West Europe region as a standard SKU:
    $ip = @{
        Name = 'myStandardPublicIP'
        ResourceGroupName = 'VNet_Demo_ResourceGroup'
        Location = 'WestEurope'
        Sku = 'Standard'
        AllocationMethod = 'Static'
        IpAddressVersion = 'IPv4'
        Zone = 1,2,3
    }
    New-AzPublicIpAddress @ip

The following screenshot shows the output of the command:

Figure 14.16 – Creating a new public IP address via PowerShell code

Figure 14.16 – Creating a new public IP address via PowerShell code

  1. Finally, verify that the public IP address has been created in the Azure portal:

Figure 14.17 – Verifying the new public IP address in the Azure portal

It is that simple to create a public IP address via PowerShell. Once the IP address has been created, it is now ready to be assigned to a resource such as a VM or other types of resources that support pre-created public IP addresses.

Next, we are going to look at user-defined routing.

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image