[go: up one dir, main page]

CN109032897A - Data scheduling method, host and solid state disk - Google Patents

Data scheduling method, host and solid state disk Download PDF

Info

Publication number
CN109032897A
CN109032897A CN201810867470.6A CN201810867470A CN109032897A CN 109032897 A CN109032897 A CN 109032897A CN 201810867470 A CN201810867470 A CN 201810867470A CN 109032897 A CN109032897 A CN 109032897A
Authority
CN
China
Prior art keywords
custom
debugging
host
ssd
interface
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201810867470.6A
Other languages
Chinese (zh)
Inventor
毕延帅
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
IEIT Systems Co Ltd
Original Assignee
Inspur Electronic Information Industry Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Inspur Electronic Information Industry Co Ltd filed Critical Inspur Electronic Information Industry Co Ltd
Priority to CN201810867470.6A priority Critical patent/CN109032897A/en
Publication of CN109032897A publication Critical patent/CN109032897A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3051Monitoring arrangements for monitoring the configuration of the computing system or of the computing system component, e.g. monitoring the presence of processing resources, peripherals, I/O links, software programs
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/0703Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
    • G06F11/079Root cause analysis, i.e. error or fault diagnosis

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computing Systems (AREA)
  • Health & Medical Sciences (AREA)
  • Biomedical Technology (AREA)
  • Debugging And Monitoring (AREA)

Abstract

本申请实施例公开了数据调度方法、主机以及固态硬盘,用于通过在自定义区域设置的自定义调试接口在线导出调试信息,提升了调试故障信息的准确性。本申请实施例方法包括:主机通过自定义调试接口向固态硬盘SSD发送调试命令以及所述自定义调试接口对应的自定义调试接口地址,所述自定义调试接口由所述SSD设置于总线和接口标准PCIe设备,所述自定义调试接口对应所述PCIe设备中自定义区域的目标配置空间,所述目标配置空间用于存储调试数据;所述主机通过所述自定义调试接口向所述SSD发送导出命令;所述主机通过所述自定义调试接口接收所述SSD内部的调试信息。

The embodiment of the present application discloses a data scheduling method, a host computer and a solid-state hard disk, which are used to export debugging information online through a custom debugging interface set in a custom area, thereby improving the accuracy of debugging fault information. The method in the embodiment of the present application includes: the host sends a debugging command to the SSD SSD through a custom debugging interface and a custom debugging interface address corresponding to the custom debugging interface, and the custom debugging interface is set on the bus and the interface by the SSD A standard PCIe device, the self-defined debugging interface corresponds to the target configuration space of the self-defined area in the PCIe device, and the target configuration space is used to store debugging data; the host sends the SSD to the SSD through the self-defined debugging interface An export command; the host receives the internal debugging information of the SSD through the custom debugging interface.

Description

数据调度方法、主机以及固态硬盘Data Scheduling Method, Host, and Solid State Disk

技术领域technical field

本申请涉及计算机技术领域,特别涉及一种数据调度方法、主机以及固态硬盘。The present application relates to the technical field of computers, in particular to a data scheduling method, a host computer and a solid-state hard disk.

背景技术Background technique

随着互联网、云计算、物联网等技术的发展,固态硬盘作为新一代的存储设备,得到广泛应用。With the development of technologies such as the Internet, cloud computing, and the Internet of Things, solid-state drives, as a new generation of storage devices, have been widely used.

目前由于固态硬盘和主机之间的交互比较单一,当固态硬盘(solid state disk,SSD)发生故障时,主机通常很难定位固态硬盘的故障起因,通常的做法是,将发生了故障的固态硬盘邮寄给生产厂家,由生产厂家定位故障原因。At present, due to the simple interaction between the solid state disk and the host, when the solid state disk (SSD) fails, it is usually difficult for the host to locate the cause of the failure of the solid state disk. Mail it to the manufacturer, and the manufacturer will locate the cause of the fault.

然而,生产厂家收到邮寄的固态硬盘后,由于固态硬盘不在故障现场,因此可能会丢失重要的现场故障信息,导致生产厂家在检测故障原因时,无法获取准确的故障信息。However, after the manufacturer receives the solid-state hard drive by mail, since the solid-state hard drive is not at the fault site, important on-site fault information may be lost, which makes it impossible for the manufacturer to obtain accurate fault information when detecting the cause of the fault.

发明内容Contents of the invention

本申请实施例提供了数据调度方法、主机以及固态硬盘,能够通过在自定义区域设置的自定义调试接口在线导出调试信息,提升了调试故障信息的准确性。The embodiment of the present application provides a data scheduling method, a host, and a solid-state hard disk, which can export debugging information online through a custom debugging interface set in a custom area, thereby improving the accuracy of debugging fault information.

本申请实施例提供了一种数据调度方法,包括:The embodiment of this application provides a data scheduling method, including:

主机通过自定义调试接口向SSD发送调试命令以及所述自定义调试接口对应的自定义调试接口地址,所述自定义调试接口由所述SSD设置于总线和接口标准(peripheralcomponent interconnect express,PCIe)设备,所述自定义调试接口对应所述PCIe设备中自定义区域的目标配置空间,所述目标配置空间用于存储调试数据;The host sends a debugging command and the corresponding custom debugging interface address of the custom debugging interface to the SSD through the custom debugging interface, and the custom debugging interface is set on a bus and an interface standard (peripheral component interconnect express, PCIe) device by the SSD , the self-defined debugging interface corresponds to the target configuration space of the self-defined area in the PCIe device, and the target configuration space is used to store debugging data;

所述主机通过所述自定义调试接口向所述SSD发送导出命令;The host sends an export command to the SSD through the custom debugging interface;

所述主机通过所述自定义调试接口接收所述SSD内部的调试信息。The host receives debugging information inside the SSD through the custom debugging interface.

可选地,在所述主机通过所述自定义调试接口向所述SSD发送调试命令以及所述自定义调试接口对应的自定义调试接口地址之前,所述方法还包括:Optionally, before the host sends a debugging command and a custom debugging interface address corresponding to the custom debugging interface to the SSD through the custom debugging interface, the method further includes:

当所述主机确定所述SSD发生故障时,所述主机判断能否识别所述PCIe设备;When the host determines that the SSD fails, the host determines whether the PCIe device can be identified;

若否,则所述主机扫描所述主机自身获取所述PCIe设备的信息。If not, the host scans the host itself to acquire the information of the PCIe device.

可选地,所述主机扫描所述主机自身获取所述PCIe设备的信息包括:Optionally, the host scanning the host itself to obtain the information of the PCIe device includes:

当所述主机为Linux主机时,所述Linux主机根据扫描命令获取所述PCIe设备的信息;When the host is a Linux host, the Linux host obtains the information of the PCIe device according to a scan command;

或者,or,

当所述主机为Windows主机时,所述Windows主机在所述Windows主机的设备管理器中搜索所述PCIe设备的信息。When the host is a Windows host, the Windows host searches for information about the PCIe device in a device manager of the Windows host.

本申请实施例提供了另一种数据调度方法,包括:The embodiment of this application provides another data scheduling method, including:

固态硬盘SSD在总线和接口标准PCIe设备设置自定义调试接口,所述自定义调试接口对应所述PCIe设备中自定义区域的目标配置空间,所述目标配置空间用于存储调试数据;The solid-state disk SSD sets a custom debugging interface at the bus and interface standard PCIe equipment, and the self-defining debugging interface corresponds to the target configuration space of the self-defined area in the PCIe device, and the target configuration space is used to store debugging data;

所述SSD通过所述自定义调试接口接收主机发送的调试命令以及所述自定义调试接口对应的自定义调试接口地址;The SSD receives the debugging command sent by the host and the custom debugging interface address corresponding to the custom debugging interface through the custom debugging interface;

所述SSD通过所述SSD中的纠错模块收集所述SSD内部的调试信息;The SSD collects debugging information inside the SSD through an error correction module in the SSD;

所述SSD将所述调试信息存储在所述目标配置空间;The SSD stores the debugging information in the target configuration space;

所述SSD通过所述自定义调试接口接收主机发送的导出命令;The SSD receives an export command sent by the host through the custom debugging interface;

