116355 Configure Hyperv 00

Embed Size (px)

Citation preview

  • 8/10/2019 116355 Configure Hyperv 00

    1/43

    Nexus 1000v Quickstart with HyperV ServerConfiguration Example

    Document ID: 116355

    Contributed by Chris Brown, Cisco TAC Engineer.

    Sep 04, 2013

    Contents

    Introduction

    Prerequisites

    Requirements

    Components Used

    Background Information

    Install Windows HyperV Server

    Introduction to Windows Core

    Install DriversAdd the HyperV Server to the Domain

    Enable Remote Access

    MMC

    Remote Desktop

    Windows Remote Shell

    Remote PowerShell

    Install Additional Roles

    Additional Configuration

    UseMPIOCPL in Orderto Launch the MPIO Wizard Once the Feature is Installed

    Add the HyperV Host to SCVMM

    Nexus 1000v on HyperV Use the Installer Application in Order to Install the Virtual Supervisor Modules (VSMs)

    Manually Install the Nexus 1000v

    Install the VSMs Manually

    Part 1 SCVMM Setup

    Part 2 VSM Deployment

    Part 3 VSM Basic Configuration

    Part 4 SVCMM Basic Configuration

    Part 5 Create the Logical Switch

    Part 6 Create VMNetworks Based on the Segments

    Add Host to DVS

    Manually Install the VEM

    Verify

    Troubleshoot

    Introduction

    This document describes how to configure Microsoft (MS) Windows HyperV Server 2012, install drivers,

    and add it to System Center Virtual Machine Manager (SCVMM). It also describes how to install and

    configure the Cisco Nexus 1000v Series switch, and add Virtual Machines (VMs) to the Nexus 1000v.

  • 8/10/2019 116355 Configure Hyperv 00

    2/43

  • 8/10/2019 116355 Configure Hyperv 00

    3/43

    The information in this document was created from the devices in a specific lab environment. All of the

    devices used in this document started with a cleared (default) configuration. If your network is live, make sure

    that you understand the potential impact of any command.

    Background Information

    HyperV core was released in parallel with Windows Server 2012. It only runs the Server Core installation of

    Server 2012 (which means no GUI, only CLI), and only runs HyperV and some related roles, such asClustering. The advantage of this is that HyperV core is completely free, except for support.

    Install Windows HyperV Server

    The HyperV server installs like any other Windows installation, which means you have to complete these

    steps:

    Reduce paths to storage down to one if you use Storage Area Network (SAN) storage.1.

    Install the required drivers when you use the installation wizard.2.

    The HyperV Server installation process is outside the scope of this document. However, it works like anyother Windows installation.

    Introduction to Windows Core

    MS is promoting the Server Core, which was introduced in 2008. The free version of HyperV only comes

    with Windows Core. However, with full installations, you can move between the two with a reboot.

    When you log into Windows Core, there are two windows ? a normal command prompt and the system

    configuration wizard.

    There are many options here that are used in order to perform basic installation/maintenance. The first step is

    to install the drivers for the Network Interface Controller (NIC) cards, which is covered in the next section.

    In order to get into PowerShell from the command prompt, typePowerShell.

  • 8/10/2019 116355 Configure Hyperv 00

    4/43

  • 8/10/2019 116355 Configure Hyperv 00

    5/43

    Enter thePowerShellcommand in order to get into PowerShell (before, you were simply in the

    Windows command prompt).

    3.

    Use theGetPSDrivelightweight command (cmdlet) in order to list all available drives, which

    includes your CD drive. In this case, the CD drive isE:\.

    4.

  • 8/10/2019 116355 Configure Hyperv 00

    6/43

    Navigate to the driver folder you want to install.5.

    Use thepnputil i a .\[driver].infcommand in order to install the driver.6.

  • 8/10/2019 116355 Configure Hyperv 00

    7/43

    Verify that the driver is installed. This command varies based on the driver; in the case of the ENIC,

    run theipconfigcommand.

    7.

    If you use DHCP, the address should be ready. Otherwise, return to the server configuration wizard,

    and configure an IP address with thesconfig.cmdcommand.

    8.

    Add the HyperV Server to the DomainWindows relies on a complex set of trust domains. In order to add your HyperV server to the SCVMM or to

    remotely manage your server, you must be a member of the same domain. There are other ways around this

    with the domain/workgroup trust, but they are outside the scope of this document.

    Enter thesconfig.cmdcommand in order to launch the server configuration wizard.1.

  • 8/10/2019 116355 Configure Hyperv 00

    8/43

    Enter1in order to launch the domain wizard. This guides you through the process used in order to

    add the server to a domain.

    2.

    Use your domain, and log in with the proper credentials.3.

    If a window does not appear that indicates that the settings have taken effect, reboot the computer

    with theshutdown rcommand in order to have the new settings take effect.

    4.

    Add aDNS entryfor your host with the DNS manager on the jumpserver.5.

    Enable Remote Access

    There are many ways in order to remotely access a server core. The best is the Microsoft Management

    Console (MMC).

  • 8/10/2019 116355 Configure Hyperv 00

    9/43

    MMC

    Runnetsh advfirewall set allprofiles state offon your host.1.

    In the Windows 2012 jumpserver, openServer Manager, and rightclickAll Servers.2.

    Search for your host, and add it to the server manager.

    You can now use Server Manager like you were on a local machine.

    3.

    Remote Desktop

    Run thecscript C:\Windows\System32\Scregedit.wsf /ar 0from the command prompt in order to enable

    remote desktop connections for administrators.

    You are now able to Remote Desktop Protocol (RDP) with accounts that haveAdministratoraccess. You can

    also enable this from the configuration wizard with option7.

    Windows Remote Shell

    RunWinRM quickconfigin order to enable remote command prompts.1.

  • 8/10/2019 116355 Configure Hyperv 00

    10/43

    From a machine on the same domain, runwinrs r:[serverName] [command]command.2.

    Remote PowerShell

    This is similar to the Remote Shell, but it gives you full PowerShell access, and allows you to connect to

    remote computers like Secure Shell (SSH).

    On the remote host, run theEnablePSRemoting Forcecommand.1.

    On the remote machine runEnterPSSession ComputerName [computer_name].2.

  • 8/10/2019 116355 Configure Hyperv 00

    11/43

    Install Additional RolesOnce the server is added to the MMC of the jumpserver, you can run theadd/remove roles and features

    wizard from the jumpserver, and add roles to the remote server like any other server. Do this now in order to

    install Multipath I/O (MPIO) if it is needed as well as the failover clustering features that are needed for

    HyperV clusters.

    Open the server configuration utility.1.

    Navigate toManage > Add Roles and Features.2.

    Choose yourHyperV server.3.

    InstallMPIO,if you use Fibre Channel (FC), andFailover Clustering.4.

    Repeat for the second host.5.

    Additional Configuration

    UseMPIOCPL in Orderto Launch the MPIO Wizard Once the Feature isInstalled

    In order to configure disks from the CLI, use these commands:

    Getdiskin order to list available disks

    Setdisk number X IsOffline $falsein order to bring the disk online

    InitializeDisk Xin order to initialize the disk

    NewPartition [Disk_Number] UseMaximumSize MBRType AssignDriveLetterin order to

    create the partition

    FormatVolume DriveLetter [DriveLetter]in order to format the drive

    Launch theClustering wizardfrom the jumpserver, and addyour two hoststo a cluster.

    Add the HyperV Host to SCVMM

    Now you have a basic Windows installation drivers are installed, IPs are configured, you are on the domain,

    and you can remotely manage the box. It is time to add the host to SCVMM, which is the equivalent ofvCenter. If you have a host that runs HyperV manager, you can point that to your host in order to manage it.

  • 8/10/2019 116355 Configure Hyperv 00

    12/43

  • 8/10/2019 116355 Configure Hyperv 00

    13/43

    You are now in SCVMM. Rightclick theAll Hostsfolder, and chooseCreate Host Group. Name

    this with a descriptive title.

    4.

  • 8/10/2019 116355 Configure Hyperv 00

    14/43

    Rightclick the newlycreated host group, and chooseAdd HyperV Hosts and Clusters.5.

    Click theWindows Server computers in a trusted Active Directory domainradio button.6.

  • 8/10/2019 116355 Configure Hyperv 00

    15/43

    Click theUse an existing Run As accountradio button. This is the account that the wizard uses in

    order to log in to the hosts you add.

    7.

    Enter theDNS namesof the servers you need to add.8.

  • 8/10/2019 116355 Configure Hyperv 00

    16/43

    On the next screen, choose thediscovered serversthat must be added. If you cannot see the servers on

    this screen, then go back and modify your search parameters.

    9.

    Modify thesettingsas needed. For example, you can change the default path.10.

  • 8/10/2019 116355 Configure Hyperv 00

    17/43

    Enablelive migrationsif desired. You can specifiy the network to use as well.11.

    Verify and accept the changes. Ensure that you fix any errors.12.

  • 8/10/2019 116355 Configure Hyperv 00

    18/43

    If you have trouble with your connection (for example, if it errorsout), complete these steps:

    Disable Windows firewall with the PowerShellnetsh advfirewall set allprofiles state offcommand.

    Make sure you use the correct credentials and that the host is on the domain.

    Review the Windows error logs because they are often helpful in this case.

    Nexus 1000v on HyperV

    The Nexus 1000v on HyperV is configured very differently than the Nexus 1000v on VMware by default.

    This is because the Nexus 1000v on HyperV relies heavily on the network segmentation features due to the

    networking architecture of HyperV. Here is a quick overview of the different terminologies and how they

    interact:

    Logical Network A logical network is a general bucket that contains a certain network. For

    example, DMZ would be a logical network and Production would be another.

    Segment Pool A collection of segments that belongs to a logical network. For example, they might

    be for different sites, such as one pool for RTP, and one pool for SJ.

    Segment This is where the access capabilities of a network are defined. This is where you assign

    VLANs.

    PortProfiles A collection of policies, not connectivity. Quality of Service (QoS), Access Control

    List (ACL) and others belong here.

    IP Pool This gets assigned to a segment. In most cases it does not matter. But, when doing

    orchestration, SCVMM can automatically assign addresses from this pool.

    Ethernet This is an uplink from the host. Each set of uplinks allows a certain segment pool.

    vEthernet This is the interface of a VM. It inherits a portprofile for its policies and a segment for

    its VLAN.

    VMnetwork This is the segment combined with the IP pool on the SCVMM side.

  • 8/10/2019 116355 Configure Hyperv 00

    19/43

    PortClassification This refers to the portprofile policies in SCVMM.

    Here is a diagram that explains the inheritance chain:

    Use the Installer Application in Order to Install the Virtual SupervisorModules (VSMs)

    Use this method for a fresh install the installer application only shows hosts that do not have a virtual

    switch. This installs the VSMs and provides some basic configuration. You should not use this to install

    because you understand the product better if you install it manually. However, it is included here for

    reference.

    Log in to the jumpserver with your domain credentials.1.

    Open a Windows Explorer window and navigate to[n1k bundle]\VSM\Installer_App.2.

    RightclickCisco.Nexus1000VInstaller.UI.exe, and chooseRun as administrator.3.

  • 8/10/2019 116355 Configure Hyperv 00

    20/43

    Review the requirements. ClickNext.4.

    Enter the SCVMM server details. Make sure you use an administrator account.5.

    On the next page, you are asked for the basic Nexus 1000v configuration. Fill this out based on your

    needs. The VSM ISO is in the VSM folder, and theVEM .msiis in the VEM folder. There is

    currently a bug, Cisco bug ID CSCuh36072, that prevents this wizard from seeing hosts with a virtual

    switch (vSwitch) already defined. The HyperV server comes with a vSwitch created already.

    Because of this bug, you need to delete the vSwitch. In order to delete it, rightclickhost, go to

    propertiesand thenvirtual switches.

    6.

  • 8/10/2019 116355 Configure Hyperv 00

    21/43

    Verify the settings, and clickNextin order to begin the installation. The installation takes about ten to

    twenty minutes.

    7.

  • 8/10/2019 116355 Configure Hyperv 00

    22/43

    After this wizard is complete, you are able to log into your VSM.Admin/Adminis the default install.

    Manually Install the Nexus 1000v

    This section describes how to manually install the Nexus 1000v Series Switch, which is useful in a couple of

    cases:

    Integration with a system that already exists. The manual installation method is far more granular and

    allows you to control exactly how it integrates.

    Deeper knowledge of the product. This method allows you to better understand how everything

    integrates, which makes it easier to troubleshoot and expand.

    Problems with the installer. If you encounter any issues with the installer, you can use the manualmethod.

    Install the VSMs Manually

    Use this method if you need to install VSMs into an environment that already exists. This method allows you

    to use the infrastructure that already exists instead of building your own.

    Part 1 SCVMM Setup

    This procedure only needs to be done once for each SCVMM server.

  • 8/10/2019 116355 Configure Hyperv 00

    23/43

    Install theprovider MSIon the SCVMM server.1.

    Import theVSM templates.

    On the SVCMM server, openPowerShell.

    Run theRegisterNexus1000vVsmTemplate.ps1script.

    Copy theVirtual Ethernet Module (VEM)to the SVCMM repository

    ALLUSERSPROFILE%\Switch Extension Drivers.

    Create alogical network(Fabric > Logical Networks) and associate it with a standard switch

    (rightclick the host,Properties,Virtual Switchesin order to create the switch, and

    Hardwarein order to assign the logical network to it). This allows you to put VMs on thisnetwork.

    2.

    Part 2 VSM Deployment

    Go toLibrary>Library Serversand upload theVSM .isoto the library server.1.

    RightclickInfra1, and chooseNew Virtual Machine.2.

    Choose theNexus1000vVSMTemplate.This was registered when the PowerShell script ran in part

    1.

    3.

    Name the VSM.4.

    Connect the Network Adapters to the network created in Part 1.5.

  • 8/10/2019 116355 Configure Hyperv 00

    24/43

    Mount theCDin the CD drive.6.

    Scroll down and enable High Availability (HA)under Availability (this is only needed if you install

    the VSMs to a failover cluster).

    7.

    Place theVSMon the Infrastructure hosts.8.

    Once the VM is deployed, launch theKVM, and run through the initial configuration wizard.9.

    Part 3 VSM Basic Configuration

    Create anIP poolfor your VLAN. These are the IPs that you assign to your VMs. They need to be

    defined, but they are only used if SCVMM provides automation.

    nsm ip pool template VLAN124

    ip address 14.17.124.80 14.17.124.250

    network 14.17.124.0 255.255.255.0

    defaultrouter 14.17.124.254

    1.

    Create alogical network. You only need one logical network unless you have something like a DMZ.

    nsm logical network chrisb2CALO

    2.

    Create anetwork segment pool. Make it a member of the logical network.

    nsm network segment pool chrisb2RTP memberof logical network chrisb2CALO

    3.

    Create multiplesegments, one for each access VLAN.

    nsm network segment chrisb2124

    memberof network segment pool chrisb2RTP

    switchport access vlan 124

    ip pool import template ip_pool_124

    publish network segment

    switchport mode access

    4.

    Create aportprofilefor the VMs. There is no need to access a VLAN here. Remember that the

    portprofile is simply a collection of policies.

    portprofile type vethernet defaultAccess

    5.

  • 8/10/2019 116355 Configure Hyperv 00

    25/43

    no shutdown

    state enabled

    publish portprofile

    Create aNetwork Segmentation Manager (NSM) uplink. Theallow network segment poolcommand

    tells SVCMM that these segments are allowed out this uplink. This is needed for the host in order to

    see your segments.

    nsm network uplink UPLINK

    switchport mode trunk

    publish network uplink allow network segment pool chrisb2RTP

    6.

    Modify the createdportprofilewith any needed policies, such as portchannels.

    portprofile type Ethernet UPLINK

    channelgroup auto mode on macpinning

    7.

    Part 4 SVCMM Basic Configuration

    Navigate toFabric, and expandNetworking. RightclickSwitch Extension Manager, and click on

    Add Virtual Switch Extension Manager.

    1.

    Enter theConnection settings. The Connection String address is http://your_VSM_IP_address.2.

    ClickBrowse, and create aRun As accountwith credentials to log in to your Nexus 1000v.3.

  • 8/10/2019 116355 Configure Hyperv 00

    26/43

    ClickNext.4.

    In the Host Groups panel, select all thehost groupsthat can use the virtual switch extension manager,

    and clickNext.

    5.

  • 8/10/2019 116355 Configure Hyperv 00

    27/43

    In the Summary panel, confirm the settings, and clickFinish. The switch extension should be created

    now.

    6.

    Part 5 Create the Logical Switch

    In the SCVMM user interface, clickFabric, thenLogical Switchesunder Networking in the

    leftnavigation panel. RightclickLogical SwitchesandCreate Logical Switch.

    1.

  • 8/10/2019 116355 Configure Hyperv 00

    28/43

    ClickNexton the Getting Started page. Review the instructions, and clickNext.2.

    Enter anameand adescriptionfor the logical switch.3.

  • 8/10/2019 116355 Configure Hyperv 00

    29/43

    In the Extensions panel, the virtual switch extensions are listed. Select theVSM extensionyou

    created, and clickNext.

    Note: Only one forwarding extension can be selected.

    4.

  • 8/10/2019 116355 Configure Hyperv 00

    30/43

    In the Uplink panel, specify theuplink portprofilesthat are part of this logical switch. The uplink

    portprofiles are available for use on the hosts where an instance of the logical switch is created. Set

    the Uplink mode toTeam.

    Note: Whether you use a single uplink or multiple uplinks, the mode should always beTeam.

    5.

    In the Uplink portprofiles field, clickAdd. The Add Uplink Port Profile window opens.6.

  • 8/10/2019 116355 Configure Hyperv 00

    31/43

  • 8/10/2019 116355 Configure Hyperv 00

    32/43

    ClickNext. On the next screen, chooseAddin order to start the classification wizard.7.

  • 8/10/2019 116355 Configure Hyperv 00

    33/43

    Choose yourVSMand theportprofileyou created. Clickbrowsein order to create a port

    classification. (A port classification is a collection of policies to apply to an interface remember thatthis is what the portprofiles define!)

    8.

  • 8/10/2019 116355 Configure Hyperv 00

    34/43

  • 8/10/2019 116355 Configure Hyperv 00

    35/43

    Specify anameand adescriptionfor the port classification.9.

  • 8/10/2019 116355 Configure Hyperv 00

    36/43

  • 8/10/2019 116355 Configure Hyperv 00

    37/43

    Choose theport profile classificationyou just created, and clickOK.10.

  • 8/10/2019 116355 Configure Hyperv 00

    38/43

  • 8/10/2019 116355 Configure Hyperv 00

    39/43

    ClickOKin order to finish adding the Virtual Port. ClickNextin order to close the Create Logical

    Switch Wizard window.

    11.

  • 8/10/2019 116355 Configure Hyperv 00

    40/43

    Part 6 Create VMNetworks Based on the Segments

    Go toVMs and Services, rightclickVM Networks, and chooseCreate VM Network.1.

    Give it a descriptivename, select yourlogical network, and clickNext.2.

  • 8/10/2019 116355 Configure Hyperv 00

    41/43

    For Isolation, chooseExternally supplied VM network, and chooseyour network segment.3.

    Finish the wizard. Now you are able to deploy VMs on this VLAN.4.

    Add Host to DVS

    When you add the host to the Logical Switch, the VEM is automatically installed.

    Go toFabric > All Hosts.1.

    Rightclick thesecond host, and chooseProperties.2.ClickVirtual Switches.3.

    ChooseNew Virtual Switch > New Logical Switch.4.

    Attach aNICto the Nexus 1000v Logical Switch.5.

  • 8/10/2019 116355 Configure Hyperv 00

    42/43

    Verify that the modules appear undershow moduleon the VSM.6.

  • 8/10/2019 116355 Configure Hyperv 00

    43/43

    Attach aVMto your created classification and segment, and then verify connectivity.7.

    Manually Install the VEM

    If SCVMM did not install the VEM, you can use this command in order to install the VEM:

    msiexec.exe /i [Path_to_N1k_bundle]\VEM\Nexus1000vVEM5.2.1.SM1.5.1.0.msi

    Verify

    There is currently no verification procedure available for this configuration.

    Troubleshoot

    There is currently no specific troubleshooting information available for this configuration.

    Updated: Sep 04, 2013 Document ID: 116355