Last updated by at .

  • Hyper-V 2016
    What's new in Hyper-V 2016
  • Microsoft Azure
    Microsoft Azure

Tag: Networking

VM Network Adapter

PowerShell One-liner to list IP Addresses of Hyper-V Virtual Machines

Here a very quick PowerShell command to list all the Virtual Network Adapters, including IP Addresses of Virtual Machines running on a Hyper-V Host.

This will give you a list of all Virtual Machines running on Hyper-V Server called “HyperV01”



Get-NetIPConfiguration

Basic Networking PowerShell cmdlets cheatsheet to replace netsh, ipconfig, nslookup and more

Around 4 years ago I wrote a blog post about how to Replace netsh with Windows PowerShell which includes basic powershell networking cmdlets. After working with Microsoft Azure, Nano Server and Containers, Powershell together with networking becomes more and more important. I created this little cheat sheet so it becomes easy for people to get started.

Basic Networking Information with PowerShell

Get-NetIPConfiguration

Get the IP Configuration (ipconfig with PowerShell)

List all Network Adapters

Get a spesific network adapter by name

Get more information VLAN ID, Speed, Connection status

Get driver information

Get adapter hardware information. This can be really usefull when you need to know the PCI slot of the NIC.

Disable and Enable a Network Adapter

Rename a Network Adapter

IP Configuration using PowerShell

Get-NetIPAddress

Get IP and DNS address information

Get IP address only

Get DNS Server Address information

Set IP Address

or if you want to change a existing IP Address

Remove IP Address

Set DNS Server

Set interface to DHCP

Ping with PowerShell

Test-NetConnection Ping

How to Ping with PowerShell

Get some more details from the Test-NetConnection

Ping multiple IP using PowerShell

Tracert

PowerShell Tracert

Tracert with PowerShell

Portscan with PowerShell

PowerShell Portscan

Use PowerShell to check for open port

NSlookup in PowerShell

PowerShell NSlookup

NSlookup using PowerShell:

Route in PowerShell

PowerShell Route

How to replace Route command with PowerShell

NETSTAT in PowerShell

PowerShell Netstat

How to replace NETSTAT with PowerShell

NIC Teaming PowerShell commands

Create a new NIC Teaming (Network Adapter Team)

SMB Related PowerShell commands

SMB PowerShell SMB Client Configuration

Get SMB Client Configuration

Get SMB Connections

Get SMB Mutlichannel Connections

Get SMB open files

Get SMB Direct (RDMA) adapters

Hyper-V Networking cmdlets

Hyper-V PowerShell Get-VMNetwork Adapter

Get and set Network Adapter VMQ settings

Get VM Network Adapter

Get VM Network Adapter IP Addresses

Get VM Network Adapter Mac Addresses

I hope you enjoyed it and the post was helpful, if you think something important is missing, please add it in the comments.



Hyper-V VM Switch

Change Hyper-V VM Switch of Virtual Machines using PowerShell

This is one of the first post of a short blog series with some simple PowerShell scripts and oneliners for Hyper-V. One this is how you can connect a Virtual Network Adapter of a Hyper-V Virtual Machine to another Virtual Switch.

This is very simple, with this command you can see all the Network Adapters of the Virtual Machine and to which Switch they are connected:

With this command you can connect it to another Switch:

Now of course you can also do this for all Virtual Machines running on a Hyper-V host:



CDN Consistent Device Naming

Cisco UCS supports Consistent Device Naming (CDN)

Yesterday I posted about Cisco UCS supporting RDMA (SMB Direct) with firmware version 2.2(4b)B. Walter Dey, former Cisco Distinguished Engineer at Cisco informed me not only about the RDMA feature he also showed me that Cisco UCS now supports Consistent Device Naming which was introduced with Windows Server 2012. Consistent Device Naming (CDN) allows Ethernet interfaces to be named in a consistent manner. This makes Ethernet interface names more persistent when adapter or other configuration changes are made. To use CDN in Cisco UCS you need to run firmware version 2.2(4b)B. This will help to make it a lot easier to identify network interfaces used with Windows Server 2012 R2 and Hyper-V.



Microsoft Exam 70-533 Implementing Microsoft Azure Infrastructure Solutions

Passed Microsoft Exam 70-533 Implementing Microsoft Azure Infrastructure Solutions

A couple of weeks ago I passed Microsoft Exam 70-533 Implementing Microsoft Azure Infrastructure Solutions, which is focused on implementing and designing Microsoft Azure Infrastructure solutions such as Azure Websites or Azure Virtual Machines (IaaS). I think taking this exam and preparing for it was a great idea. Even if I have already done a couple of projects on Azure I still learned a lot during the preparation and you can find some of the best practices. Since Azure is a huge beast and the rapid deployment of new features, you will definitely find some new stuff you didn’t know before during the preparation for the exam. And of course taking new Microsoft Certifications early helps you to stand out in the IT Pro or Developer world. Of course passing exams alone does not make you an expert, but if you have know-how on a topic it’s is always got to have some kind of paper to prove it.