所述SSD通过所述自定义调试接口向所述主机导出所述SSD内部的调试信息。The SSD exports the internal debugging information of the SSD to the host through the custom debugging interface.

本申请实施例提供了一种主机,包括:The embodiment of this application provides a host, including:

第一发送单元,用于通过自定义调试接口向固态硬盘SSD发送调试命令以及所述自定义调试接口对应的自定义调试接口地址,所述自定义调试接口由所述SSD设置于总线和接口标准PCIe设备,所述自定义调试接口对应所述PCIe设备中自定义区域的目标配置空间,所述目标配置空间用于存储调试数据;The first sending unit is used to send a debugging command and a custom debugging interface address corresponding to the custom debugging interface to the solid state disk SSD through a custom debugging interface, and the custom debugging interface is set on the bus and interface standard by the SSD PCIe device, the self-defined debugging interface corresponds to the target configuration space of the self-defined area in the PCIe device, and the target configuration space is used to store debugging data;

第二发送单元,用于通过所述自定义调试接口向所述SSD发送导出命令;A second sending unit, configured to send an export command to the SSD through the custom debugging interface;

接收单元,用于通过所述自定义调试接口接收所述SSD内部的调试信息。A receiving unit, configured to receive internal debugging information of the SSD through the custom debugging interface.

可选地,所述主机还包括:Optionally, the host also includes:

第一判断单元,用于当确定所述SSD发生故障时,判断能否识别所述PCIe设备;A first judging unit, configured to judge whether the PCIe device can be identified when it is determined that the SSD fails;

扫描单元,用于当确定不能识别所述PCIe设备时,扫描获取所述PCIe设备的信息。The scanning unit is configured to, when it is determined that the PCIe device cannot be identified, scan to acquire the information of the PCIe device.

可选地,扫描单元具体包括:Optionally, the scanning unit specifically includes:

当所述主机为Linux主机时,根据扫描命令获取所述PCIe设备的信息;When the host is a Linux host, the information of the PCIe device is obtained according to a scan command;

或者,or,

当所述主机为Windows主机时,在所述Windows主机的设备管理器中搜索所述PCIe设备的信息。When the host is a Windows host, search for information about the PCIe device in a device manager of the Windows host.

本申请实施例提供了一种固态硬盘,包括:The embodiment of the present application provides a solid-state hard disk, including:

设置单元,用于在总线和接口标准PCIe设备设置自定义调试接口,所述自定义调试接口对应所述PCIe设备中自定义区域的目标配置空间,所述目标配置空间用于存储调试数据;The setting unit is used to set a custom debugging interface on the bus and interface standard PCIe equipment, and the self-defining debugging interface corresponds to the target configuration space of the self-defined area in the PCIe device, and the target configuration space is used to store debugging data;

接收单元,用于通过所述自定义调试接口接收主机发送的调试命令以及所述自定义调试接口对应的自定义调试接口地址;The receiving unit is configured to receive the debugging command sent by the host through the custom debugging interface and the custom debugging interface address corresponding to the custom debugging interface;

收集单元,用于通过所述SSD中的纠错模块收集所述SSD内部的调试信息;A collection unit, configured to collect debugging information inside the SSD through an error correction module in the SSD;

存储单元,用于将所述调试信息存储在所述目标配置空间;a storage unit, configured to store the debugging information in the target configuration space;

第三发送单元,用于通过所述自定义调试接口接收主机发送的导出命令;A third sending unit, configured to receive an export command sent by the host through the custom debugging interface;

导出单元,用于通过所述自定义调试接口向所述主机导出所述SSD内部的调试信息。An exporting unit, configured to export the internal debugging information of the SSD to the host through the custom debugging interface.

本申请实施例提供了一种主机,该主机具有实现上述主机的数据调度方法中主机行为的功能。该功能可以通过硬件实现,也可以通过执行相应的软件实现。该硬件或软件包括一个或多个与上述功能相对应的模块。An embodiment of the present application provides a host, and the host has a function of implementing the behavior of the host in the above data scheduling method for the host. This function can be implemented by hardware or by executing corresponding software. The hardware or software includes one or more modules corresponding to the above functions.

本申请实施例提供了一种固态硬盘,该固态硬盘具有实现上述固态硬盘的数据调度方法中固态硬盘行为的功能。该功能可以通过硬件实现,也可以通过执行相应的软件实现。该硬件或软件包括一个或多个与上述功能相对应的模块。An embodiment of the present application provides a solid-state hard disk, and the solid-state hard disk has a function of implementing the behavior of the solid-state hard disk in the above data scheduling method for the solid-state hard disk. This function can be implemented by hardware or by executing corresponding software. The hardware or software includes one or more modules corresponding to the above functions.

本申请实施例提供了一种计算机存储介质,该计算机存储介质用于储存上述存储设备所用的计算机软件指令,其包括用于执行为主机所设计的程序。An embodiment of the present application provides a computer storage medium, and the computer storage medium is used for storing computer software instructions used by the above-mentioned storage device, including a program designed for executing a host.

本申请实施例提供了一种计算机存储介质,该计算机存储介质用于储存上述存储设备所用的计算机软件指令,其包括用于执行为固态硬盘所设计的程序。An embodiment of the present application provides a computer storage medium, and the computer storage medium is used for storing computer software instructions used by the above-mentioned storage device, including a program for executing a program designed for a solid-state hard disk.

本申请实施例提供了一种计算机程序产品,该计算机程序产品包括计算机软件指令,该计算机软件指令可通过处理器进行加载来实现上述数据调度方法的流程。An embodiment of the present application provides a computer program product, where the computer program product includes computer software instructions, and the computer software instructions can be loaded by a processor to implement the flow of the above data scheduling method.

从以上技术方案可以看出,本申请实施例具有以下优点:主机通过由固态硬盘在PCIe设备设置的自定义调试接口向SSD发送调试命令以及自定义调试接口对应的自定义调试接口地址,然后主机通过自定义调试接口向SSD发送导出命令,最后通过自定义调试接口接收SSD内部的调试信息,因此主机能够通过自定义调试接口实时获取重要的现场故障信息,从而正确定位故障原因,提升了主机检测固态硬盘故障原因的准确性。As can be seen from the above technical solutions, the embodiment of the present application has the following advantages: the host sends a debugging command and the corresponding custom debugging interface address to the SSD through the custom debugging interface set by the solid state disk on the PCIe device, and then the host Send an export command to the SSD through the custom debugging interface, and finally receive the internal debugging information of the SSD through the custom debugging interface, so the host can obtain important on-site fault information in real time through the custom debugging interface, thereby correctly locating the cause of the fault and improving the detection of the host The accuracy of the reason for the failure of the SSD.

附图说明Description of drawings

图1为本申请实施例中数据调度方法的一个实施例示意图;FIG. 1 is a schematic diagram of an embodiment of a data scheduling method in an embodiment of the present application;

图2为本申请实施例中数据调度方法的另一个实施例示意图Figure 2 is a schematic diagram of another embodiment of the data scheduling method in the embodiment of the present application

图3为本申请实施例中数据调度方法的另一个实施例示意图;FIG. 3 is a schematic diagram of another embodiment of the data scheduling method in the embodiment of the present application;

图4为本申请实施例中主机的一个实施例示意图;FIG. 4 is a schematic diagram of an embodiment of a host in the embodiment of the present application;

图5为本申请实施例中主机的另一个实施例示意图;FIG. 5 is a schematic diagram of another embodiment of the host in the embodiment of the present application;

图6为本申请实施例中固态硬盘的一个实施例示意图;FIG. 6 is a schematic diagram of an embodiment of a solid-state hard disk in the embodiment of the present application;

图7为本申请实施例中固态硬盘的另一个实施例示意图。FIG. 7 is a schematic diagram of another embodiment of a solid state disk in the embodiment of the present application.

具体实施方式Detailed ways

