En esta publicación de blog, le mostraré cómo habilitar permanentemente la compresión SMB en Windows 10 y Windows Server 2019. La compresión SMB es una característica que le permite comprimir datos antes de enviarlos a través de la red, lo que reduce el uso de ancho de banda y mejora el rendimiento.
SMB compression is especially useful for transferring large files or folders that contain a large amount of redundant or compressible data.
SMB compression is available since Windows 10 version 2004 and Windows Server version 2004, and can be enabled on a per-share or per-file basis using PowerShell cmdlets or the File Explorer user interface. However, if you want to enable SMB compression for all SMB transfers by default, you must modify registry settings on both the client and server sides.
To enable SMB compression permanently on the client side, follow these steps:
Open the Registry Editor by typing regedit in the Run dialog box or in the Start menu.
2. Navigate to the following key: HKEY_LOCAL_MACHINE_LOCAL_MACHINE_SYSTEM_CurrentControlSetSetServices_LanmanWorkstation_Parameters
3. Right-click on the Parameters key and select New > DWORD Value (32 bits).
4. Assign the new value the name EnableCompression and set its data to 1.
5. Close the Registry Editor and restart your computer.
To enable SMB compression permanently on the server side, follow these steps:
Open the Registry Editor by typing regedit in the Run dialog box or in the Start menu.
2. Navigate to the following key: HKEY_LOCAL_MACHINE_SYSTEM_CurrentControlSetSetServices_LanmanServer_Parameters
3. Right-click on the Parameters key and select New > DWORD Value (32 bits).
4. Assign the new value the name CompressionEnabled and set its data to 1.
5. Close the Registry Editor and restart your computer.
After enabling SMB compression permanently on both sides, you should see a significant improvement in file transfer speed and network efficiency. You can also use the Get-SmbCompression cmdlet to check the compression status of any SMB file or share.
Note that SMB compression does not support SMB encryption, SMB signing or SMB multi-channel. If you enable any of these features, SMB compression will be automatically disabled. You can also disable SMB compression manually by setting the registry values to 0 or by using the Disable-SmbCompression cmdlet.
I hope this blog post has been helpful to you. If you have any questions or comments, please leave a comment below.
If you want to speed up the transfer of files over a network, you can use SMB compression.
This is a feature that compresses data before sending it over the network, reducing bandwidth usage and improving performance.
However, SMB compression is not enabled by default.
You must enable it manually, either for each connection or for all connections.
Here’s how you can do it.
First, you need to configure the SMB server. This is the computer that hosts the shared folder. To enable SMB compression on the server, you need to edit the Windows registry. You can do this by typing regedit in the search box on the taskbar and clicking Registry Editor. Then navigate to the following key: HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\LanmanServer\Parameters. In the right pane, right-click and select New -‘ DWORD Value (32-bit). Name the new value EnableCompressedTraffic and double-click on it to open it. Set its value to 1 and click OK. Then restart the computer for the changes to take effect.
Next, you must configure the SMB clients. These are the computers that access the shared folder. To enable SMB compression on the clients, you must also edit the Windows registry. You can do this by following the same steps above, but navigating to this key:
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\LanmanWorkstation\Parameters. Create a new DWORD value (32-bit) called EnableCompressedTraffic and set its value to 1. Then restart the computer for the changes to take effect.
Alternatively, you can enable SMB compression for a specific connection without editing the registry. You can do this by using the NET USE command with the /REQUESTCOMPRESSION:YES parameter. For example, if you want to connect to a shared folder named Release on a server named Server, you can type this command: NET USE * /REQUESTCOMPRESSION:YES. This will create a compressed connection to the shared folder.
SMB compression can help you save bandwidth and speed up the transfer of files across a network. However, it can also increase CPU usage on both the server and the client, so you should test it before using it in production environments.