配置Hyper-V网卡为混杂( Promiscuous)模式

1.Add a VMSwitch Port Feature, where "LAN2" is your virtual switch name.
$A=Get-VMSystemSwitchExtensionPortFeature -FeatureName "Ethernet Switch Port Security Settings"
$A.SettingData.MonitorMode = 2
Add-VMSwitchExtensionPortFeature -ExternalPort -SwitchName LAN2 -VMSwitchExtensionFeature $A

2.Change the PortMirroring Attribute of the VM Networkdevice, where "VMName 06_WinXPMonitor" is your VM name and "00155D016612" is the MAC address of your adapter
Get-VMNetworkAdapter -VMName 06_WinXPMonitor | ? MacAddress -eq '00155D016612' | Set-VMNetworkAdapter -PortMirroring Destination

原文地址:https://www.cnblogs.com/dreamer-fish/p/15311248.html