本申请实施例提供了数据调度方法、主机以及固态硬盘,用于通过在自定义区域设置的自定义调试接口在线导出调试信息,提升了调试故障信息的准确性。The embodiment of the present application provides a data scheduling method, a host computer, and a solid-state disk, which are used to export debugging information online through a custom debugging interface set in a custom area, thereby improving the accuracy of debugging fault information.

请参阅图1,图1为本申请实施例中数据调度方法的一个实施例示意图,下面从主机侧对图1中数据调度方法的一个实施例进行描述。Please refer to FIG. 1 . FIG. 1 is a schematic diagram of an embodiment of the data scheduling method in the embodiment of the present application. The following describes an embodiment of the data scheduling method in FIG. 1 from the host side.

本申请实施例中固态硬盘的数据恢复方法的一个实施例包括:An embodiment of the data recovery method of the solid-state hard disk in the embodiment of the present application includes:

101、主机通过自定义调试接口向SSD发送调试命令以及自定义调试接口地址;101. The host sends a debugging command and a custom debugging interface address to the SSD through a custom debugging interface;

本实施例中,主机为了能够导出SSD内部的调试信息,可以通过自定义调试接口向SSD发送调试命令以及与自定义调试接口对应的自定义调试接口地址。In this embodiment, in order to export debugging information inside the SSD, the host may send a debugging command and a custom debugging interface address corresponding to the custom debugging interface to the SSD through the custom debugging interface.

具体地,SSD的PCIe设备设置有配置空间,配置空间对应有PCIe设备上的各种接口,其中包括基地址头(basic header)的区域的接口、自定义头(vender defined header)的区域的接口、PCIe头的区域的接口等。通过PCIe设备的配置空间,主机端可以与SSD进行各种信息的交互。自定义调试接口由SSD设置于PCIe设备中与自定义区域对应的位置,该自定义接口对应PCIe设备中自定义区域的配置空间,该自定义区域的配置空间由SSD自行配置。自定义接口还对应有自定义调试接口地址,通过该自定义调试接口地址,主机可以向固态硬盘发送各种命令,并且可以由固态硬盘把调试信息存储在与该自定义调试接口地址对应的目标配置空间中。Specifically, the PCIe device of the SSD is provided with a configuration space, and the configuration space corresponds to various interfaces on the PCIe device, including interfaces in the area of the basic header (basic header) and interfaces in the area of the custom header (vender defined header) , the interface of the area of the PCIe header, etc. Through the configuration space of the PCIe device, the host can interact with the SSD for various information. The custom debugging interface is set by the SSD at the position corresponding to the custom area in the PCIe device. The custom interface corresponds to the configuration space of the custom area in the PCIe device, and the configuration space of the custom area is configured by the SSD itself. The custom interface also corresponds to the custom debugging interface address. Through the custom debugging interface address, the host can send various commands to the solid state disk, and the solid state disk can store the debugging information in the target corresponding to the custom debugging interface address. configuration space.

而自定义调试接口是本发明的关键所在,自定义调试接口由固态硬盘所配置,是固态硬盘从自定义区域划分出一部分配置空间作为自定义调试空间,也就是说,是固态硬盘从属于自定义区域的接口中划分出一部分接口,以供发送命令和保存调试信息使用,本申请实施例中将该部分接口称为自定义调试接口。由固态硬盘划分出来的该部分作为自定义调试空间的配置空间,在本申请实施例中称为目标配置空间。因此,也可以说,自定义调试接口对应PCIe设备中自定义区域内的目配置空间。该目标配置空间可以用于存储检测和定位固态硬盘故障原因的调试信息。And the self-defined debugging interface is the key of the present invention, the self-defined debugging interface is configured by the solid-state hard disk, is that the solid-state hard disk divides a part of the configuration space from the self-defined area as the self-defined debugging space, that is to say, the solid-state hard disk is subordinate to the self-defined debugging space. A part of the interfaces in the defined area is divided for sending commands and storing debugging information. In the embodiment of the present application, this part of the interfaces is called a custom debugging interface. This part divided by the solid state disk is used as the configuration space of the custom debugging space, which is called the target configuration space in the embodiment of the present application. Therefore, it can also be said that the custom debugging interface corresponds to the target configuration space in the custom area of the PCIe device. The target configuration space can be used to store debugging information for detecting and locating the cause of a solid-state disk failure.

参见下表1,表1为本申请实施例中PEIe设备的配置空间的配置表格。主机端与SSD通过配置空间进行信息交互。参见表1,从00h到184h的各个接口,均对应有各自的偏移地址,后述将偏移地址简称为地址。00h~34h的接口对应PCIe标准定义的配置空间,40h~60h接口属于自定义区域的配置空间。各个接口对应的配置空间的大小固定不变,一般为16字节或32字节。Referring to Table 1 below, Table 1 is a configuration table of the configuration space of the PEIe device in the embodiment of the present application. The host and the SSD exchange information through the configuration space. Referring to Table 1, each interface from 00h to 184h corresponds to its own offset address, and the offset address will be referred to as address for short in the following. Interfaces from 00h to 34h correspond to the configuration space defined by the PCIe standard, and interfaces from 40h to 60h belong to the configuration space of the custom area. The size of the configuration space corresponding to each interface is fixed, generally 16 bytes or 32 bytes.

表1Table 1

在40h~60h接口对应的自定义配置空间中,54h、58h、5Ch、60h为本发明中固态硬盘自行分配的用于调试故障信息的配置空间。主机可以通过这4个自定义的调试接口(即自定义的调试地址)向SSD的自定义调试的配置空间发送调试命令,要求SSD收集调试信息;并且,主机可以通过这些自定义调试接口发送对应于自定义的调试接口的自定义调试接口地址。54h接口对应的配置空间中,进一步划分为三个子配置空间,分别用于存储首要引导加载程序的跳转值(primary bootloader jump value,PBL jump value)、高位地址(upperaddress)、删除命令(delete command);58h接口对应的配置空间用于存储PBL低位地址(PBL lower address);5Ch接口对应的配置空间用于存储PBL数据标记(PBL data mark);60h接口对应的配置空间用于PBL数据(PBL数据)。本实施例中将自定义调试的配置空间统称为目标配置空间。In the custom configuration space corresponding to the 40h~60h interface, 54h, 58h, 5Ch, and 60h are the configuration spaces for debugging fault information allocated by the solid state disk in the present invention. The host can send debugging commands to the SSD's custom debugging configuration space through these four custom debugging interfaces (that is, custom debugging addresses), and requires the SSD to collect debugging information; and, the host can send corresponding commands through these custom debugging interfaces. The address of the custom debugging interface for the custom debugging interface. The configuration space corresponding to the 54h interface is further divided into three sub-configuration spaces, which are used to store the jump value of the primary bootloader (primary bootloader jump value, PBL jump value), upper address (upperaddress), delete command (delete command) ); the configuration space corresponding to the 58h interface is used to store the PBL lower address (PBL lower address); the configuration space corresponding to the 5Ch interface is used to store the PBL data mark (PBL data mark); the configuration space corresponding to the 60h interface is used for the PBL data (PBL data). In this embodiment, the configuration space for custom debugging is collectively referred to as the target configuration space.

102、主机通过自定义调试接口向SSD发送导出命令;102. The host sends an export command to the SSD through a custom debugging interface;

本实施例中,主机通过自定义调试接口向SSD的自定义调试配置空间发送调试命令和自定义调试接口地址后,可以通过自定义调试接口向SSD发送导出命令,要求导出SSD内部的调试信息的数据。In this embodiment, after the host sends the debugging command and the address of the custom debugging interface to the custom debugging configuration space of the SSD through the custom debugging interface, it can send an export command to the SSD through the custom debugging interface, requesting to export the internal debugging information of the SSD. data.

需要说明的是,由于各个接口对应的配置空间一般能够存储16字节或32字节的数据量,各个接口对应的配置空间有限,这样就要求主机在每次发送导出命令时,需要限制导出的数据量,因此主机可以通过自定义调试接口连续向SSD发送导出命令。It should be noted that, since the configuration space corresponding to each interface can generally store 16 bytes or 32 bytes of data, the configuration space corresponding to each interface is limited. This requires the host to limit the exported data every time it sends an export command. The amount of data, so the host can continuously send export commands to the SSD through the custom debug interface.

