Optimize File Transfers with SMB Compression in Windows 11

This article guides on how to use the SMB compression feature in Windows 11 for mapping a network drive, reducing data transferred over networks. The feature is automatically enabled, but can be manually activated. Alongside existing shared network locations, new ones can be created with SMB compression built-in using various command formats.

This article explains how to use the SMB compression feature when mapping a network drive in Windows 11.

Windows has a feature called SMB compression, which can reduce the amount of data that needs to be transferred over the network by compressing it. This can be particularly useful if you frequently transfer large files or work with remote servers.

The SMB Compression feature is enabled by default. Howerver, if it is disabled and you want to re-enable it, you can use the steps below.

Press the Windows key + R to open the Run dialog box. Then Type “optionalfeatures” (without quotes) and press Enter.

Scroll down to find “SMB 1.0/CIFS File Sharing Support” and expand it. Then Check the box next to “SMB 1.0/CIFS Client” and “SMB 1.0/CIFS Server“.

Click OK to save changes.

Use SMB compression when mapping network drives

As mentioned above, the SMB compression feature in Windows can reduce the amount of data that needs to be transferred over the network by compressing them.

Here’s how to use it to map network drives and copy files faster.

Use the command format below to map a network drive with SMB compression.

net use * \\FILESERVER\SharedFolder /requestcompression:yes

For example, you will run the command below to map a network share on a HomePC computer with a shared Documents folder.

The star ( * )in the command will automatically assign a letter for the network drive.

net use * \\HomePC\Documents /requestcompression:yes

With the PowerShell app, use the command format below.

New-SmbMapping -LocalPath "Z:" -RemotePath "\\HomePC\Documents" -CompressNetworkTraffic $true

With Robocopy, use the command format below.

robocopy C:\HomePC\Documents \\DestinationPC\Path\To\Documents /compress

The steps above assume that there are already shared network locations and you want to map them.

Howerver, Windows also allows users to create new network shares with SMB compression built-in, so the compression feature is ready to use.

Run the commands below to create a new network share using the PowerShell app with the SMB compression feature.

The example below creates a new shared Documents folder in the user’s home directory of the user “GeekRewind” with SMB compression enabled.

New-SmbShare -Name "Documents" -Path "C:\Users\GeekRewind\Documents" -CompressData $true

For an existing shared folder without SMB compression, you can use the command to modify it to include the SMB compression feature.

Set-SmbShare -Name "Documents" -CompressData $true

That should do it!

Conclusion:

  • Windows 11’s SMB compression feature can significantly reduce data transfer over the network by compressing files.
  • SMB compression can enhance file transfer speed, especially for large files and remote server interactions.
  • Users can easily enable SMB compression to map network drives and copy files faster with straightforward commands.
  • Additionally, Windows 11 allows the creation of new network shares with built-in SMB compression, simplifying the process.
  • This article provides comprehensive instructions for leveraging SMB compression to optimize data transfer in Windows 11, empowering users to maximize network efficiency.

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *