mountainss Cloud and Datacenter Management Blog

Microsoft SystemCenter blogsite about virtualization on-premises and Cloud


Leave a comment

NEW #Docker version 1.13.0 available for Download #Containers #ACS #DevOps

docker-logo

  • Upgrades
  • New
    • Windows containers
    • Improved UI for Daemon.json editing
    • VHDX file containing images and non-host mounted volumes can be moved (using “advanced” tab in the UI)
    • Support for arm, aarch64, ppc64le architectures using qemu
    • TRIM support for disk (shrinks virtual disk)
    • VM’s time synchronization is forced after the host wakes from sleep mode
    • Docker Experimental mode can be toggled
  • Bug fixes and minor changes
    • Improved Proxy UI
    • Improvements to Logging and Diagnostics
    • About Box is now Copy/Paste enabled
    • Improvements in drive sharing code
    • Optimized boot process
    • Trend Micro Office Scan made the Api proxy think no drive was shared
    • Show a link to the virtualization documentation
    • Always remove the disk on factory reset (#5719)
    • VPNKit: Improved diagnostics (#6080, #6104)
    • VPNKit: Forwarded UDP datagrams should have correct source port numbers (#5926)
    • VPNKit: If one request fails, allow other concurrent requests to succeed. For example this allows IPv4 servers to work even if IPv6 is broken. (#5926)
    • VPNKit: Fix bug which could cause the connection tracking to underestimate the number of active connections (#5926)
    • VPNKit: add a local cache of DNS responses

docker-version-1130


Leave a comment

Running #NanoServer in a #Container on Windows Server 2016 with #Docker in Powershell #DevOps

windows-containers

What are Containers

They are an isolated, resource controlled, and portable operating environment. 

Basically, a container is an isolated place where an application can run without affecting the rest of the system and without the system affecting the application. Containers are the next evolution in virtualization. 

If you were inside a container, it would look very much like you were inside a freshly installed physical computer or a virtual machine. And, to Docker, a Windows Server Container can be managed in the same way as any other container.

Windows Container Types

Windows Containers include two different container types, or runtimes. 

Windows Server Containers – provide application isolation through process and namespace isolation technology. A Windows Server container shares a kernel with the container host and all containers running on the host.

Hyper-V Containers – expand on the isolation provided by Windows Server Containers by running each container in a highly optimized virtual machine. In this configuration the kernel of the container host is not shared with the Hyper-V Containers. 

hyper-v-containers

Container Fundamentals

When you begin working with containers you will notice many similarities between a container and a virtual machine. A container runs an operating system, has a file system and can be accessed over a network just as if it was a physical or virtual computer system. That said, the technology and concepts behind containers are very different from that of virtual machines.

The following key concepts will be helpful as you begin creating and working with Windows Containers.  

Container Host: Physical or Virtual computer system configured with the Windows Container feature. The container host will run one or more Windows Containers.

Container Image: As modifications are made to a containers file system or registry, such as with software installation they are captured in a sandbox. In many cases you may want to capture this state such that new containers can be created that inherit these changes. That’s what an image is – once the container has stopped you can either discard that sandbox or you can convert it into a new container image. For example, let’s imagine that you have deployed a container from the Windows Server Core OS image. You then install MySQL into this container. Creating a new image from this container would act as a deployable version of the container. This image would only contain the changes made (MySQL), however would work as a layer on top of the Container OS Image.

Sandbox: Once a container has been started, all write actions such as file system modifications, registry modifications or software installations are captured in this ‘sandbox’ layer.

Container OS Image: Containers are deployed from images. The container OS image is the first layer in potentially many image layers that make up a container. This image provides the operating system environment. A Container OS Image is Immutable, it cannot be modified.

Container Repository: Each time a container image is created the container image and its dependencies are stored in a local repository. These images can be reused many times on the container host. The container images can also be stored in a public or private registry such as DockerHub so that they can be used across many different container host.

You have to install these Windows Server 2016 Rolls and Feature first before you start with Containers :

  • Hyper-V
  • Containers

system

My Windows 2016 Server Build version.

hyperv-install

Install Hyper-V

container-feature-installed

Install Containers

Here is an example on my Windows 2016 Server to get started with Windows Containers :

containers1

Install-Module -Name DockerMsftProvider -Repository PSGallery -Force

containers2

Install-Package -Name docker -ProviderName DockerMsftProvider

containers3

containers4

Restart-Computer -Force

containers5

Here we pull out of the Docker Hub the Microsoft Nanoserver Container.

containers6

Downloading the Image.

containers7

Automatically extract the image.

containers8 Docker Container Image Microsoft/nanoserver is downloaded.

run-container

Docker run -i -t microsoft/nanoserver

docker-container-session

docker ps
( you will see the container with Nanoserver is running)

container-nic

Inside the container.

powershell-nanoserver-from-docker-container

Running Powershell inside the container.

Containers for Developers

From a developer’s desktop to a testing machine to a set of production machines, a Docker image can be created that will deploy identically across any environment in seconds. This story has created a massive and growing ecosystem of applications packaged in Docker containers, with DockerHub, the public containerized-application registry that Docker maintains, currently publishing more than 180,000 applications in the public community repository.  

When you containerize an app, only the app and the components needed to run the app are combined into an “image”. Containers are then created from this image as you need them. You can also use an image as a baseline to create another image, making image creation even faster. Multiple containers can share the same image, which means containers start very quickly and use fewer resources. For example, you can use containers to spin up light-weight and portable app components – or ‘micro-services’ – for distributed apps and quickly scale each service separately. 

Because the container has everything it needs to run your application, they are very portable and can run on any machine that is running Windows Server 2016. You can create and test containers locally, then deploy that same container image to your company’s private cloud, public cloud or service provider. The natural agility of Containers supports modern app development patterns in large scale, virtualized and cloud environments.

With containers, developers can build an app in any language. These apps are completely portable and can run anywhere – laptop, desktop, server, private cloud, public cloud or service provider – without any code changes.

Containers helps developers build and ship higher-quality applications, faster.

Containers for IT Pro’s

IT Professionals can use containers to provide standardized environments for their development, QA, and production teams. They no longer have to worry about complex installation and configuration steps. By using containers, systems administrators abstract away differences in OS installations and underlying infrastructure. Containers help admins create an infrastructure that is simpler to update and maintain

microsoft-containers

Lot of Success with Containers and Nanoserver
#MVPbuzz


Leave a comment

#Docker containers running on #Windows10 for #DevOps #Azure

docker-site-1

Docker for Windows

An integrated, easy-to-deploy environment for building, assembling, and shipping applications from a Windows PC, Docker for Windows is a native Windows application with a native user interface and auto-update capability, deeply integrated with Windows native virtualization, Hyper-V, networking and file system, making it faster and more reliable than previous ways of getting Docker on a Windows PC

Before you install Docker for Windows 10 make sure you have the right Windows 10 version.
The current version of Docker for Windows runs on 64bit Windows 10 Pro, Enterprise and Education (1511 November update, Build 10586 or later).
And have the Hyper-V feature of Windows 10 installed. Here you can download Docker for Windows 10

docker-download

docker-setup1

Click on Install.

docker-setup2

Click Finish and Launch Docker

docker-is-running-1

hyper-v

The Docker VM

docker-is-up

Now you can work from Powershell with Docker Containers :

docker-help

There is also a graphical GUI called Kitematic with the Docker Hub connection for the Container marketplace.

open-kitematic

This will download Kitematic.

kitematicExtract the zip file and run Kitematic

kitematic-icon

docker-kite

Kitematic with recommended Docker Containers to download 😉

azure-containers

If you search for Azure you find a lot of Azure related Docker Containers.

It’s so easy to download a container from the Docker Hub and make it running on your Windows 10 Machine, here is an example of an Jenkins Container:

jenkins

Click Create.

download-images

It’s downloading the Docker Container Image.

jenkins-3

Jenkins is already running in the Docker Container and is
asking some questions for the setup.

jenkins-4

Jenkins is setting up the environment.

jenkins-5

jenkins-6

And now we have Jenkins in a Container running.

Here you can find more information about Jenkins

jenkins-running

And with Kitematic you can see the log of the Jenkins Container
Here you can start, restart or stop the Docker Containers.

jenkins-inspect

Here I did a Docker Inspect Jenkins to see settings of the Container.

Hope this blogpost is useful to play with Docker Containers on your Windows 10 device 😉

When you want to learn more about Microsoft Windows Containers you can start here :

Windows Containers Documentation

acs

When you want to learn more about Microsoft Azure Container Services you can start here :

Azure Container Service Documentation

docker-containers

Lot of Success with running Containers !


Leave a comment

NEW Free #Microsoft Windows Server 2016 Ebook Available #Winserv #Hyperv #NanoServer #Containers

windows-server-2016-ebook-cover

Windows Server has powered a generation of organizations, from small businesses to large enterprises. No matter what your role in IT, you can be guaranteed you that have touched Windows Server at some point in your career or at very least you have seen it from afar! This book introduces you to Windows Server 2016, which is the next version of Windows Server. No matter what your area of expertise, this book will introduce you to the latest developments in Windows Server 2016.

Here you can download the Free Microsoft Windows Server 2016 Ebook

SCUG Banner

 


Leave a comment

#MSIgnite recorded Video Sessions #Azure #AzureStack #MSOMS #Sysctr #Winserv and More

Take your management and security strategy to the cloud with Operations Management Suite (OMS)

Review Microsoft Azure Stack with Jeffrey Snover and Mark Russinovich

Dive deep into Operations Management Suite for applications and infrastructure

Here you find all the recorded Microsoft Ignite video sessions 2016

SCUG Banner


Leave a comment

#WindowsContainer Host Deployment on #NanoServer #HyperV nested Virtualization

Hyper-V-Containers-Nested-Virtualization

Windows Containers on Hyper-V NanoServer nested Virtualization

Deployment Steps

Install Container Feature

The container feature can be installed on Windows Server 2016, or Windows Server 2016 Core, using Windows Server Manager or PowerShell.

To install the role using PowerShell, run the following command in an elevated PowerShell session.

Install Containers

PS C:\> Install-WindowsFeature containers

The system needs to be rebooted when the container role installation has completed.

PS C:\> shutdown /r

After the system has rebooted, use the Get-ContainerHost command to verify that the container role has successfully been installed:

Get-Containerhost

PS C:\> Get-ContainerHost

Prepare Nano Server

Deploying Nano Server involves creating a prepared virtual hard drive, which includes the Nano Server operating system, and additional feature packages. This guide quickly details preparing a Nano Server virtual hard drive, which can be used for Windows Containers.

For more information on Nano Server, and to explore different Nano Server deployment options, see the Nano Server Documentation.

Create a folder named nano.

PS C:\> New-Item -ItemType Directory c:\nano

Locate the NanoServerImageGenerator.psm1 and Convert-WindowsImage.ps1 files from the Nano Server folder, on the Windows Server Media. Copy these to c:\nano.

#Set path to Windows Server 2016 Media
PS C:\> $WindowsMedia = "C:\Users\Administrator\Downloads\WindowsServerTP4"

PS C:\> Copy-Item $WindowsMedia\NanoServer\Convert-WindowsImage.ps1 c:\nano
PS C:\> Copy-Item $WindowsMedia\NanoServer\NanoServerImageGenerator.psm1 c:\nano

Run the following to create a Nano Server virtual hard drive. The –Containers parameter indicates that the container package will be installed, and the –Compute parameter takes care of the Hyper-V package. Hyper-V is only required if Hyper-V containers will be created.

Import-Module

PS C:\> Import-Module C:\nano\NanoServerImageGenerator.psm1
PS C:\> New-NanoServerImage -MediaPath $WindowsMedia -BasePath c:\nano -TargetPath C:\nano\NanoContainer.vhdx -MaxSize 10GB -GuestDrivers -ReverseForwarders -Compute -Containers

When completed, create a virtual machine from the NanoContainer.vhdx file. This virtual machine will be running the Nano Server OS, with optional packages.

Configure Nested Virtualization

If the container host itself will be running on a Hyper-V virtual machine, and will also be hosting Hyper-V Containers, nested virtualization needs to be enabled. This can be completed with the following PowerShell command.

The virtual machines must be turned off when running this command.

PS C:\> Set-VMProcessor -VMName <container host vm> -ExposeVirtualizationExtensions $true

Configure Virtual Processors

If the container host itself will be running on a Hyper-V virtual machine, and will also be hosting Hyper-V Containers, the virtual machine will require at least two processors. This can be configured through the settings of the virtual machine, or with the following PowerShell script.

PS C:\> Set-VMProcessor –VMName <VM Name> -Count 2

Enable Hyper-V Role

If Hyper-V Containers will be deployed, the Hyper-V role needs to be enabled on the container host. If the container host is a virtual machine, ensure that nested virtualization has been enabled. The Hyper-V role can be installed on Windows Server 2016 or Windows Server 2016 Core using the following PowerShell command.

PS C:\> Install-WindowsFeature hyper-v

Create Virtual Switch

Each container needs to be attached to a virtual switch in order to communicate over a network. A virtual switch is created with the New-VMSwitch command. Containers support a virtual switch with type External or NAT.

This example creates a virtual switch with the name “Virtual Switch”, a type of NAT, and Nat Subnet of 172.16.0.0/12.

PS C:\> New-VMSwitch -Name "Virtual Switch" -SwitchType NAT -NATSubnetAddress 172.16.0.0/12

Configure NAT

In addition to creating a virtual switch, if the switch type is NAT, a NAT object needs to be created. This is completed using the New-NetNat command. This example creates a NAT object, with the name ContainerNat, and an address prefix that matches the NAT subnet assigned to the container switch.

Finally, if the container host is running inside of a Hyper-V virtual machine, MAC spoofing must be enable. This allows each container to receive an IP Address. To enable MAC address spoofing, run the following command on the Hyper-V host. The VMName property will be the name of the container host.

PS C:\> Get-VMNetworkAdapter -VMName <contianer host vm> | Set-VMNetworkAdapter -MacAddressSpoofing On

Install OS Images

An OS image is used as the base to any Windows Server or Hyper-V container. The image is used to deploy a container, which can then be modified, and captured into a new container image. OS images have been created with both Windows Server Core and Nano Server as the underlying operating system.

Container OS images can be found and installed using the ContainerProvider PowerShell module. Before using this module, it needs to be installed. The following commands can be used to install the module.

PS C:\> Install-PackageProvider ContainerProvider -Force

Return a list of images from PowerShell OneGet package manager:

PS C:\> Find-ContainerImage

Name                 Version                 Description
----                 -------                 -----------
NanoServer           10.0.10586.0            Container OS Image of Windows Server 2016 Techn...
WindowsServerCore    10.0.10586.0            Container OS Image of Windows Server 2016 Techn...

To download and install the Nano Server base OS image, run the following.

PS C:\> Install-ContainerImage -Name NanoServer -Version 10.0.10586.0
Downloaded in 0 hours, 0 minutes, 10 seconds.

Likewise, this command downloads and installs the Windows Server Core base OS image.

Issue: Save-ContainerImage and Install-ContainerImage cmdlets fail to work with a WindowsServerCore container image, from a remote PowerShell session.
Workaround: Logon to the machine using Remote Desktop and use Save-ContainerImage cmdlet directly.

PS C:\> Install-ContainerImage -Name WindowsServerCore -Version 10.0.10586.0
Downloaded in 0 hours, 2 minutes, 28 seconds.

Verify that the images have been installed using the Get-ContainerImage command.

PS C:\> Get-ContainerImage

Name              Publisher    Version      IsOSImage
----              ---------    -------      ---------
NanoServer        CN=Microsoft 10.0.10586.0 True
WindowsServerCore CN=Microsoft 10.0.10586.0 True

For more information on Container management See Windows Containers Documentation

MSFT Containers


Leave a comment

#Microsoft Azure Stack: Hardware requirements Released by @Jsnover #AzureStack #Cloud #MAS

Here you can find the Microsoft Azure Stack Technical Preview (POC) Hardware Requirements

Microsoft is bringing Azure Cloud Services to your Datacenter with Microsoft Azure Stack

Cloud Applications

It’s all about delivering Cloud Applications