103、主机通过自定义调试接口接收SSD内部的调试信息。103. The host receives debugging information inside the SSD through a custom debugging interface.

主机通过自定义调试接口向SSD发送导出命令后,SSD就会通过内置纠错模块收集SSD内部的调试信息,并将调试信息保存到与自定义调试接口对应的目标配置空间中。该调试信息包括调试日志、SSD的各种参数(包括管理数据和元数据)。通过上述步骤,主机就可以通过自定义调试接口导出SSD内部的调试信息,以供技术人员检测SSD的故障原因使用。After the host sends the export command to the SSD through the custom debugging interface, the SSD will collect the internal debugging information of the SSD through the built-in error correction module, and save the debugging information to the target configuration space corresponding to the custom debugging interface. The debugging information includes debugging logs and various parameters of the SSD (including management data and metadata). Through the above steps, the host can export the internal debugging information of the SSD through the custom debugging interface, so as to be used by technicians to detect the cause of the SSD failure.

需要说明的是,本实施例中的操作步骤既可以用于检测SSD发生断电故障的调试信息,也可以用于检测SSD发生没有断电但通信中断故障的调试信息,具体此处不做限定。It should be noted that the operation steps in this embodiment can be used not only to detect the debugging information of SSD power failure, but also to detect the debugging information of SSD failure without power failure but communication interruption, which is not limited here. .

本申请实施例中,主机通过由固态硬盘在PCIe设备设置的自定义调试接口向SSD发送调试命令以及自定义调试接口对应的自定义调试接口地址,然后主机通过自定义调试接口向SSD发送导出命令,最后通过自定义调试接口接收SSD内部的调试信息,因此主机能够通过自定义调试接口实时获取重要的现场故障信息,从而正确定位故障原因,提升了主机检测固态硬盘故障原因的准确性。In the embodiment of this application, the host sends the debugging command and the corresponding custom debugging interface address to the SSD through the custom debugging interface set by the solid state disk on the PCIe device, and then the host sends the export command to the SSD through the custom debugging interface , and finally receive the debugging information inside the SSD through the custom debugging interface, so the host can obtain important on-site fault information in real time through the custom debugging interface, thereby correctly locating the cause of the fault and improving the accuracy of the host in detecting the cause of the solid state drive failure.

以上从主机侧对本申请实施例中数据调度方法的一个实施例进行了描述。下面从SSD侧对本申请实施例中数据调度方法的另一个实施例。参见图2,图2为本申请实施例中数据调度方法的另一个实施例。An embodiment of the data scheduling method in the embodiment of the present application has been described above from the host side. Another embodiment of the data scheduling method in the embodiment of the present application is described below from the SSD side. Referring to FIG. 2, FIG. 2 is another embodiment of the data scheduling method in the embodiment of the present application.

本申请实施例中数据调度方法的另一个实施例包括:Another embodiment of the data scheduling method in the embodiment of the present application includes:

201、SSD在PCIe设备设置自定义调试接口;201. The SSD sets a custom debugging interface on the PCIe device;

本实施例中,SSD首先可以在PCIe设备的自定义区域设置自定义调试接口,各个自定义调试接口分别对应各自不同的配置空间,同时对应各自不同的偏移地址(简称为地址)。该自定义调试接口为前述图1的步骤101中述及的54h、58h、5Ch以及60h。具体的SSD自行分配自定义接口的内容已在前述图1的步骤101中详述,此处不再赘述。In this embodiment, the SSD can first set a custom debugging interface in a custom area of the PCIe device, each custom debugging interface corresponds to a different configuration space, and corresponds to a different offset address (abbreviated as an address). The self-defined debugging interfaces are 54h, 58h, 5Ch and 60h mentioned above in step 101 of FIG. 1 . The specific self-assignment of the custom interface by the SSD has been described in detail in the aforementioned step 101 of FIG. 1 , and will not be repeated here.

202、SSD通过自定义调试接口接收主机发送的调试命令以及自定义调试接口地址;202. The SSD receives the debugging command sent by the host and the address of the custom debugging interface through the custom debugging interface;

本实施例中,SSD在PCIe设备完成自定义调试接口的设置之后,可以通过自定义调试接口接收主机发送的调试命令,以及接收与自定义调试接口对应的自定义调试接口地址,自定义调试接口地址对应自定义调试接口的配置空间,即目标配置空间。In this embodiment, after the PCIe device completes the setting of the custom debugging interface, the SSD can receive the debugging command sent by the host through the custom debugging interface, and receive the custom debugging interface address corresponding to the custom debugging interface, and the custom debugging interface The address corresponds to the configuration space of the custom debugging interface, that is, the target configuration space.

203、SSD通过SSD中的纠错模块收集SSD内部的调试信息;203. The SSD collects debugging information inside the SSD through an error correction module in the SSD;

SSD在收到调试命令后,可以通过SSD内部的纠错(debug)模块收集SSD内部的与故障相关的调试信息。After the SSD receives the debugging command, it can collect the debugging information related to the fault inside the SSD through the error correction (debug) module inside the SSD.

204、SSD将调试信息存储在目标配置空间;204. The SSD stores the debugging information in the target configuration space;

SSD在完成调试信息的收集工作后,可以将调试信息存储在自定义调试接口地址对应的目标配置空间中,以备主机使用。After the SSD finishes collecting the debugging information, it can store the debugging information in the target configuration space corresponding to the address of the custom debugging interface for use by the host.

205、SSD通过自定义调试接口接收主机发送的导出命令;205. The SSD receives the export command sent by the host through the custom debugging interface;

本实施例中,SSD在将调试信息存储在目标配置空间后,可以通过自定义调试接口接收主机发送的导出命令。In this embodiment, after the SSD stores the debugging information in the target configuration space, it can receive the export command sent by the host through the custom debugging interface.

206、SSD通过自定义调试接口向主机导出SSD内部的调试信息。206. The SSD exports debugging information inside the SSD to the host through a custom debugging interface.

本实施例中,SSD在接收到主机发送的导出命令之后,可以通过PCIe设备的自定义调试接口向主机导出SSD内部的调试信息。In this embodiment, after the SSD receives the export command sent by the host, it can export the internal debugging information of the SSD to the host through the custom debugging interface of the PCIe device.

需要说明的是,SSD可以通过PCIe设备的自定义调试接口连续接收到主机不断发送的导出命令,因此SSD通过每条导出命令,逐条向主机导出调试信息。一般而言,SSD的PCIe设备中的各个接口可以传输的数据为16字节或32字节,因此根据接收到的导出命令,SSD也只能导出16字节或32字节等有限的数据量。也正因为如此,需要主机不断发送导出命令,从而使SSD收集调试信息。It should be noted that the SSD can continuously receive the export commands sent by the host through the custom debugging interface of the PCIe device, so the SSD exports debugging information to the host one by one through each export command. Generally speaking, each interface in the SSD PCIe device can transmit 16 bytes or 32 bytes of data, so according to the received export command, the SSD can only export a limited amount of data such as 16 bytes or 32 bytes. . Because of this, the host needs to send export commands continuously, so that the SSD can collect debugging information.

本申请实施例中,SSD通过在PCIe设备预设的自定义调试接口接收主机发送的调试命令以及自定义调试接口地址,然后通过SSD内部的纠错模块收集SSD内部的调试信息,并将调试信息存储在目标配置空间,当SSD通过自定义调试接口接收到主机发送的导出命令后,可以通过自定义调试接口向主机导出SSD内部的调试信息,因此能够使主机通过自定义调试接口实时获取重要的现场故障信息,从而正确定位故障原因,提升了主机检测固态硬盘故障原因的准确性。In the embodiment of this application, the SSD receives the debugging command sent by the host and the address of the custom debugging interface through the custom debugging interface preset in the PCIe device, and then collects the debugging information inside the SSD through the error correction module inside the SSD, and sends the debugging information to Stored in the target configuration space, when the SSD receives the export command sent by the host through the custom debugging interface, it can export the internal debugging information of the SSD to the host through the custom debugging interface, so that the host can obtain important information in real time through the custom debugging interface. On-site failure information, so as to correctly locate the cause of the failure, and improve the accuracy of the host to detect the cause of the solid-state hard disk failure.

