none
SPF returns different results for VirtualNetworkAdapter in REST Client compared to what is available in Powershell RRS feed

  • Question

  • While retrieving VirtualNetworkadapter, the VLAN details in Powershell is coming with the right value but the VLAN values in RESTclient is coming with 0. (For the same setup and same authentication)

    We have the following setup,

    OS - Windows Server 2012 R2 Datacenter
    VMM - System Center 2012 R2,
    SPF - SPF 2012 R2
    SQL Server SQL Server 2012 SP1
    Hyper-V - 6.3.9600
    PowerShell

    Executing the following command in Powershell

    Get-SCVirtualNetworkAdapter -vm UbuntuOS

    SlotId                                     : 0
    VirtualNetwork                             : Tenant-Logical-Switch
    VMwarePortGroup                            :
    MACAddressType                             : Dynamic
    EthernetAddressType                        : Dynamic
    PhysicalAddressType                        : Dynamic
    MACAddress                                 :
    EthernetAddress                            :
    PhysicalAddress                            :
    RequiredBandwidth                          : 0
    VirtualNetworkAdapterType                  : Synthetic
    VmwAdapterIndex                            :
    LogicalNetwork                             : Tenant-Logical-network
    VMNetwork                                  : Tenant-VM-network
    VMNetworkServiceSetting                    :
    VMSubnet                                   : Tenant-VM-network_0
    PortClassification                         :
    VirtualNetworkAdapterPortProfileSet        :
    LogicalSwitch                                          :
    GuestIPNetworkVirtualizationUpdatesEnabled : False
    MACAddressSpoofingEnabled                  : False
    MACAddressesSpoofingEnabled                : False
    VMNetworkOptimizationEnabled               : False
    VLanEnabled                                         : True
    VLanID                                                  : 25

    VLANEnabled and VLAN are showing True and 25 respectively.

    For the same setup, when we get the data from RESTClient

    https://vmm2012:8090/SC2012R2/VMM/Microsoft.Management.Odata.svc/$metadata#VirtualNetworkAdapters

    "ID": "8bfd2e1f-3313-4a14-b823-25b3b447500a",
          "Name": "UbuntuOS",
          "VMwarePortGroup": null,
          "EthernetAddressType": "Dynamic",
          "PhysicalAddressType": "Dynamic",
          "EthernetAddress": null,
          "PhysicalAddress": null,
          "VirtualNetworkAdapterType": "Synthetic",
          "Location": null,
          "Tag": null,
          "Description": "",
          "VMNetworkId": "c143d512-c00d-4c11-8e03-198891de3bd2",
          "VMNetworkName": "Tenant-VM-network",
          "VMSubnetId": "02ad8d0f-b11a-4853-839a-7dadb9c07174",
          "TemplateId": null,
          "VMId": null,
          "StampId": "8974d176-318e-436c-83f7-4284aa3c7a1f",
          "MACAddressesSpoofingEnabled": false,
          "SlotId": 0,
          "VLanEnabled": false,
          "VLanId": 0,

    Not sure why we are getting VLAN id 0 in RESTClient. Any help in resolving this is highly appreciated.

    Thanks,
    Saba
    Monday, July 20, 2015 11:35 PM

All replies

  • While retrieving VirtualNetworkadapter, the VLAN details in Powershell is coming with the right value but the VLAN values in RESTclient is coming with 0. (For the same setup and same authentication)

    We have the following setup,

    OS - Windows Server 2012 R2 Datacenter

    VMM - System Center 2012 R2,
    SPF - SPF 2012 R2
    SQL Server SQL Server 2012 SP1
    Hyper-V - 6.3.9600
    PowerShell

    Executing the following command in Powershell

    Get-SCVirtualNetworkAdapter -vm UbuntuOS

    SlotId                                     : 0
    VirtualNetwork                             : Tenant-Logical-Switch
    VMwarePortGroup                            :
    MACAddressType                             : Dynamic
    EthernetAddressType                        : Dynamic
    PhysicalAddressType                        : Dynamic
    MACAddress                                 :
    EthernetAddress                            :
    PhysicalAddress                            :
    RequiredBandwidth                          : 0
    VirtualNetworkAdapterType                  : Synthetic
    VmwAdapterIndex                            :
    LogicalNetwork                             : Tenant-Logical-network
    VMNetwork                                  : Tenant-VM-network
    VMNetworkServiceSetting                    :
    VMSubnet                                   : Tenant-VM-network_0
    PortClassification                         :
    VirtualNetworkAdapterPortProfileSet        :
    LogicalSwitch                              :
    GuestIPNetworkVirtualizationUpdatesEnabled : False
    MACAddressSpoofingEnabled                  : False
    MACAddressesSpoofingEnabled                : False
    VMNetworkOptimizationEnabled               : False
    VLanEnabled                                : True
    VLanID                                     : 25

    VLANEnabled and VLAN are showing True and 25 respectively.

    For the same setup, when we get the data from RESTClient

    https://vmm2012:8090/SC2012R2/VMM/Microsoft.Management.Odata.svc/$metadata#VirtualNetworkAdapters

    "ID": "8bfd2e1f-3313-4a14-b823-25b3b447500a",
          "Name": "UbuntuOS",
          "VMwarePortGroup": null,
          "EthernetAddressType": "Dynamic",
          "PhysicalAddressType": "Dynamic",
          "EthernetAddress": null,
          "PhysicalAddress": null,
          "VirtualNetworkAdapterType": "Synthetic",
          "Location": null,
          "Tag": null,
          "Description": "",
          "VMNetworkId": "c143d512-c00d-4c11-8e03-198891de3bd2",
          "VMNetworkName": "Tenant-VM-network",
          "VMSubnetId": "02ad8d0f-b11a-4853-839a-7dadb9c07174",
          "TemplateId": null,
          "VMId": null,
          "StampId": "8974d176-318e-436c-83f7-4284aa3c7a1f",
          "MACAddressesSpoofingEnabled": false,
          "SlotId": 0,
          "VLanEnabled": false,
          "VLanId": 0,

    Not sure why we are getting VLAN id 0 in RESTClient. Any help in resolving this is highly appreciated.

    Thanks,

    Saba.

    Monday, July 20, 2015 6:49 AM
  • Hi,

    I believe the problem is more related to VMM or App controller. Orchestrator return the value via rest service, so you may have problems with the source.

    And I think the value returned from powershell is correct.


    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com.

    Wednesday, July 22, 2015 1:59 AM
    Moderator
  • Yes. Powershell returns the correct data. SPF interacts with VMM through Powershell so ideally, the SPF should return the same values what is returned in Powershell. I have tried applying the SPF patch Roll up 6 but still I am getting the same issue.   
    Wednesday, July 22, 2015 7:14 AM