0

It seems Bridgeutil_1.0 is a great tool, simple and easy, but my problem is the there are two network adapters with same hardware ID and I happened to have to attach them together, how could I do it?

I used command like:

bridgeutil /attach "PCI\VEN_8086&DEV_10D3&SUBSYS_00008086&REV_00" /attach "PCI\VEN_8086&DEV_10D3&SUBSYS_00008086&REV_00"

but it still only attach one network.

Programmatically create/destroy network bridges with .NET on Windows 7

Community
  • 1
  • 1
sking
  • 1
  • 1
  • @bkausbk Thanks for the nice tool Bridgeutil! could you help? – sking Dec 31 '14 at 02:32
  • How can they have the same hardware ID? – user2864740 Dec 31 '14 at 02:34
  • I don't know exactly. I'm not with CS background. I can figure out more, in general, i think they are the HW with same model on the different PCI bus. I think hardware ID is not unique to each piece of hardware device, right? – sking Dec 31 '14 at 02:42
  • This "hardware ID" is not the Ethernet ID (aka MAC address). It's used for driver selection. – Ben Voigt Dec 31 '14 at 03:31
  • Show your C# code? You've linked to a programming question, but your question right now has nothing to do with programming except a C# tag. You're going to have to explain how C# is related, or it will be closed. – Ben Voigt Dec 31 '14 at 03:35
  • I'm sorry. The code will be same to what's in the link. My question is how to handle the identical hardware-id issue. I have removed the C# tag. – sking Dec 31 '14 at 05:47
  • Hello, yes I already found out that index don't always will work, I'll will fix this issue soon. I had not thought of, in fact, that there can be devices with the same ID. I like the idea using the hardware id, but this is not enough. May be I could combine the index with the hardware id so that bridgeutil /attach "PCI\VEN_1..." 1 /attach "PCI\VEN\1..." 2 could indicate first and second device with this hardware id? Any ideas? – bkausbk Dec 31 '14 at 22:29
  • Please take a look at my new version on sourceforce. Now it is possible to either addiotionally specify network MAC address or interface alias name. – bkausbk Jan 02 '15 at 19:28
  • Yes, it works perfectly now. bridgeutil /attach "PCI\VEN_8086&DEV_10D3&SUBSYS_00008086&REV_00" Front_LAN /attach "PCI\VEN_8086&DEV_10D3&SUBSYS_00008086&REV_00" Internal_NIC – sking Jan 04 '15 at 06:10
  • BTW, msvcr120.dll is required for the new version now. I downloaded it from internet. – sking Jan 04 '15 at 06:14

1 Answers1

0

I find some clue.

run msinfo32, you can get the "PNP Device ID" and index, which will be different for the same model of adapters.

It seems index don't work with Bridgeutil. This PNP Device ID will work with the Bridgeutil.

Now the issue became to "How to programmatically get the PNP Device ID?"

For the problem i met, it seems every unit have the same PNP Device ID, as every unit was installed with the same windows7 image. I can directly use the two PNP Device ID i found out.

My problem solved.

Bridgeutil also updated to better support this case:

/attach [] Index or hardware id of the adapter to attach to bridge. /detach [] Index or hardware id of the adapter to detach from bridge.

The optional parameter either specifies a network adapter MAC address or an interface alias name.

For example:

bridgeutil /attach "PCI\VEN_8086&DEV_10D3&SUBSYS_00008086&REV_00" Front_LAN /attach "PCI\VEN_8086&DEV_10D3&SUBSYS_00008086&REV_00" Internal_NIC

sking
  • 1
  • 1