以上从固态硬盘侧对本申请实施例中数据调度方法进行了描述,以下参见图3,图3为本申请实施例中数据调度方法的另一个实施例。The above describes the data scheduling method in the embodiment of the present application from the side of the solid-state hard disk. Referring to FIG. 3 , FIG. 3 is another embodiment of the data scheduling method in the embodiment of the present application.

本申请实施例中数据调度方法的另一个实施例包括:Another embodiment of the data scheduling method in the embodiment of the present application includes:

301、SSD在PCIe设备设置自定义调试接口;301. The SSD sets a custom debugging interface on the PCIe device;

本实施例中的步骤301与前述图2所述实施例中的步骤201类似,此处不再赘述。Step 301 in this embodiment is similar to step 201 in the foregoing embodiment described in FIG. 2 , and will not be repeated here.

302、当主机确定SSD发生故障时,所述主机判断能否识别PCIe设备;302. When the host determines that the SSD fails, the host determines whether the PCIe device can be identified;

本实施例中,当主机确定SSD发生故障时,主机可以首先判断能否识别SSD中设置的PCIe设备。In this embodiment, when the host determines that the SSD is faulty, the host may first determine whether the PCIe device set in the SSD can be identified.

需要说明的是,本申请实施例中述及的SSD的故障,可以是SSD发生了断电的故障,也可以是SSD和主机之间通信中断的故障,具体此处不做限定。It should be noted that the failure of the SSD mentioned in the embodiment of the present application may be a failure of the SSD being powered off, or a failure of communication interruption between the SSD and the host, which is not specifically limited here.

若能识别SSD中的PCIe设备,则无需在SSD中扫描识别SSD的PCIe设备,执行步骤304;若不能识别,则执行步骤303。If the PCIe device in the SSD can be identified, step 304 is performed without scanning the SSD to identify the PCIe device in the SSD; if not, step 303 is performed.

303、主机扫描主机自身获取PCIe设备的信息;303. The host scans the host itself to obtain the information of the PCIe device;

如果主机无法识别SSD中的PCIe,则主机可以扫描获取PCIe设备的信息。If the host cannot recognize the PCIe in the SSD, the host can scan to obtain the information of the PCIe device.

进一步地,当主机为Linux主机时,Linux主机可以根据扫描命令获取PCIe设备的信息。例如,该扫描命令可以为:Further, when the host is a Linux host, the Linux host can obtain the information of the PCIe device according to the scan command. For example, the scan command could be:

echo 1>/sys/bus/pci/rescan。echo 1>/sys/bus/pci/rescan.

当主机为Window主机时,Windows主机可以在Windows主机的设备管理器中刷新并搜索PCIe设备的信息。When the host is a Windows host, the Windows host can refresh and search for PCIe device information in the device manager of the Windows host.

主机扫描主机自身获取PCIe设备的信息的方法,可以因主机的操作系统的不同而有所不同,具体此处不做限定。The method for the host to scan the host itself to obtain the information of the PCIe device may vary depending on the operating system of the host, which is not specifically limited here.

304、SSD通过SSD中的纠错模块收集SSD内部的调试信息;304. The SSD collects debugging information inside the SSD through an error correction module in the SSD;

305、SSD将调试信息存储在目标配置空间;305. The SSD stores the debugging information in the target configuration space;

本实施例中的步骤304和305与前述图2所述的实施例中的步骤203和204类似,具体此处不做限定。Steps 304 and 305 in this embodiment are similar to steps 203 and 204 in the embodiment described above in FIG. 2 , and are not specifically limited here.

306、主机通过自定义调试接口向SSD发送导出命令;306. The host sends an export command to the SSD through a custom debugging interface;

本步骤与前述图1所述的实施例中的步骤102类似,具体此处不做限定。This step is similar to step 102 in the embodiment described above in FIG. 1 , and is not specifically limited here.

307、SSD通过自定义接口向主机导出SSD内部的调试信息。307. The SSD exports debugging information inside the SSD to the host through a custom interface.

本步骤与前述图2所述的实施例中的步骤206类似,具体此处不做限定。This step is similar to step 206 in the embodiment described above in FIG. 2 , and is not specifically limited here.

本申请实施例中,由于主机能够在向SSD发送调试命令之前判断能否识别PCIe设备,如果无法识别,则扫描进行识别从而获取PCIe设备的信息,这样才可以找到自定义调试接口从SSD导出SSD发生故障的调试信息,因此进一步提升了本申请实施例的技术方案的实用性,在此基础上能够保证主机能够获取到重要的现场故障信息,正确定位故障原因,既提升了主机检测SSD故障原因的准确性,又提升了本发明技术方案的实用性。In the embodiment of this application, since the host can determine whether the PCIe device can be recognized before sending the debugging command to the SSD, if it cannot be recognized, then scan and identify to obtain the information of the PCIe device, so that the custom debugging interface can be found to export the SSD from the SSD The debugging information of the failure, so the practicability of the technical solution of the embodiment of the present application is further improved. On this basis, it can be ensured that the host can obtain important on-site failure information and correctly locate the cause of the failure, which not only improves the host's detection of SSD failure causes. The accuracy of the method improves the practicability of the technical solution of the present invention.

上面对本申请实施例中的数据调度方法进行了描述,下面对本申请实施例中的主机进行描述,请参阅图4,图4为本申请实施例中主机的一个实施例示意图;The data scheduling method in the embodiment of the present application is described above, and the host in the embodiment of the present application is described below, please refer to FIG. 4, which is a schematic diagram of an embodiment of the host in the embodiment of the present application;

本申请实施例中主机的一个实施例包括:An embodiment of the host in the embodiment of this application includes:

第一发送单元401,用于通过自定义调试接口向固态硬盘SSD发送调试命令以及自定义调试接口对应的自定义调试接口地址,该自定义调试接口由SSD设置于总线和接口标准PCIe设备,该自定义调试接口对应PCIe设备中自定义区域的目标配置空间,该目标配置空间用于存储调试数据;The first sending unit 401 is used to send a debug command and a custom debug interface address corresponding to the custom debug interface to the solid-state disk SSD through a custom debug interface. The custom debug interface is set on the bus and the interface standard PCIe device by the SSD. The custom debugging interface corresponds to the target configuration space of the custom area in the PCIe device, and the target configuration space is used to store debugging data;

第二发送单元402,用于通过自定义调试接口向SSD发送导出命令;The second sending unit 402 is configured to send an export command to the SSD through a custom debugging interface;

接收单元403,用于通过自定义调试接口接收SSD内部的调试信息。The receiving unit 403 is configured to receive internal debugging information of the SSD through a custom debugging interface.

可选地,主机还包括:Optionally, the host also includes:

第一判断单元404,用于当确定SSD发生故障时,判断能否识别PCIe设备;The first judging unit 404 is configured to judge whether the PCIe device can be identified when it is determined that the SSD fails;

扫描单元405,用于当确定不能识别PCIe设备时,扫描获取PCIe设备的信息。The scanning unit 405 is configured to, when it is determined that the PCIe device cannot be identified, scan to obtain information about the PCIe device.

可选地,扫描单元405具体包括:Optionally, the scanning unit 405 specifically includes:

当所述主机为Linux主机时,根据扫描命令获取所述PCIe设备的信息;When the host is a Linux host, the information of the PCIe device is obtained according to a scan command;

或者,or,

当所述主机为Windows主机时,在所述Windows主机的设备管理器中搜索所述PCIe设备的信息。When the host is a Windows host, search for information about the PCIe device in a device manager of the Windows host.

