Got it

Improving CIFS Access Performance by Changing the CIFS Block Transfer Size

118 0 0 0 0

Hi team!

Here's a case that Improving CIFS Access Performance by Changing the CIFS Block Transfer Size.


Problem Description

A customer's network is of poor quality and the network latency is long. 

When a client accesses a storage system through CIFS, the access performance is low.



Symptom

At a site in India, when an upper-layer application on a client accesses a CIFS shared folder on an OceanStor 5300 V3 storage system, frozen frames are found in videos. 

From the CIFS status statistics collected on the storage system, it is found that the internal latency of the storage system is normal. 

However, by using the client to ping the IP address of the storage system, it is found that the latency is long.



Possible Cause

The network quality is poor and the network latency is long. 

Therefore, it takes a longer time to transfer packets over the network. 

However, the upper-layer application on the client requires short latency. So, services are affected.



Identification Method

● Method of viewing latency in the CIFS status statistics collected on the storage system

1. Enter the developer mode.

    admin:/> change user_mode current_mode user_mode=developer

2. Run the protocol status statistics command and view the internal latency of the storage system.

    In application scenarios that have high service requirements, the internal latency is typically 10 ms or shorter.

developer:/>show cifs smb2_state controller=0X (0X indicates a controller ID. Possible values are 0A, 0B, 0C, and 0D.) 

The average latency of SMB2_READ is 4975 μs and that of SMB2_WRITE is 1500 μs.

1

● Method of using a client to ping the IP address of the storage system and view the latency

1. In the cmd window  of the client, run net use and view the network IP address of the share mounted to the client.

    In the following figure, the network IP address is 129.151.23.189.

    2

● Compare the network IP address with the logical IP address of the storage system.

● In the following figure, the logical IP address is 129.151.23.189.

    3

● Then, it is confirmed that the client uses 129.151.23.189 to connect to the storage system.


2. On the client, ping the service IP address of the storage system and view the latency.

4

 ● By comparing the latency in pinging the storage system (20 ms) with the internal latency of the storage system (4 ms), 

    it can be inferred that the network is the major factor that causes low performance.


Solution

Increase the CIFS block transfer size on the storage system and client, 

thereby reducing the number of packets transferred over the network.

● One the storage system, run the following command:

    developer:/> change service cifs_config max_block_size=1048576

    4


● On a client that runs Windows Sever 2008 R2 or later, change the block transfer size as follows:

1. Pressing the Windows key + R to open the Run dialog box.

2. Enter regedit to open the registry.

3. Change the block transfer size.

    Go to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Lanmanworkstation\Parameters, 

    create a DWORD item, name it SizReqBuf, and set the value to 1048576 (namely, 1 MB).

4. Enable the support for jumbo frames.

    Go to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Lanmanworkstation\Parameters, 

    create a DWORD item, name it DisableLargeMtu, and set the value to 0.

5. Change the maximum TCP window size.

    Go to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters, 

    create a DWORD item, name it GlobalMaxTcpWindowSize, and set the value to hexadecimal 1000000.

6. Change the TCP window size.

    Go to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters, 

    create a DWORD item, name it TcpWindowSize, and set the value to hexadecimal 1000000.

Comment

You need to log in to comment to the post Login | Register

Notice: To protect the legitimate rights and interests of you, the community, and third parties, do not release content that may bring legal risks to all parties, including but are not limited to the following:
  • Politically sensitive content
  • Content concerning pornography, gambling, and drug abuse
  • Content that may disclose or infringe upon others ' commercial secrets, intellectual properties, including trade marks, copyrights, and patents, and personal privacy
Do not share your account and password with others. All operations performed using your account will be regarded as your own actions and all consequences arising therefrom will be borne by you. For details, see " User Agreement."

My Followers

Login and enjoy all the member benefits

Login

Block
Are you sure to block this user?
Users on your blacklist cannot comment on your post,cannot mention you, cannot send you private messages.
Reminder
Please bind your phone number to obtain invitation bonus.