Microsoft Virtualization Discussions

get-nanetinterface always shows the interface enabled, even when it's disabled

dlmaldonado
2,889 Views

Anyone else having this issue?

I've tested on different filers, same results. get-nanetinterface shows every interface enabled. I can't get it to display the disabled interfaces as disabled.

1 ACCEPTED SOLUTION

timothyn
2,889 Views

Are you trying to determine which interfaces are connected/active?  That's subtly different from "enabled".  Unfortunately the API doesn't make that abundantly clear, but you can look at the mediatype property which will end with "up" or "down" depending on its connection state:

PS C:\> get-nanetinterface | ft Interface, Enabled, Mediatype -AutoSize

Interface Enabled Mediatype

--------- ------- ---------

e0a          True auto-1000t-fd-up

e0b         False auto-1000t-fd-up

e0c         False auto-unknown-down

e0d         False auto-unknown-down

e0P          True auto-unknown-down

lo           True VIA Provider

losk         True

vh          False

View solution in original post

2 REPLIES 2

timothyn
2,890 Views

Are you trying to determine which interfaces are connected/active?  That's subtly different from "enabled".  Unfortunately the API doesn't make that abundantly clear, but you can look at the mediatype property which will end with "up" or "down" depending on its connection state:

PS C:\> get-nanetinterface | ft Interface, Enabled, Mediatype -AutoSize

Interface Enabled Mediatype

--------- ------- ---------

e0a          True auto-1000t-fd-up

e0b         False auto-1000t-fd-up

e0c         False auto-unknown-down

e0d         False auto-unknown-down

e0P          True auto-unknown-down

lo           True VIA Provider

losk         True

vh          False

dlmaldonado
2,889 Views

Yes. That's what I was trying to get at. In filerview or oncommand it's either enabled or disabled. That was confusing me. Thank you.

Public