本申请实施例中,第一发送单元401通过由固态硬盘在PCIe设备设置的自定义调试接口向SSD发送调试命令以及自定义调试接口对应的自定义调试接口地址,然后第二发送单元402通过自定义调试接口向SSD发送导出命令,最后通过自定义调试接口接收SSD内部的调试信息,因此主机能够通过自定义调试接口实时获取重要的现场故障信息,从而正确定位故障原因,提升了主机检测固态硬盘故障原因的准确性。In the embodiment of the present application, the first sending unit 401 sends the debugging command and the custom debugging interface address corresponding to the custom debugging interface to the SSD through the custom debugging interface set by the solid state disk on the PCIe device, and then the second sending unit 402 sends the debugging command through the self-defined debugging interface Define the debugging interface to send export commands to the SSD, and finally receive the internal debugging information of the SSD through the custom debugging interface, so the host can obtain important on-site fault information in real time through the custom debugging interface, thereby correctly locating the cause of the fault and improving the detection of the solid state drive by the host. The accuracy of the cause of the failure.

参见图5,图5为本申请实施例中主机的另一个实施例示意图。本申请实施例中的固态硬盘的另一个实施例包括:Referring to FIG. 5, FIG. 5 is a schematic diagram of another embodiment of the host in the embodiment of the present application. Another embodiment of the solid-state hard disk in the embodiment of the present application includes:

该固态硬盘500可因配置或性能不同而产生比较大的差异,可以包括一个或一个以上处理器(central processing units,CPU)501(例如,一个或一个以上处理器)和存储器505,该存储器505中存储有一个或一个以上的应用程序或数据。The solid-state hard drive 500 may have relatively large differences due to different configurations or performances, and may include one or more processors (central processing units, CPU) 501 (for example, one or more processors) and memory 505, the memory 505 There are one or more applications or data stored in it.

其中,存储器505可以是易失性存储或持久存储。存储在存储器505的程序可以包括一个或一个以上模块,每个模块可以包括对服务器中的一系列指令操作。更进一步地,处理器501可以设置为与存储器505通信,在固态硬盘500上执行存储器505中的一系列指令操作。Wherein, the storage 505 may be a volatile storage or a persistent storage. The program stored in the memory 505 may include one or more modules, and each module may include a series of instructions to operate on the server. Furthermore, the processor 501 may be configured to communicate with the memory 505 , and execute a series of instruction operations in the memory 505 on the solid state disk 500 .

固态硬盘500还可以包括一个或一个以上电源502,一个或一个以上有线或无线网络接口503,一个或一个以上输入输出接口504,和/或,一个或一个以上操作系统,例如Windows ServerTM,Mac OS XTM,UnixTM,LinuxTM,FreeBSDTM等等。The solid state hard drive 500 can also include one or more power supplies 502, one or more wired or wireless network interfaces 503, one or more input and output interfaces 504, and/or, one or more operating systems, such as Windows ServerTM, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM, etc.

需要说明的是,本实施例中的存储器505可以使用SATA接口的存储硬盘,具体此处不做限定。此外,本实施例中的固态硬盘500可以不设置掉电保护装置,且可以只设置一个处理器501,具体此处不做限定。It should be noted that the storage 505 in this embodiment may use a storage hard disk with a SATA interface, which is not specifically limited here. In addition, the solid state hard disk 500 in this embodiment may not be provided with a power-down protection device, and may only be provided with one processor 501 , which is not specifically limited here.

本实施例中固态硬盘500中的处理器501所执行的流程与前述图1至图3所示的实施例中描述的方法流程类似,此处不再赘述。The process executed by the processor 501 in the solid state disk 500 in this embodiment is similar to the process described in the above-mentioned embodiments shown in FIGS. 1 to 3 , and will not be repeated here.

本申请实施例的有益效果是,处理器501能够通过固态硬盘在PCIe设备设置的自定义调试接口实施获取重要的现场故障信息,从而正确定位故障原因,提升了主机检测固态硬盘故障原因的准确性。The beneficial effect of the embodiment of the present application is that the processor 501 can obtain important on-site fault information through the custom debugging interface set by the solid-state hard drive on the PCIe device, thereby correctly locating the cause of the fault and improving the accuracy of the host to detect the cause of the solid-state hard drive failure .

本申请实施例还提供一种计算机存储介质,该计算机存储介质用于储存为前述主机所用的计算机软件指令,其包括用于执行为主机所设计的程序。The embodiment of the present application also provides a computer storage medium, which is used to store computer software instructions used by the aforementioned host, including a program for executing a program designed for the host.

上面对本申请实施例中的主机进行了描述,下面对本申请实施例中的固态硬盘进行描述。参见图6,图6为本申请实施例中固态硬盘的一个实施例。The host in the embodiment of the present application has been described above, and the solid state disk in the embodiment of the present application will be described below. Referring to FIG. 6, FIG. 6 is an embodiment of a solid state disk in the embodiment of the present application.

本申请实施例中固态硬盘的一个实施例包括:An embodiment of the solid-state hard disk in the embodiment of the present application includes:

设置单元601,用于在总线和接口标准PCIe设备设置自定义调试接口,该自定义调试接口对应PCIe设备中自定义区域的目标配置空间,该目标配置空间用于存储调试数据;The setting unit 601 is used to set a custom debugging interface on the bus and interface standard PCIe devices, the custom debugging interface corresponds to the target configuration space of the custom area in the PCIe device, and the target configuration space is used to store debugging data;

接收单元602,用于通过自定义调试接口接收主机发送的调试命令以及自定义调试接口对应的自定义调试接口地址;The receiving unit 602 is configured to receive the debugging command sent by the host through the custom debugging interface and the custom debugging interface address corresponding to the custom debugging interface;

收集单元603,用于通过SSD中的纠错模块收集SSD内部的调试信息;The collection unit 603 is used to collect debugging information inside the SSD through the error correction module in the SSD;

存储单元604,用于将调试信息存储在目标配置空间;a storage unit 604, configured to store debugging information in the target configuration space;

第三发送单元605,用于通过自定义调试接口接收主机发送的导出命令;The third sending unit 605 is configured to receive an export command sent by the host through a custom debugging interface;

导出单元606,用于通过自定义调试接口向主机导出SSD内部的调试信息。The exporting unit 606 is configured to export debugging information inside the SSD to the host through a custom debugging interface.

本申请实施例中,接收单元602通过设置单元601在PCIe设备预设的自定义调试接口接收主机发送的调试命令以及自定义调试接口地址,然后收集单元603通过纠错模块收集SSD内部的调试信息,存储单元604将调试信息存储在目标配置空间,当SSD通过自定义调试接口接收到主机发送的导出命令后,可以由导出单元606通过自定义调试接口向主机导出SSD内部的调试信息,因此能够使主机通过自定义调试接口实时获取重要的现场故障信息,从而正确定位故障原因,提升了主机检测固态硬盘故障原因的准确性。In the embodiment of this application, the receiving unit 602 receives the debugging command and the address of the custom debugging interface sent by the host through the custom debugging interface preset by the PCIe device through the setting unit 601, and then the collecting unit 603 collects the debugging information inside the SSD through the error correction module , the storage unit 604 stores the debugging information in the target configuration space. When the SSD receives the export command sent by the host through the custom debugging interface, the export unit 606 can export the internal debugging information of the SSD to the host through the custom debugging interface, so it can The host can obtain important on-site fault information in real time through the custom debugging interface, so as to correctly locate the cause of the fault and improve the accuracy of the host to detect the cause of the solid-state hard disk failure.

请参阅图7,图7为本申请实施例中固态硬盘的另一个实施例示意图。Please refer to FIG. 7 . FIG. 7 is a schematic diagram of another embodiment of the solid state disk in the embodiment of the present application.

本申请实施例中的固态硬盘的另一个实施例包括:Another embodiment of the solid-state hard disk in the embodiment of the present application includes:

该固态硬盘700可因配置或性能不同而产生比较大的差异,可以包括一个或一个以上处理器(central processing units,CPU)701(例如,一个或一个以上处理器)和存储器705,该存储器705中存储有一个或一个以上的应用程序或数据。The solid-state hard disk 700 may have relatively large differences due to different configurations or performances, and may include one or more processors (central processing units, CPU) 701 (for example, one or more processors) and memory 705, the memory 705 There are one or more applications or data stored in it.

