1

I have a use case to find all physical (no virtual or vlan interfaces) on FreeBSD.

How can I get a count of the number of physical interfaces on a box consistently regardless of any virtual interface or vlan config?

1 Answer 1

1

It seems that you're looking for something along this line:

pciconf -lv | grep network | wc -l

Also, you may get a list of the interfaces like this:

pciconf -lv | grep ethernet -B4 | grep class= | cut -d@ -f1

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.