So what are the skills measured for this exam. The exam 70-533 focuses on 6 topics, Azure Websites, Virtual Machines, Cloud Services, Storage, Azure Active Directory and Virtual Networks. To my surprise I got a really good score on Azure Websites and of course Virtual Machines, since I used to run several of them on Azure. I also found out that Azure Active Directory is one of the parts I have to invest a little more.

Skills measured

Implement websites (15-20%)

  • Deploy websites
    • Define deployment slots; roll back deployments, configure and deploy packages, deploy web jobs, schedule web jobs
  • Configure websites
    • Configure app settings, connection strings, handlers, and virtual directories; configure certificates, custom domains, and traffic manager; configure SSL bindings and runtime configurations; manage websites by using Windows PowerShell and Xplat-CLI
  • Configure diagnostics, monitoring, and analytics
    • Retrieve diagnostics data; view streaming logs; configure endpoint monitoring, alerts, and diagnostics; monitor website resources
  • Configure scale and resilience
    • Configure auto-scale using built-in and custom schedules; configure by metric; change the size of an instance
  • Manage hosting plans
    • Create hosting plans; migrate websites between hosting plans; create a website within a hosting plan

Implement virtual machines (15-20%)

  • Deploy workloads on Azure virtual machines (VMs)
    • Identify supported Microsoft workloads; deploy and connect to a Linux VM; create VMs
  • Implement images and disks
    • Create specialized and generalized images for Windows and Linux; copy images between storage accounts and subscriptions; upload VHDs
  • Perform configuration management
    • Automate configuration management by using PowerShell Desired State Configuration and custom script extensions; enable puppet and chef extensions
  • Configure VM networking
    • Settings include reserved IP addresses, access control list (ACL), internal name resolution, DNS at the cloud service level, load balancing endpoints, HTTP and TCP health probes, public IPs, firewall rules, direct server return, and Keep Alive
  • Configure VM resiliency
    • Scale up and scale down VM sizes; auto-scale; configure availability sets
  • Design and implement VM storage
    • Configure disk caching; plan storage capacity; configure operating system disk redundancy; configure shared storage using Azure File service; configure geo-replication; encrypt disks
  • Monitor VMs
    • Configure endpoint monitoring, alerts, and diagnostics

Implement cloud services (15-20%)

  • Configure cloud services and roles
    • Configure instance count and size, operating system version and family, upgrade and fault domains, ACLs, reserved IPs, and network access rules; configure local storage; configure dedicated and co-located caching, local and cloud configurations, and local disks; configure multiple websites; configure custom domains
  • Deploy and manage cloud services
    • Upgrade a deployment; VIP swap a deployment; package a deployment; modify configuration files; perform in-place updates; perform runtime configuration changes using the portal; scale a cloud service; create service bus namespaces and choose a tier; apply scalability targets
  • Monitor cloud services
    • Monitor service bus queues, topics, relays, and notification hubs; configure diagnostics

Implement storage (15-20%)

  • Implement blobs and Azure files
    • Read data; change data; set metadata on a container; use encryption (SSL); perform an async blob copy; configure a Content Delivery Network (CDN); implement storage for backup and disaster recovery; configure Azure Backup; define blob hierarchies; configure custom domains; configure the Import and Export Service
  • Manage access
    • Create and manage shared access signatures; use stored access policies; regenerate keys
  • Configure diagnostics, monitoring, and analytics
    • Configure retention policies and logging levels; analyze logs
  • Implement SQL databases
    • Choose the appropriate database tier and performance level; configure point in time recovery and geo-replication; import and export data and schema; design a scaling strategy
  • Implement recovery services
    • Create a backup vault; deploy a backup agent; back up and restore data

Implement an Azure Active Directory (15-20%)

  • Integrate an Azure AD with existing directories
    • Implement DirSync, O365 integration, and single sign-on with on-premises Windows Server 2012 R2; add custom domains; monitor Azure AD
  • Configure the Application Access Panel
    • Configure single sign-on with SaaS applications using federation and password based; add users and groups to applications; revoke access to SaaS applications; configure access; federation with Facebook and Google ID
  • Integrate an app with Azure AD
    • Web apps (WS-federation); desktop apps (OAuth); graph API

Implement virtual networks (15-20%)

  • Configure a virtual network
    • Deploy a VM into a virtual network; deploy a cloud service into a virtual network; configure static IPs; configure internal load balancing; design subnets
  • Modify a network configuration
    • Modify a subnet; import and export a network configuration
  • Design and implement a multi-site or hybrid network
    • Choose the appropriate solution between ExpressRoute, site-to-site, and point-to-site; choose the appropriate gateway; identify supported devices and software VPN solutions; identify networking prerequisites; configure regional virtual networks and multi-site virtual networks