其中,存储器705可以是易失性存储或持久存储。存储在存储器705的程序可以包括一个或一个以上模块,每个模块可以包括对服务器中的一系列指令操作。更进一步地,处理器701可以设置为与存储器705通信,在固态硬盘700上执行存储器705中的一系列指令操作。Wherein, the storage 705 may be a volatile storage or a persistent storage. The program stored in the memory 705 may include one or more modules, and each module may include a series of instructions to operate on the server. Furthermore, the processor 701 may be configured to communicate with the memory 705 , and execute a series of instruction operations in the memory 705 on the solid state disk 700 .

固态硬盘700还可以包括一个或一个以上电源702,一个或一个以上有线或无线网络接口703,一个或一个以上输入输出接口704,和/或,一个或一个以上操作系统,例如Windows ServerTM,Mac OS XTM,UnixTM,LinuxTM,FreeBSDTM等等。The solid state hard drive 700 can also include one or more power supplies 702, one or more wired or wireless network interfaces 703, one or more input and output interfaces 704, and/or, one or more operating systems, such as Windows ServerTM, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM, etc.

需要说明的是,本实施例中的存储器705可以使用SATA接口的存储硬盘,具体此处不做限定。此外,本实施例中的固态硬盘700可以不设置掉电保护装置,且可以只设置一个处理器701,具体此处不做限定。It should be noted that the storage 705 in this embodiment may use a storage hard disk with a SATA interface, which is not specifically limited here. In addition, the solid state hard disk 700 in this embodiment may not be provided with a power-off protection device, and may only be provided with one processor 701 , which is not specifically limited here.

本实施例中固态硬盘700中的处理器701所执行的流程与前述图1至图3所示的实施例中描述的方法流程类似,此处不再赘述。The process executed by the processor 701 in the solid state disk 700 in this embodiment is similar to the process described in the above-mentioned embodiments shown in FIG. 1 to FIG. 3 , and will not be repeated here.

本申请实施例的有益效果是,处理器701可以在PCIe设备预设自定义调试接口,并根据接收到的调试命令通过纠错模块收集SSD内部的调试信息,最后根据接收到的导出命令通过自定义调试接口向主机导出SSD内部的调试信息,因此能够使主机通过自定义调试接口实时获取重要的现场故障信息,从而正确定位故障原因,提升了主机检测固态硬盘故障原因的准确性。The beneficial effect of the embodiment of the present application is that the processor 701 can preset a custom debugging interface on the PCIe device, and collect the internal debugging information of the SSD through the error correction module according to the received debugging command, and finally pass the self-defined debugging information according to the received export command. Define the debugging interface to export the debugging information inside the SSD to the host, so that the host can obtain important on-site fault information in real time through the custom debugging interface, thereby correctly locating the cause of the fault and improving the accuracy of the host in detecting the cause of the SSD failure.

本申请实施例还提供一种计算机存储介质,该计算机存储介质用于储存为前述固态硬盘所用的计算机软件指令,其包括用于执行为固态硬盘所设计的程序。The embodiment of the present application also provides a computer storage medium, which is used for storing computer software instructions used for the aforementioned solid-state hard disk, including a program for executing a program designed for the solid-state hard disk.

本申请实施例还提供一种计算机程序产品,该计算机程序产品包括计算机软件指令,该计算机软件指令可通过处理器进行加载来实现前述图1至3所示的实施例中的方法流程。An embodiment of the present application further provides a computer program product, where the computer program product includes computer software instructions, and the computer software instructions can be loaded by a processor to implement the method flow in the foregoing embodiments shown in FIGS. 1 to 3 .

所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的系统,装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。Those skilled in the art can clearly understand that for the convenience and brevity of the description, the specific working process of the above-described system, device and unit can refer to the corresponding process in the foregoing method embodiment, which will not be repeated here.

在本申请所提供的几个实施例中,应该理解到,所揭露的系统,装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。In the several embodiments provided in this application, it should be understood that the disclosed system, device and method can be implemented in other ways. For example, the device embodiments described above are only illustrative. For example, the division of the units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or May be integrated into another system, or some features may be ignored, or not implemented. In another point, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces, and the indirect coupling or communication connection of devices or units may be in electrical, mechanical or other forms.

所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place, or may be distributed to multiple network units. Part or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, each unit may exist separately physically, or two or more units may be integrated into one unit. The above-mentioned integrated units can be implemented in the form of hardware or in the form of software functional units.

所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行本申请各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:U盘、移动硬盘、只读存储器(ROM,Read-OnlyMemory)、随机存取存储器(RAM,Random Access Memory)、磁碟或者光盘等各种可以存储程序代码的介质。If the integrated unit is realized in the form of a software function unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or part of the contribution to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium , including several instructions to make a computer device (which may be a personal computer, a server, or a network device, etc.) execute all or part of the steps of the methods described in the various embodiments of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-OnlyMemory), random access memory (RAM, Random Access Memory), magnetic disk or optical disk and other media that can store program codes.

Claims (10)

1. A method for scheduling data, comprising:
the host sends a debugging command and a custom debugging interface address corresponding to the custom debugging interface to a Solid State Disk (SSD) through the custom debugging interface, the custom debugging interface is arranged on a bus and interface standard PCIe (peripheral component interconnect express) device by the SSD, the custom debugging interface corresponds to a target configuration space of a custom area in the PCIe device, and the target configuration space is used for storing debugging data;
the host sends a export command to the SSD through the custom debugging interface;
and the host receives debugging information inside the SSD through the custom debugging interface.
2. The method of claim 1, wherein before the host sends a debug command and a custom debug interface address corresponding to the custom debug interface to the SSD through the custom debug interface, the method further comprises:
when the host determines that the SSD fails, the host judges whether the PCIe device can be identified;
if not, the host scans the information of the PCIe equipment acquired by the host.
3. The method of claim 2, wherein the host scanning the host itself for information about the PCIe device comprises:
when the host is a Linux host, the Linux host acquires information of the PCIe equipment according to a scanning command;
or,
and when the host is a Windows host, the Windows host searches the information of the PCIe equipment in the equipment manager of the Windows host.
4. A method for scheduling data, comprising:
the method comprises the steps that a Solid State Disk (SSD) sets a custom debugging interface on a bus and interface standard PCIe device, wherein the custom debugging interface corresponds to a target configuration space of a custom area in the PCIe device, and the target configuration space is used for storing debugging data;
the SSD receives a debugging command sent by a host and a custom debugging interface address corresponding to the custom debugging interface through the custom debugging interface;
the SSD collects debugging information inside the SSD through an error correction module in the SSD;
the SSD stores the debugging information in the target configuration space;
the SSD receives a lead-out command sent by a host through the custom debugging interface;
and the SSD exports debugging information inside the SSD to the host through the custom debugging interface.
5. A host, comprising:
a processor, a memory, an input-output device, and a bus;
the processor, the memory and the input and output equipment are respectively connected with the bus;
the processor is configured to perform the steps of:
sending a debugging command and a custom debugging interface address corresponding to the custom debugging interface to a Solid State Disk (SSD) through the custom debugging interface, wherein the custom debugging interface is arranged on a bus and interface standard PCIe (peripheral component interconnect express) device by the SSD, the custom debugging interface corresponds to a target configuration space of a custom area in the PCIe device, and the target configuration space is used for storing debugging data; sending a export command to the SSD through the custom debug interface; and receiving debugging information inside the SSD through the custom debugging interface.
6. The host of claim 5, wherein the processor is further configured to determine whether the PCIe device is identifiable upon determining that the SSD is malfunctioning; and if not, scanning to acquire the information of the PCIe equipment.
7. The method of claim 6, wherein the processor is specifically configured to:
when the host is a Linux host, acquiring information of the PCIe equipment according to a scanning command;
or,
and when the host is a Windows host, searching the information of the PCIe equipment in the equipment manager of the Windows host.
8. A solid state disk, comprising:
a processor, a memory, an input-output device, and a bus;
the processor, the memory and the input and output equipment are respectively connected with the bus;
the processor is configured to perform the steps of:
setting a custom debugging interface on a bus and interface standard PCIe device, wherein the custom debugging interface corresponds to a target configuration space of a custom area in the PCIe device, and the target configuration space is used for storing debugging data; receiving a debugging command sent by a host and a custom debugging interface address corresponding to the custom debugging interface through the custom debugging interface; collecting debugging information inside the SSD through an error correction module in the SSD; storing the debugging information in the target configuration space; receiving a lead-out command sent by a host through the custom debugging interface; and exporting the debugging information inside the SSD to the host through the custom debugging interface.
9. A computer program product comprising instructions which, when run on a computer, cause the computer to perform the method of any one of claims 1 to 3.
10. A computer program product comprising instructions which, when run on a computer, cause the computer to perform the method of claim 4.
CN201810867470.6A 2018-08-01 2018-08-01 Data scheduling method, host and solid state disk Pending CN109032897A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810867470.6A CN109032897A (en) 2018-08-01 2018-08-01 Data scheduling method, host and solid state disk

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810867470.6A CN109032897A (en) 2018-08-01 2018-08-01 Data scheduling method, host and solid state disk

