Redirecting SMB traffic to secondary NIC

Hi there!

After searching for several hours on the Internet about this topic and banging my head against the wall with unsuccessful results, I have to ask this here:

My current setup consists on 2 PCs, one laptop, the other a tower. Each one receives Internet via a CAT 6 cable from a TP-Link unmanaged switch, which connects trough a MoCA to the ISP ONT/Router. All these operate at gigabit ethernet speeds (on-board NICS, switch and MoCAs). Recently, I have upgraded the tower and the laptop with a 2.5 GbE adapter (both ASUS with Realtek chips) and set them up via direct connection on their own static IP network. As of right now, a 2.5 GbE switch is not a viable option due to not being affordable for me.

The network diagram is something like this:

The question is: how do I configure the 2.5GbE adapters to
a) transfer the files first though the direct connection, and
b) if the direct connection is not available, through the switch?

I have tried modifying the priorities of the network adapters and accessing directly though the “secondary” IP address, but Windows still refuses to transfer as I wish. Any thoughts on this?

Thanks for your attention

1 Like

Change adapter priority

1 Like

Like @rockking suggested:


Windows being Windows, I guess?
Depending on the Windows version, you may be able to set up “NIC-Teaming”, that way it uses both NICs when possible.

Weird, isn’t there this smb multi-homing thing that’d let the OP transfer at 3.5Gbps?

What windows version(s) are you on?

Apparently, even after changing priorities, Windows still refuses to use the secondary NIC. The screenshot below is the tower 2.5GbE Ipv4 settings, which are the same in the laptop except for the IP address and the default gateway, which are reversed.

Btw, I have tried teaming both NICs but it didn’t end well (W10 v. 22H2). Even after setting a static IP with the virtual teamed NIC, I could not get Internet access no matter what I did, so I reverted to the previous situation.

1 Like

This will not set you up to use the 2.5gb network first by default, but it will set up the share to use both networks links and allow you to use bandwidth from both at once if you want to try it. This will most likely be limited to 2gbit as it will only send 1gb down both links (since you are limited by the 1gb connection on one side):

  1. Go to your driver settings and make sure Receive Side Scaling is turned on for both NICs.

  2. Run powershell as admin.

  3. type “Get-SmbServerConfiguration | Out-String -Stream | Select-String “EnableMultiChannel””

  4. If it reports the value as false, type “Set-SmbServerConfiguration -EnableMultiChannel $True”

  5. Check your network interfaces for some values you need with “Get-SmbServerNetworkInterface”
    Make note of the interface indexes listed

  6. Now set up multi-channel and your hostname with this next command. For the interface part, put the numbers in that you found from the last command “New-SmbMultichannelConstraint -ServerName “hostname here” -InterfaceIndex #, # -Force”

  7. Check your settings with the command “Get-SmbMultichannelConstraint”
    This should list two interfaces now, probably Eth0 and Eth1, and both should have the same server name.

Transfer a file and see if the transfer speed is higher.

edit:
I see this disclaimer on Microsoft’s website, so it sounds like it wont use both NICs this way but will choose the 2.5gb NIC on its own (which is what you wanted the behavior to be anyway so problem solved):

If you want to set it up to only use the 2.5gb link then you could set up both NICs similar to how you did but without a default gateway. Set the default gateway on your main NIC for all your other traffic instead. Then when setting up the share and mapping the drive you would set the IP of the 2nd NIC for the share mount. This will cause the traffic for that to always go over that 2.5gb NIC only and no other traffic will.

Note that with this method if the NIC ever becomes unavailable the share will also not work, because it is mounted only over that NIC and its direct IP address. I know this isnt what you asked for, but it is one method of doing something similar to what you want and using the high bandwidth NIC only for the share traffic and nothing else.

So PC1 with NIC1 is set to 10.0.0.1
PC2 with NIC2 is set to 10.0.0.2
Subnet 255.255.255.0 for both
No default gateway for both.

Click “Map Network Drive”
the Folder setting would be “\10.0.0.1\ShareName”
Note that there are actually two \ at the beginning before the IP, but this forum keeps not displaying the second backslash.

I suspect the problem you are having with the NIC priority metric not doing what you want is related to this type of setup here. If you map a network drive with this method it will always use that IP, so it won’t choose one NIC or the other depending on the priority you set, it only knows how to go to the IP you set.

Not quite what you want, i.e. without the magic of auto-switching.

Set the two interfaces normally on both machines adequately,

Machine 1, Eth1, 192.168.0.2 for 1Gb with gateway and dns (Set your correct dns and gateway or use dhcp).
Machine 1, Eth2, 10.0.0.1 for 2.5Gb without gateway and dns.

Machine 2, Eth1, 192.168.0.3 for 1Gb with gateway and dns (Set your correct dns and gateway or use dhcp).
Machine 2, Eth2, 10.0.0.2 for 2.5Gb without gateway and dns.

You can adjust the addresses as you wish.

Don’t use names when finding smb server, use IP \\10.x.x.x

In such a network model and two machines, I personally see no point in having a backup path for traffic.

Well, it seems that setting a even higher priority difference between the two adapters (1 for the 2.5 GbE and 1000 for the on-board NIC), entering the dark and forbidden woods of regEdit to clear the network location history and forcing SMB multichannel on both systems managed to solve it, somehow (?)

This demonstrates how I love and loathe Windows at the same time.

At least I can survive transferring big files (100+ GB video files) between the two computers until I can afford a 2.5 GbE switch.

Thanks for everything guys