Preparation

To prepare for the exam I used several different resources such as Microsoft Virtual Academy, TechNet, Channel9 and of course Microsoft Azure it self. I also found some great community blogs which have some link summaries:

If you are going to take this exam I wish you good luck.



AzureStartup

Microsoft Azure Update at Build 2014

At the Build Conference 2014 Microsoft already announced a lot of new stuff for the whole Microsoft or IT ecosystem. There is absolutely no time to cover all the changes and announcements Microsoft has made in the past 2 days. So I will just focus on the things I care about.

  • Prior to the Build Conference Microsoft announced that Windows Azure will be renamed to Microsoft Azure. This will show how Microsoft is not only building on top of the Windows platform, they also have opened up for other platforms an solutions a long time ago. One example for that maybe was the announcement of supporting Oracle Software in Microsoft Azure around a year ago.
  • Mark Russinovich announced some great new changes to Microsoft Azure IaaS. You can now capture and deploy images, you can Puppet and Chef as well as PowerShell DSC support, to configure you server environment. An this is great for developers, some of the features will show up directly in Visual Studio. Microsoft also did some work on the Networking site which was really important, for example you can now change the subnet for Virtual Machines.
    Microsoft Azure Announcements
  • Microsoft also launched a lot of new preview features like Azure Cache and a lot more. What I love the most is the new Microsoft Azure feature called Azure Automation. Azure Automation allows you to automate the creation, monitoring, deployment, and maintenance of resources in your Azure environment using a highly-available workflow execution engine. Orchestrate time-consuming, error-prone, and frequently repeated tasks against Azure and third party systems to decrease time to value for your cloud operations. This is basically Service Management Automation (SMA), which was released with System Center 2012 R2 as a on premise version, now running up in Microsoft Azure. For those how haven’t heard about SMA, SMA is a new automation engine and Runbooks in Service Management Automation and Microsoft Azure Automation are Windows PowerShell workflows.
    Microsoft Azure Automation
  • Microsoft also release a new preview of the Microsoft Azure portal. Since Microsoft released a huge number of new features in Azure, the “old” management portal didn’t really fit the requirements anymore. The new Azure management portal helps you to be much more organized and is using a lot of new concept like “blades” to help you navigate through your Azure environment. The new dashboard also gives you a quick overview about the Microsoft Azure datacenters and there service status, and the new touch friendly dashboard also allows you to customize it for your need. You can check it out on portal.azure.com
    New Microsoft Azure Portal
  • I am not a developer but I was really impressed what Microsoft did for developers. They are just generating a huge numbers of new opportunities with their new platforms not only in Microsoft Azure using IaaS, mobile Services or PaaS, Microsoft also announced a new concept of Universal Apps which allows developers to write apps which run on Windows Phone, Windows and Xbox One. Some days ago Microsoft also showed the new Kinect v2 hardware which I hope developers will use to write some really cool stuff. If we have a lot back at Microsoft Azure, what I really liked about the new Portal is the  integration of Team Foundation Server or “team projects”.
    Microsoft Azure Team Projects

This are just a few of the cool new things Microsoft announced at Build 2014, there is a lot more which is definitely worth to talk about.



PowerShell NetAdpater Advanced Property

Hyper-V Network Virtualization NVGRE: No connection between VMs on different Hyper-V Hosts

I have worked on some project with Hyper-V Network Virtualization and NVGRE, and today I have seen an issue with Encapsulated Task Offloading on some HP Broadcom Network adapters.

 

Issue

I have Hyper-V Hosts running with 10GbE Broadcom Network Adapters (HP Ethernet 10Gb 2-port 530FLR-SFP+ Adapter) with driver version 7.8.52.0 (released in 2014). I have created a new VM Network based on Hyper-V Network Virtualization using NVGRE. VM1 is running on Host1 and VM2 is running on Host2. You can ping VM2 from VM1 but there is no other connection possible like SMB, RDP, HTTP or DNS. If you are using a NVGRE Gateway you can no even resolve DNS inside those VMs. If VM1 and VM2 are running on the same Hyper-V host everything between those VMs works fine.

Advanced Driver Settings

If you are using Server Core, which you should by the way, you can use the following command to check for those settings:

PowerShell NetAdpater Advanced Property

 

Resolution

The Broadcom Network adapters have a feature called Encapsulated Task Offloading which is enabled by default. If you disable Encapsulated Task Offloading everything works fine. You can disable it by using the following PowerShell cmdlet.

After that connection inside the VMs started to work immediately, no reboot needed.