Publications (1)

Publication Number Publication Date
CN109032897A true CN109032897A (en) 2018-12-18

Family

ID=64648720

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810867470.6A Pending CN109032897A (en) 2018-08-01 2018-08-01 Data scheduling method, host and solid state disk

Country Status (1)

Country Link
CN (1) CN109032897A (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114168073A (en) * 2021-11-18 2022-03-11 苏州浪潮智能科技有限公司 Access method and device for solid state disk debugging space
CN114237949A (en) * 2021-11-18 2022-03-25 合肥沛睿微电子股份有限公司 Debugging information access method and electronic equipment thereof
CN115220948A (en) * 2022-07-26 2022-10-21 北京忆恒创源科技股份有限公司 Method and device for making SSD enter emergency mode and be visible by host end
WO2022232980A1 (en) * 2021-05-06 2022-11-10 Micron Technology, Inc. Debug interface between host system and memory system
WO2024109708A1 (en) * 2022-11-21 2024-05-30 苏州元脑智能科技有限公司 Method and system for wireless debugging of solid-state drives, device and storage medium

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103257912A (en) * 2012-02-16 2013-08-21 鸿富锦精密工业(深圳)有限公司 Testing device and method thereof for testing peripheral component interface express (PCIE) slot
US8954788B2 (en) * 2013-02-13 2015-02-10 Lsi Corporation Methods and structure for single root input/output virtualization enhancement in peripheral component interconnect express systems
CN104516843A (en) * 2013-09-30 2015-04-15 韩商联测股份有限公司 Non-mounted storage test device based on FPGA
US9086965B2 (en) * 2011-12-15 2015-07-21 International Business Machines Corporation PCI express error handling and recovery action controls
CN104866411A (en) * 2015-06-08 2015-08-26 北京奇虎科技有限公司 Monitoring and analyzing method and device for solid state disks
US20160070486A1 (en) * 2014-09-04 2016-03-10 HGST Netherlands B.V. Debug data saving in host memory on pcie solid state drive
CN105718346A (en) * 2016-01-22 2016-06-29 浪潮电子信息产业股份有限公司 Computer mainboard PCIe slot function test method based on UEFI
CN107066370A (en) * 2017-04-26 2017-08-18 郑州云海信息技术有限公司 A kind of automatic monitoring and the instrument and method for collecting faulty hard disk daily record
CN107423180A (en) * 2017-07-28 2017-12-01 郑州云海信息技术有限公司 A kind of solid state hard disc and its diagnostic method
CN107480033A (en) * 2016-06-08 2017-12-15 阿里巴巴集团控股有限公司 Virtual machine blue screen detection method and equipment

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9086965B2 (en) * 2011-12-15 2015-07-21 International Business Machines Corporation PCI express error handling and recovery action controls
CN103257912A (en) * 2012-02-16 2013-08-21 鸿富锦精密工业(深圳)有限公司 Testing device and method thereof for testing peripheral component interface express (PCIE) slot
US8954788B2 (en) * 2013-02-13 2015-02-10 Lsi Corporation Methods and structure for single root input/output virtualization enhancement in peripheral component interconnect express systems
CN104516843A (en) * 2013-09-30 2015-04-15 韩商联测股份有限公司 Non-mounted storage test device based on FPGA
US20160070486A1 (en) * 2014-09-04 2016-03-10 HGST Netherlands B.V. Debug data saving in host memory on pcie solid state drive
CN104866411A (en) * 2015-06-08 2015-08-26 北京奇虎科技有限公司 Monitoring and analyzing method and device for solid state disks
CN105718346A (en) * 2016-01-22 2016-06-29 浪潮电子信息产业股份有限公司 Computer mainboard PCIe slot function test method based on UEFI
CN107480033A (en) * 2016-06-08 2017-12-15 阿里巴巴集团控股有限公司 Virtual machine blue screen detection method and equipment
CN107066370A (en) * 2017-04-26 2017-08-18 郑州云海信息技术有限公司 A kind of automatic monitoring and the instrument and method for collecting faulty hard disk daily record
CN107423180A (en) * 2017-07-28 2017-12-01 郑州云海信息技术有限公司 A kind of solid state hard disc and its diagnostic method

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
兰高志: "《PCI总线配置空间的开发和应用》", 《计算机与网络》 *

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2022232980A1 (en) * 2021-05-06 2022-11-10 Micron Technology, Inc. Debug interface between host system and memory system
US12450007B2 (en) 2021-05-06 2025-10-21 Micron Technology, Inc. Debug interface between a host system and a memory system
CN114168073A (en) * 2021-11-18 2022-03-11 苏州浪潮智能科技有限公司 Access method and device for solid state disk debugging space
CN114237949A (en) * 2021-11-18 2022-03-25 合肥沛睿微电子股份有限公司 Debugging information access method and electronic equipment thereof
WO2023087941A1 (en) * 2021-11-18 2023-05-25 苏州浪潮智能科技有限公司 Method and apparatus for accessing debugging space of solid state disk
CN114168073B (en) * 2021-11-18 2023-08-29 苏州浪潮智能科技有限公司 Method and device for accessing debugging space of solid-state hard disk
CN115220948A (en) * 2022-07-26 2022-10-21 北京忆恒创源科技股份有限公司 Method and device for making SSD enter emergency mode and be visible by host end
WO2024109708A1 (en) * 2022-11-21 2024-05-30 苏州元脑智能科技有限公司 Method and system for wireless debugging of solid-state drives, device and storage medium

Similar Documents

Publication Publication Date Title
CN105938450B (en) Method and system for automatic debugging information collection
CN109032897A (en) Data scheduling method, host and solid state disk
CN103412769B (en) External card parameter configuration, equipment and system
CN105589776B (en) A fault location method and server
CN103218180B (en) Disk localization method and positioner
US11188407B1 (en) Obtaining computer crash analysis data
CN103455363B (en) Command processing method, device and physical host of virtual machine
US10599521B2 (en) System and method for information handling system boot status and error data capture and analysis
US10055366B2 (en) Method for data transmission and server for implementing the method
JP2016058083A (en) System and method for managing plurality of bios default setting
US10606677B2 (en) Method of retrieving debugging data in UEFI and computer system thereof
US9703937B2 (en) Method to prevent operating system digital product key activation failures
US20150149753A1 (en) Server and inspecting method thereof
CN111831389B (en) Data processing method, device and storage medium
CN117806438B (en) Control method and device of server heat dissipation device, storage medium and electronic device
JP5073799B2 (en) System and method for customizing a SCSI error response received from a SCSI target in a storage network environment
CN115373749B (en) Method and computing device for identifying PCIE terminal device
CN106030544B (en) Computer device memory detection method and computer device
CN113645056B (en) Method and system for positioning fault of intelligent network card
CN114185804B (en) Interface testing method and device and terminal equipment
CN114003535B (en) A device bandwidth configuration method, system, electronic device and storage medium
CN106776315B (en) Version detection method and device
CN115292113B (en) Fault detection method, device and electronic equipment for memory of server
US12204914B2 (en) Enhanced service operating system capabilities through embedded controller system health state tracking
CN109923846B (en) Method and device for determining hotspot address

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20181218

RJ01 Rejection of invention patent application after publication