Optical storage system, fault processing method and control device
By configuring a backup cartridge in an optical storage system and replacing a failed optical disc with the optical disc in the backup cartridge, the problem of degradation in data read and write performance caused by optical disk failure is solved, and efficient data read and write performance and fault handling is achieved.
Patent Information
- Application Number
- CN202410177921.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-02-08
- Publication Date
- 2025-08-08
AI Technical Summary
When the CD fails in the existing optical storage system, the data reading and writing performance is degraded because the optical disk needs to be removed from different optical disk cartridges for data reading and writing, resulting in an increase in delay.
Configure the backup cartridge, use the CD in the backup cartridge to replace the CD in the failed optical cartridge, and read and write data in the same optical cartridge to reduce the delay in removing the CD from different optical cartridges.
It improves the data read and write performance of optical storage systems, reduces the delay in troubleshooting, and ensures the efficiency and reliability of data read and write.
Smart Images

Figure CN120448194A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of data storage technology, and in particular to an optical storage system, a fault handling method, and a control device. Background Art
[0002] Optical storage system refers to a storage system that uses optical discs as storage media and can be used to store data persistently. Figure 1 As shown, the optical storage system may include a management server and an optical disc cabinet. The management server is used to control and manage the reading and writing of data in the optical disc cabinet. The optical disc cabinet includes a control unit, a manipulator, an optical drive, and multiple optical disc magazines, each of which contains multiple optical discs. When reading and writing data on an optical disc, the management server may issue a read / write command to the control unit; based on the read / write command, the control unit may control the manipulator to remove the optical disc from the optical disc magazine and place the optical disc in a designated optical drive. The control unit then controls the optical drive to read and write data on the optical disc and feeds back the read / write results to the management server. After completing the data reading and writing, the control unit controls the manipulator to move the optical disc back to the designated optical disc magazine.
[0003] Currently, data is usually stored in multiple optical discs in an optical disc tray based on redundant arrays of independent disks (RAID) technology. That is, some of the multiple optical discs are used to store data, and other optical discs are used to store parity bits. In this way, if an optical disc is damaged, the data or parity bits stored on other optical discs can be used to recover the data on the damaged optical disc.
[0004] However, when a damaged disc is detected, the optical disk cabinet typically uses discs from other magazines to store data. This means that the damaged disc is replaced with a disc from another magazine. This causes the data stored using RAID technology to be dispersed across different magazines. Consequently, when data is subsequently read or written, the control unit controls the robot to remove discs from different magazines, which can reduce the read and write performance of the optical storage system. Summary of the Invention
[0005] The present application provides an optical storage system to maintain a high level of data reading and writing performance of the optical storage system. In addition, the present application also provides a fault handling method, a control device, a computer-readable storage medium, and a computer program product.
[0006] In a first aspect, the present application provides an optical storage system, which includes a control device (such as a controller, etc.), a moving device (such as a robotic arm, etc.), at least one optical drive, multiple optical disc cartridges, and a spare disc cartridge; wherein the multiple optical disc cartridges include a first optical disc cartridge, the first optical disc cartridge includes at least one optical disc, the spare disc cartridge includes at least one optical disc, and the at least one optical drive includes the first optical drive; then, the control device is used to control the moving device to move the first optical disc to the spare disc cartridge when it is determined that the first optical disc in the first optical disc cartridge has a fault (such as when the first optical drive fails to write data to the first optical disc and notifies the control device that the first optical disc has a fault, etc.), and when the first optical drive successfully completes writing data to the second optical disc in the spare disc cartridge, control the moving device to move the second optical disc to the first optical disc cartridge, that is, use the optical disc in the spare disc cartridge to replace the faulty optical disc in the first optical disc cartridge.
[0007] Because the optical storage system is configured with a spare cartridge containing optical discs, and the optical storage system will use the optical disc in the spare cartridge to replace the optical disc in the first cartridge that is determined to be faulty, when the optical storage system stores data based on RAID technology, multiple optical discs storing data based on the RAID technology can be located in the same optical disc cartridge. This allows the control device to use the moving device to remove the multiple optical discs from the same optical disc cartridge for subsequent reading and writing of data, without having to remove the optical discs from different optical disc cartridges. This can reduce the time delay of removing multiple optical discs from the optical disc cartridge, thereby achieving a higher level of data reading and writing performance of the optical storage system.
[0008] In one possible embodiment, when the first optical drive successfully completes writing data to the second optical disc in the spare disc tray, the control device can also control the moving device to move the second optical disc in the spare disc tray to the first optical drive when it is determined that the first optical disc in the first optical disc tray has failed, and control the first optical drive to write data to the second optical disc, so as to replace the failed first optical disc in the first optical disc tray.
[0009] In one possible embodiment, at least one optical drive in the optical storage system further includes a second optical drive. The control device is further configured to determine that the first optical drive has failed if the first optical drive fails to write data to the second optical disc. In this manner, the control device can determine that the cause of the failure is an optical drive failure by sequentially writing data to different optical discs using the same optical drive, thereby improving the accuracy of fault diagnosis.
[0010] In one possible implementation, the control device may specifically determine that the first optical drive has failed when the first optical drive fails to write data to the second optical disc, but the second optical drive successfully writes data to the second optical disc. Thus, by using different optical drives to write data to the same optical disc, the cause of the failure can be identified as an optical drive failure based on the success or failure of the data write, thereby improving the accuracy of fault diagnosis.
[0011] In one possible embodiment, the control device may further be configured to, upon determining that the first optical drive has failed, control the moving device to move the second optical disc to the second optical drive, and control the second optical drive to write data to the second optical disc, and then, upon the second optical drive successfully completing data writing to the second optical disc, control the moving device to move the second optical disc to the first optical disc cartridge. In this manner, upon failure of the first optical disc drive, data can be written to the second optical disc using the unfailed second optical drive, and the first optical disc in the first optical disc cartridge can be replaced with the second optical disc to which data has been successfully written, thereby enabling failure recovery in the optical storage system and ensuring subsequent data read and write performance of the optical storage system.
[0012] In one possible embodiment, the control device is also used to isolate the fault of the first optical drive so as to reduce the impact of the fault of the first optical drive on the performance of storing data in the optical storage system; or, the control device is also used to output fault alarm information for the first optical drive so that the operation and maintenance personnel can perceive the fault of the first optical drive based on the fault alarm information and perform operation and maintenance on the faulty first optical drive in a timely manner.
[0013] In one possible implementation, the spare cartridge includes a hot spare cartridge and an empty cartridge. The hot spare cartridge is used to store the second disc before a first disc fails, while the empty cartridge is used to store the first disc after a first disc fails. This allows the control device to replace the failed disc in the first cartridge with the disc in the hot spare cartridge and store the failed disc in the empty cartridge. Furthermore, using different cartridges to store the new disc and the failed disc reduces the difficulty for subsequent maintenance personnel.
[0014] In one possible implementation, there are multiple hot spare cartridges or multiple empty cartridges. In this way, when some of the hot spare cartridges or some of the empty cartridges are used up, services can continue to be provided using the remaining cartridges, thereby reducing the operation and maintenance delay requirements for operation and maintenance personnel.
[0015] In one possible implementation, a spare disc cartridge includes multiple disc slots, including a first disc slot and a second disc slot. Before determining that the first disc has failed, the first disc slot stores the second disc, while the second disc slot stores no disc. After determining that the first disc has failed, the first disc slot stores no disc, while the second disc slot stores the first disc. In this way, a single spare disc cartridge can be used to both provide new discs and store failed discs, reducing the complexity of hardware design.
[0016] In one possible implementation, the control device can also be configured to count the number of optical discs removed from the spare cartridge and, when the number of optical discs removed from the spare cartridge reaches a threshold, output a prompt message, prompting the operator to replace the spare cartridge. This prompt message can prompt maintenance personnel to promptly perform maintenance on the spare cartridge, thereby ensuring the spare cartridge's corresponding fault handling function and further guaranteeing the data read and write performance of the optical storage system.
[0017] In one possible embodiment, the first optical disc cartridge includes multiple optical discs, and the multiple optical discs store data based on RAID (Redundant Array of Independent Disks) technology. Then, the control device is specifically used to control the first optical disc drive to use the data stored on other optical discs among the multiple optical discs except the first optical disc to reconstruct data for the second optical disc when it is determined that the first optical disc among the multiple optical discs has failed. In this way, the failed optical disc can be replaced with a new optical disc carrying correct data, thereby ensuring the reliability of data storage in the optical storage system.
[0018] In a second aspect, the present application provides a fault handling method, which is applied to an optical storage system. The optical storage system includes a control device, a moving device, at least one optical drive, multiple optical disc cartridges, and a spare disc cartridge. The multiple optical disc cartridges include a first optical disc cartridge, the first optical disc cartridge includes at least one optical disc, the spare disc cartridge includes at least one optical disc, and at least one optical drive includes the first optical drive. The fault handling method includes: when it is determined that a fault occurs with the first optical disc in the first optical disc cartridge, the control device controls the moving device to move the first optical disc to the spare disc cartridge; when the first optical drive successfully completes writing data to the second optical disc in the spare disc cartridge, the control device controls the moving device to move the second optical disc to the first optical disc cartridge.
[0019] In a possible implementation, when determining that the first optical disc in the first optical disc cartridge fails, the control device may control the moving device to move the second optical disc in the spare disc cartridge to the first optical drive, and control the first optical drive to write data to the second optical disc.
[0020] In a possible implementation, the at least one optical drive further includes a second optical drive, and the control device may further determine that the first optical drive has failed when the first optical drive fails to write data to the second optical disc.
[0021] In one possible implementation, when the first optical drive fails to write data to the second optical disc, the control device determines that the first optical drive has failed. Specifically, the control device determines that the first optical drive has failed when the first optical drive fails to write data to the second optical disc and the second optical drive successfully writes data to the second optical disc.
[0022] In one possible implementation, when it is determined that the first optical drive has failed, the control device can also control the moving device to move the second optical disc to the second optical drive; the control device controls the second optical drive to write data to the second optical disc; when the second optical drive successfully completes writing data to the second optical disc, the control device controls the moving device to move the second optical disc to the first optical disc cartridge.
[0023] In a possible implementation manner, the control device may further perform fault isolation for the first optical drive; or, the control device may further output fault warning information for the first optical drive.
[0024] In one possible implementation, the spare disk cartridge includes a hot spare disk cartridge and an empty disk cartridge. The hot spare disk cartridge is used to store the second optical disk before the first optical disk fails, and the empty disk cartridge is used to store the first optical disk after the first optical disk fails.
[0025] In one possible implementation, there are multiple hot spare disk cartridges, or there are multiple empty disk cartridges.
[0026] In one possible embodiment, the spare disc tray includes a plurality of disc slots, and the plurality of disc slots include a first disc slot and a second disc slot; wherein, before determining that the first disc has failed, the second disc is stored in the first disc slot, and no disc is stored in the second disc slot; after determining that the first disc has failed, no disc is stored in the first disc slot, and the first disc is stored in the second disc slot.
[0027] In one possible implementation, the control device can also count the number of optical discs taken out from the spare disc tray; when the number of optical discs taken out from the spare disc tray equals a threshold, the control device outputs a prompt message, which is used to prompt the spare disc tray to be replaced.
[0028] In one possible embodiment, the first optical disc cartridge includes multiple optical discs, and the multiple optical discs store data based on independent redundant array of disks RAID technology; then, when the control device controls the first optical disc drive to write data to the second optical disc, it can specifically be that when it is determined that the first optical disc among the multiple optical discs has failed, the control device controls the first optical disc drive to use the data stored on the other optical discs among the multiple optical discs except the first optical disc to reconstruct the data for the second optical disc.
[0029] The fault handling method provided in the second aspect corresponds to the optical storage system provided in the first aspect. Therefore, the technical effects of the fault handling method provided in the second aspect can be found in the relevant description of the technical effects of the above-mentioned first aspect or any implementation method of the first aspect, and will not be elaborated on here.
[0030] In a third aspect, the present application provides a control device comprising modules for executing the fault handling method in the second aspect or any possible implementation of the second aspect.
[0031] In a fourth aspect, the present application provides a control device, comprising a processor and a memory. The processor and the memory communicate with each other. The processor is used to execute instructions stored in the memory so that the control device executes the fault handling method in the first aspect or any one of the implementations of the first aspect. It should be noted that the memory can be integrated into the processor or can be independent of the processor. The control device may also include a bus. The processor is connected to the memory via the bus. The memory may include a readable memory and a random access memory.
[0032] In a fifth aspect, the present application provides a computer-readable storage medium, which stores instructions. When the computer-readable storage medium is run on a computing device, the computing device executes the operating steps of the fault handling method described in the above-mentioned second aspect or any implementation method of the second aspect.
[0033] In a sixth aspect, the present application provides a computer program product comprising instructions, which, when executed on a computing device, enables the computing device to execute the operating steps of the fault handling method described in the second aspect or any one of the implementations of the second aspect.
[0034] Based on the implementation methods provided in the above aspects, this application can also be further combined to provide more implementation methods. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] Figure 1 1 is a schematic structural diagram of an optical storage system;
[0036] Figure 2 A schematic structural diagram of an exemplary optical storage system provided in this application;
[0037] Figure 3 A schematic structural diagram of another exemplary optical storage system provided in this application;
[0038] Figure 4 A schematic structural diagram of another exemplary optical storage system provided in this application;
[0039] Figure 5 A schematic structural diagram of another exemplary optical storage system provided in this application;
[0040] Figure 6 A schematic structural diagram of another exemplary optical storage system provided in this application;
[0041] Figure 7 A flowchart of a troubleshooting method provided in this application;
[0042] Figure 8 A flowchart of another troubleshooting method provided for this application;
[0043] Figure 9 A schematic structural diagram of a control device provided in this application;
[0044] Figure 10 A schematic diagram of the hardware structure of a control device provided in this application. DETAILED DESCRIPTION
[0045] To make the above-mentioned objects, features, and advantages of the present application more clearly understood, various non-limiting embodiments of the embodiments of the present application will be exemplified below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present application, not all of them. Based on the embodiments in this application, all other embodiments obtained based on the above content are within the scope of protection of this application.
[0046] See also Figure 2 , is a schematic diagram of the structure of an exemplary optical storage system 20. Figure 2 As shown, the optical storage system 20 includes a control device 101, a moving device 102, an optical driver 103, an optical disc cartridge 104, an optical disc cartridge 105, and a spare disc cartridge 106. Each optical disc cartridge includes at least one optical disc slot, each of which stores at least one optical disc. The spare disc cartridge 106 may include multiple optical disc slots, some of which store optical discs (non-faulty and unused optical discs), while others (i.e., vacant optical disc slots) do not store any optical discs.
[0047] When data needs to be written to an optical disc, the control device 101 can control the moving device 102 to remove the optical disc from the optical disc magazine 104 or the optical disc magazine 105, and control the moving device 102 to move the removed optical disc to the optical drive 103. For example, the moving device 102 can be a robotic arm, or other device capable of moving an optical disc.
[0048] Then, the control device 101 can control the optical drive 103 to write new data to the optical disc, specifically, the optical drive can burn the new data on the optical disc. After the data is successfully written, the control device 101 controls the moving device 102 to move the optical disc in the optical drive 103 back to the optical disc tray 104 or the optical disc tray 105.
[0049] In practical applications, the optical storage system 20 can store data based on RAID technology. Specifically, it can utilize multiple optical discs in the same optical disc cartridge for data storage, with some of the optical discs used to store data and others used to store parity bits. In this way, if data on one of the multiple optical discs is lost, the data on the missing optical disc can be restored using the data on the other optical discs and the parity bits.
[0050] Taking the example of using multiple optical discs in optical disc magazine 104 to store data based on RAID technology, during the process of storing data on the multiple optical discs in optical disc magazine 104, control device 101 controls mobile device 102 to remove multiple optical discs from optical disc magazine 104. Furthermore, each time optical drive 103 completes writing data to one of the multiple optical discs, mobile device 102 removes the optical disc from drive 103 and inserts the next optical disc in the multiple optical discs into drive 103. This process continues in this manner until data or parity bits have been written to all of the multiple optical discs. Finally, control device 101 controls mobile device 102 to move the multiple optical discs back to the corresponding optical disc slots in optical disc magazine 104. When it is necessary to read the data stored on the multiple optical discs, a similar process can be used to complete the data reading, which will not be described in detail here.
[0051] In actual use, optical disc failures are unavoidable in optical storage system 20. For example, if optical disc a fails in optical disc magazine 104, and optical disc b in optical disc magazine 105 is used to store new data or restore data on optical disc a, multiple optical discs stored using RAID technology will be distributed across different optical disc magazines. In this case, when new data needs to be written to or data needs to be read from these multiple optical discs, control device 101 controls movement device 102 to first remove multiple optical discs (excluding optical disc a) from optical disc magazine 105, and then remove optical disc b from optical disc magazine 105. After all the optical discs required for reading or writing by optical drive 103 have been removed, control device 101 controls movement device 102 to sequentially insert multiple optical discs into optical drive 103, and control device 103 performs corresponding reading and writing operations on the inserted optical discs. However, the time taken by the mobile device 102 to remove multiple optical discs from one optical disc magazine is usually less than the time taken by the mobile device 102 to remove multiple optical discs from multiple optical disc magazines, which will reduce the efficiency of the optical storage system 20 in reading and writing data for the multiple optical discs, affecting the data reading and writing performance of the optical storage system 20.
[0052] Based on this, in the optical storage system 20 provided in this application, when the optical disc a in the optical disc cartridge 104 fails, the control device 101 controls the moving device 102 to replace the optical disc a in the optical disc cartridge 104 with the optical disc c in the spare disc cartridge 106 .
[0053] Specifically, the control device 101 controls the moving device 102 to move the optical disc a in the optical disc magazine 104 to an unused optical disc slot in the spare disc magazine 106, and controls the moving device 102 to remove the normal optical disc c stored in the spare disc magazine 106 (in actual application, the optical disc c in the spare disc magazine 106 may not store any data before being removed), and to insert the optical disc c into the optical drive 103. The control device 101 then controls the optical drive 103 to write data to the optical disc c. This data may be new data required to be stored by the optical storage system 20, or data recovered from the failed optical disc a. At the same time, the control device 101 controls the moving device 102 to move the failed optical disc a to an unused optical disc slot in the spare disc magazine 106.
[0054] In this way, multiple optical discs that store data based on RAID technology can still be located in the same optical disc cartridge (i.e., all located in optical disc cartridge 104, etc.). This allows the control device 101 to use the mobile device 102 to take out the multiple optical discs in the same optical disc cartridge for data reading and writing when reading and writing data on the multiple optical discs subsequently, without having to take out the optical discs from different optical disc cartridges. This can reduce the delay in taking out multiple optical discs from the optical disc cartridge, ensure the efficiency of the optical storage system 20 in reading and writing data for the multiple optical discs, and thus enable the data reading and writing performance of the optical storage system 20 to reach a higher level.
[0055] It is worth noting that the above Figure 2 The optical storage system 20 shown is only an example and is not intended to be limiting. The following describes several implementation examples of other optical storage systems.
[0056] Example 1, the above Figure 2 The optical storage system 20 described above is described by taking as an example a system including a spare disk cartridge 106, and the spare disk cartridge 106 including an optical disk and an empty optical disk slot. In other optical storage systems, multiple spare disk cartridges may be included, and each spare disk cartridge may have the same or similar design as the spare disk cartridge 106, which is not limited thereto. Alternatively, in Figure 2 The optical storage system 20 shown is based on Figure 3 In the optical storage system 30 shown, the optical disc cartridge 106 can be split into a hot spare cartridge 1061 and an empty cartridge 1062. The hot spare cartridge 1061 can include at least one normal optical disc that does not store data. Figure 3 The hot spare cartridge 1061 storing multiple optical discs is used as an example for description. The empty cartridge 1062 may include at least one idle optical disc slot. Figure 3 In the example, the empty cartridge 1062 includes multiple vacant optical disc slots. Thus, when a faulty optical disc is present in the optical disc cartridge 104 or the optical disc cartridge 105, the faulty optical disc can be replaced with an optical disc in the hot spare cartridge 1061, and the faulty optical disc can be stored in an vacant optical disc slot in the empty cartridge 1062.
[0057] Example 2: Figure 3 The optical storage system 30 shown is described by taking a hot spare cartridge 1061 and an empty cartridge 1062 as an example. Figure 4 The optical storage system 40 shown may include a plurality of hot spare cartridges and a plurality of empty cartridges. Figure 4 The following example illustrates a system including two hot spare cartridges (i.e., hot spare cartridge 1061 and hot spare cartridge 1063) and two empty cartridges (i.e., empty cartridge 1062 and empty cartridge 1064). Thus, when all the optical discs in a hot spare cartridge are used to replace a faulty optical disc, or all the optical disc slots in an empty cartridge are used to store optical discs, the optical storage system 40 can continue to use the optical discs in other hot spare cartridges to replace the faulty optical disc, and use the vacant optical disc slots in other empty cartridges to store the faulty optical disc. At any time before all the other hot spare cartridges and other empty cartridges are fully used, the operation and maintenance personnel can replace the used hot spare cartridges or empty cartridges, thereby increasing the delay tolerance for the operation and maintenance personnel in replacing the hot spare cartridges or empty cartridges, and thus improving the operation and maintenance personnel's experience.
[0058] Furthermore, when all the discs in the hot spare cartridge have been used to replace a faulty disc, the hot spare cartridge has multiple vacant disc slots. In this case, the optical storage system 40 can also use these disc slots as new empty cartridges. In this way, the maintenance personnel only need to replace the used empty cartridges with new hot spare cartridges, which can further reduce the maintenance operations of the maintenance personnel and improve the maintenance experience.
[0059] Example three, Figures 2 to 4 The optical storage system 30 shown is described by taking one optical drive (ie, optical drive 103) as an example. In other optical storage systems, multiple optical drives may be included, such as Figure 5 The optical storage system 50 shown in FIG. 1 may include not only an optical drive 103 but also an optical drive 107 ( Figure 5 (This description uses two optical drives as an example.) Thus, the control device 101 can simultaneously use the optical drive 103 and the optical drive 107 to read and write data from multiple optical discs in parallel, thereby improving the data read and write efficiency of the optical storage system 50. Alternatively, when the optical drive 103 fails, the control device 101 can use the optical drive 107 to take over the data read and write for all discs, thereby improving the data read and write reliability of the optical storage system 50.
[0060] Example 4, above Figures 2 to 5 In the optical storage system shown in FIG. 1 , the control device 101 can be integrated with the mobile device 102 and the like. In this case, the optical storage system can be an intelligent optical disk cabinet. In other possible implementations, Figure 2 The optical storage system 20 shown is based on Figure 6 In the optical storage system 60 shown, the control device 101 can be split into a processing unit 1011 and a control unit 1012, wherein the control unit 1012 can be integrated with the mobile device 102 and the processing unit 1011 can be deployed separately. Figure 6 As shown, the processing unit 1011 can be deployed in the management server, and the control unit 1012, the mobile device 102, the optical drive 103, the optical disc tray 104, the optical disc tray 105 and the spare disc tray 106 can be deployed in the optical disc cabinet, so that the control unit 1012 can control the mobile device 102 to move the optical disc and control the optical drive 103 to read and write data on the optical disc under the instruction of the processing unit 1011.
[0061] It is understandable that in addition to the optical storage systems described in the above examples, in actual applications, the optical storage system can also be implemented in other ways, such as combining the implementation methods of the optical storage systems in the above examples, etc., and this is not limited.
[0062] For ease of understanding, an embodiment of a fault handling method applied to an optical storage system provided by the present application is described below with reference to the accompanying drawings.
[0063] See also Figure 7 , Figure 7 A flowchart of a fault handling method provided in an embodiment of the present application, which can be applied to Figures 2 to 6 Any optical storage system shown can also be applied to other applicable optical storage systems. Figure 2 Taking the optical storage system 20 as an example, the process of the control device 101 handling optical disc failure is introduced.
[0064] in, Figure 7 The following description is made by taking the control device 101 writing data to an optical disc as an example. Figure 7 The troubleshooting methods shown may specifically include:
[0065] S701 : The control device 101 sends a control command 1 to the mobile device 102 to control the mobile device 102 to take out multiple optical discs from the optical disc cartridge 104 , and to control the mobile device 102 to place the first optical disc of the taken out optical discs into the optical drive 103 .
[0066] For example, the multiple optical discs in optical disc tray 104 can be used to store data based on RAID technology. For example, if the optical disc tray 104 contains 12 optical discs, 10 of them can be used to store data, and the remaining 2 can be used to store parity bits corresponding to the data. In this way, if the data (or parity bits) on one of the 12 optical discs is lost, the data stored on the remaining 11 optical discs and the parity bits can be used to reconstruct the data and restore the data (or parity bits) on that disc. This improves the reliability of data storage on the multiple optical discs.
[0067] In this embodiment, when data needs to be written to multiple optical discs in the optical disc magazine 104 (e.g., the control device 101 receives a data write request sent by the front-end application), the control device 101 can control the mobile device 102 to remove multiple optical discs from the optical disc magazine 104 by sending a control command 1 to the mobile device 102. Each of the multiple optical discs will be sequentially placed into the optical drive 103, so that the optical drive 103 can subsequently write corresponding data to each optical disc. For example, the control command 1 sent by the control device 101 to the mobile device 102 can include an identifier of the optical disc magazine 104 and an identifier of each of the multiple optical discs included in the optical disc magazine 104, so as to instruct the mobile device 102 which optical discs to remove from which optical disc magazine.
[0068] After taking out multiple optical discs, the mobile device 102 may only put one optical disc into the optical drive 103. In this embodiment, for the sake of distinction and description, it is assumed that the optical disc currently put into the optical drive 103 by the mobile device 102 is the first optical disc.
[0069] S702 : The control device 101 sends a control command 2 to the optical drive 103 to control the optical drive 103 to write data to a first optical disc in the optical drive 103 .
[0070] In this embodiment, after mobile device 102 places a first optical disc into optical drive 103, control device 101 can instruct optical drive 103 to write data to the first optical disc. Specifically, control device 101 can send control command 2 to optical drive 103. Control command 2 can include an operation type and an operation address. The operation type indicates a write operation to the first optical disc, and the operation address indicates the storage address of the data to be written on the first optical disc. Thus, after receiving control command 2, optical drive 103 can execute the corresponding data write process on the first optical disc.
[0071] Under normal circumstances, after the optical drive 103 completes writing data to an optical disc, the moving device 102 can remove the optical disc in the optical drive 103, select the next optical disc to be written from the removed optical discs, and insert the next optical disc into the optical drive 103. The optical drive 103 then continues writing data to the next optical disc. This process continues in this manner until the optical drive 103 completes writing data to all optical discs removed from the optical disc magazine 104.
[0072] S703 : During the process of the optical drive 103 writing data to the first optical disc, the control device 101 determines that a failure occurs in the first optical disc.
[0073] In actual application, it is unlikely that some optical discs will fail, such as some optical discs being physically damaged, which will cause errors in writing data to these optical discs by the optical drive 103. In this embodiment, the optical disc that fails is the first optical disc currently inserted into the optical drive 103.
[0074] In a specific implementation, during the process of writing data to the first optical disc, if the first optical disc fails, the optical drive 103 will fail to write data to the first optical disc. At this time, the optical drive 103 can send an error code to the control device 101, and the error code is used to indicate a data writing error. Accordingly, the control device 101 can determine that the first optical disc has failed based on the received error code, so that the control device 101 can continue to perform the following steps to replace the failed first optical disc with the optical disc in the spare disc tray 106. For the convenience of distinction and description, the new optical disc taken out of the spare disc tray 106 is referred to as the second optical disc below (in actual application, if the optical drive 103 successfully writes data to the optical disc, it can also feedback a successful write response to the control device 101).
[0075] S704: The control device 101 sends a control command 3 to the mobile device 102 to control the mobile device 102 to move the first optical disc that has failed in the optical drive 103 to an empty optical disc slot in the spare tray 106, and to put the second optical disc taken out from the spare tray 106 into the optical drive 103.
[0076] S705 : The control device 101 sends a control command 4 to the optical drive 103 to control the optical drive 103 to retry writing the data previously intended to be written into the first optical disc into the second optical disc in the optical drive 103 .
[0077] If the optical drive 103 successfully completes writing data to the second optical disc, the mobile device 101 can remove the second optical disc from the optical drive 103, select the next optical disc to be written from the multiple optical discs removed from the optical disc magazine 104, and move the optical disc to the optical drive 103 so that the optical drive 103 can continue to write data to the next optical disc. When the optical disc placed in the optical drive 103 also has a fault, the control device 101 can use a normal optical disc in the spare disc magazine 106 to replace the faulty optical disc in the optical drive 103 in a similar manner to the above-mentioned processing of the first optical disc. If the optical disc newly placed in the optical drive 103 has not failed, the optical drive 103 can write other data to the optical disc, and after the data is successfully written, the mobile device 102 switches the optical disc in the optical drive 103 to which the data is written. This process continues in this way until the optical drive 103 completes writing data to all optical discs.
[0078] 706 : After completing writing the data into the multiple optical discs, the control device 101 may send a control command 5 to the movement device 102 to control the movement device 102 to move the multiple optical discs back into the optical disc tray 104 .
[0079] The multiple optical discs moved back into the optical disc tray 104 include the second optical disc and do not include the first optical disc that has failed. In addition, the position of the second optical disc in the optical disc tray 104 may be the position of the first optical disc in the optical disc tray 104 .
[0080] Furthermore, after replacing the first optical disc with the second optical disc, if the first optical disc already stored data before the failure, the control device 101 can also recover the data on the first optical disc and write the data to the second optical disc. In a specific implementation, the control device 101 can calculate the data stored on the first optical disc based on the data stored on the other optical discs among the multiple optical discs except the first optical disc, and then the control device 101 can write the calculated data to the second optical disc via the optical drive 103.
[0081] In this way, in the process of writing data to multiple optical discs in the optical disc cartridge 104, for some optical discs that fail, the optical discs in the spare disc cartridge 106 can be replaced instead of replacing the failed optical discs with optical discs in other optical disc cartridges (i.e., the optical disc cartridge 105). This allows the multiple optical discs to be moved back to the same optical disc cartridge (i.e., the optical disc cartridge 104) after storing a copy of data using multiple optical discs, without having to be dispersed in different optical disc cartridges. This allows the control device 101 to use the moving device 102 to take out the multiple optical discs in the same optical disc cartridge for data reading and writing when subsequently reading and writing data on the multiple optical discs, without having to take out optical discs from different optical disc cartridges. This can reduce the delay in taking out multiple optical discs from the optical disc cartridge, ensure the efficiency of the optical storage system 20 in reading and writing data for the multiple optical discs, and thus enable the data reading and writing performance of the optical storage system 20 to reach a higher level.
[0082] It should be noted that this embodiment uses the example of writing data to multiple optical discs in optical disc cartridge 104 as an example. When data stored on multiple optical discs in optical disc cartridge 104 needs to be read, control device 101 can employ a similar process to that described above, using mobile device 102 and optical drive 103 to read the data from each optical disc. Furthermore, during the process of reading data stored on multiple optical discs, if optical disc 1 fails, control device 101 can also replace the failed optical disc with optical disc 2 in spare disc cartridge 106. In this case, since optical disc 1 stored data before the failure, control device 101 can restore the data on optical disc 1 when replacing the failed optical disc 1 with optical disc 2. In specific implementations, control device 101 can reconstruct the data stored on optical disc 1 based on the data on the multiple optical discs other than optical disc 1. Specifically, control device 101 can perform an XOR operation, such as performing an XOR operation, on the data stored on the other optical discs and a parity bit to calculate the data on the failed optical disc 1. The reconstructed data can then be written to optical disc 2 via optical drive 103. Then, the control device 101 can move the optical disc 2 and the remaining optical discs (excluding the optical disc 1) back to the optical disc tray 104. Similarly, during the process of reading and writing data on the multiple optical discs in the optical disc tray 105, if some of the optical discs fail, a similar method can be adopted to replace the failed optical discs with the non-faulty optical discs in the spare disc tray 106.
[0083] Furthermore, in this embodiment, data is stored on multiple optical disks based on RAID technology as an example for description. In other embodiments, data can also be stored on multiple optical disks based on other technologies, which is not limited to this.
[0084] above Figure 7 In the embodiment shown, the control device 101 is used as an example to illustrate that the optical disc fails. In actual application, in addition to the optical disc failure, the optical drive may also fail. For example, the optical drive may be damaged, resulting in errors in reading and writing data on the optical disc. Figure 8 , introduces the process of the control device 101 identifying a failure of the optical drive 103 and processing the failure.
[0085] See also Figure 8 , Figure 8 This is a flow chart of another fault handling method provided in an embodiment of the present application, which can be applied to Figures 2 to 6 Any optical storage system shown can also be applied to other applicable optical storage systems. Figure 5 Taking the optical storage system 50 as an example, the process of the control device 101 identifying and handling optical drive failures is introduced.
[0086] in, Figure 8 The following description is made by taking the control device 101 writing data to an optical disc as an example. Figure 8 The troubleshooting methods shown may specifically include:
[0087] S801 : The control device 101 sends a control command 1 to the mobile device 102 to control the mobile device 102 to take out multiple optical discs from the optical disc tray 104 , and to control the mobile device 102 to place a third optical disc among the taken out optical discs into the optical drive 103 .
[0088] S802 : The control device 101 sends a control command 2 to the optical drive 103 to control the optical drive 103 to write data to the third optical disc in the optical drive 103 .
[0089] The specific implementation process of step S801 and step S802 can be found in the above Figure 7 The description of the relevant parts of step S701 and step S702 in the illustrated embodiment is omitted here.
[0090] S803 : When the optical drive 103 fails to write data to the third optical disc, the control device 101 preliminarily determines that the third optical disc is faulty.
[0091] In actual scenarios, the optical drive 103 may fail to write data to the third optical disc due to a fault in the third optical disc, or the optical drive 103 may fail to write data to the third optical disc.
[0092] In a specific implementation, when a data write error occurs while the optical drive 103 is writing data to the third optical disc, the optical drive 103 can send error code 1 to the control device 101. Based on error code 1, the control device 101 can identify that the third optical disc has failed. In this embodiment, when a data write error occurs on an optical disc, it can be assumed that the optical disc has failed. To this end, the control device 101 can continue to perform the following steps to replace the third optical disc with the fourth optical disc in the spare disc tray 106.
[0093] S804: The control device 101 sends a control command 3 to the mobile device 102 to control the mobile device 102 to move the third optical disc that has failed in the optical drive 103 to an empty optical disc slot in the spare disc tray 106, and to put the fourth optical disc taken out from the spare disc tray 106 into the optical drive 103.
[0094] S805 : The control device 101 sends a control command 4 to the optical drive 103 to control the optical drive 103 to retry writing the data previously intended to be written to the third optical disc to the fourth optical disc in the optical drive 103 .
[0095] The specific implementation process of step S803 and step S804 can be found in the above Figure 7The description of the relevant parts of step S703 and step S704 in the illustrated embodiment is omitted here.
[0096] S806 : When the optical drive 103 fails to write data to the fourth optical disc, the control device 101 preliminarily determines that the optical drive 103 is faulty.
[0097] In a specific implementation, when the optical drive 103 writes data to the fourth optical disc and a write error occurs, the error code 2 may be sent to the control device 101 , so that the control device 101 may determine that an error exists in the data writing to the fourth optical disc based on the error code 2 .
[0098] It is understood that since the fourth optical disc in the spare disc tray 106 is usually a normal optical disc, if the optical disc in the optical drive 103 is replaced with the fourth optical disc, and a write error still occurs when the optical drive 103 writes data to the fourth optical disc, this indicates that the cause of the write error is not a failure of the third optical disc, but is likely a failure of the optical drive 103. Therefore, the control device 101 can verify whether the optical drive 103 is faulty by switching the optical drive that writes data to the fourth optical disc.
[0099] S807 : The control device 101 sends a control command 5 to the mobile device 102 to control the mobile device 102 to move the fourth optical disc in the optical drive 103 to the optical drive 107 .
[0100] S808 : The control device 101 sends a control command 6 to the optical drive 107 to control the optical drive 107 to write data to the fourth optical disc in the optical drive 107 .
[0101] S809 : When the optical drive 107 successfully writes data to the fourth optical disc, the control device 101 determines that the optical drive 103 fails.
[0102] It will be appreciated that if optical drive 107 is able to successfully write data to the fourth optical disc, this indicates that the fourth optical disc is not faulty, and the reason for the failure of optical drive 103 to write data to the fourth optical disc is generally due to a fault in optical drive 103. In this case, control device 101 can determine that optical drive 103 has failed. Furthermore, control device 101 can isolate the fault of optical drive 103, such as by adding a flag to optical drive 103 to indicate a fault. Accordingly, control device 101 can subsequently use optical drive 107, which has not been fault-isolated, to read and write data from the multiple optical discs in optical tray 104 and optical tray 105.
[0103] If the optical drive 107 still fails to write data to the fourth optical disc, since the probability of both the optical drive 103 and the optical drive 107 failing simultaneously is low, the control device 101 can instruct the moving device 102 to replace the fourth optical disc in the optical drive 107 with a new optical disc (hereinafter referred to as the fifth optical disc) in the spare disc cartridge 106, and control the optical drive 107 to write data to the fifth optical disc. If the data is successfully written to the fifth optical disc, the control device 101 can determine that the third and fourth optical discs have failed. If the data is written to the fifth optical disc cartridge, the control device 101 can determine that the optical drive 103 and the optical drive 107 have failed, or can determine that all the third through fifth optical discs have failed, etc.
[0104] In this way, the control device 101 can accurately determine whether the fault is caused by a disc fault or a disc fault by replacing the disc and the optical drive, thereby improving the accuracy of fault location. Furthermore, by accurately determining whether the optical drive 103 has a fault, the data reconstruction and data burning process performed when updating the disc in the optical drive 103 can be reduced, thereby preventing the performance of the optical storage system 50 from being degraded due to multiple data reconstructions and disc burning.
[0105] Furthermore, after determining that the optical drive 103 has failed, the control device 101 may also output fault warning information for the optical drive 103. For example, the fault warning information may be output to a human-computer interaction device (such as a display screen) so that the human-computer interaction device can present the fault warning to an operation and maintenance personnel. In this way, the operation and maintenance personnel can perform operation and maintenance on the faulty optical drive 103 in the optical storage system 50, such as repairing the optical drive 103 or replacing the optical drive 103 with a new one, etc., without limitation.
[0106] Furthermore, when all the healthy optical discs stored in the spare disc tray 106 are used to replace the faulty optical discs in the optical disc tray 104 and the optical disc tray 105 , the control device 101 may also output a prompt message to prompt the maintenance personnel to replace the spare disc tray 106 .
[0107] As an implementation example, the control device 101 can count the number of optical discs removed from the spare disc tray 106. Each optical disc removed from the spare disc tray 106 is typically used to replace a faulty optical disc in the optical disc tray 104 or the optical disc tray 105. When the counted number of optical discs removed from the spare disc tray 106 reaches a threshold, it indicates that all non-faulty optical discs stored in the spare disc tray 106 have been used up. At this point, the control device 101 can generate and output a prompt message, such as outputting the prompt message to a human-computer interaction device (such as a display screen) so that the human-computer interaction device can present the prompt message to the operation and maintenance personnel. In this way, the operation and maintenance personnel can promptly replace the spare disc tray 106 in the optical storage system 50 under the prompt of the human-computer interaction device. When a new optical disc in the optical disc tray 104 or the optical disc tray 105 fails, the control device 101 can use the optical disc in the replaced spare disc tray 106 to replace it.
[0108] It should be noted that this embodiment uses the example of writing data to multiple optical discs in optical disc tray 104 as an example. When reading data stored on multiple optical discs in optical disc tray 104, control device 101 can employ a similar process to that described above, utilizing mobile device 102 and optical drive 103 to read the data from each optical disc. Furthermore, while reading data stored on multiple optical discs, if optical disc a fails, control device 101 can replace the failed optical disc with optical disc b in spare tray 106. In this case, since optical disc a stored data before the failure, control device 101 can restore the data on optical disc a by replacing the failed optical disc 1 with optical disc b. Furthermore, if optical drive 103 encounters errors reading data stored on other optical discs while reconstructing the data on optical disc a, control device 101 can verify whether the data read failure is caused by a failed optical disc or a malfunction in optical drive 103 by replacing the optical disc that reads the data. If the optical drive 107 can successfully read the optical disc a or read the data on other optical discs, the control device 101 can determine that the optical drive 103 has failed and use the optical drive 107 to read the data on multiple optical discs removed from the optical disc magazine 104. If the optical drive 107 also fails to read the data on the optical disc a and other optical discs, the control device 101 can feedback a response of data read failure to the front-end application and output a prompt message to prompt the operation and maintenance personnel to perform manual intervention, such as to allow the operation and maintenance personnel to determine whether the cause of the failure is a disc failure or an optical drive failure.
[0109] above Figure 8In the illustrated embodiment, the control device 101 determines the faulty optical disc or optical drive by replacing the optical disc and the optical drive. In other embodiments, when data writing or reading fails, the optical drive 103 may also generate a specific type of error code based on the fault condition, with different types of error codes corresponding to different types of faults. Thus, after receiving the error code sent by the optical drive, the control device 101 can determine whether the optical disc or the optical drive is faulty based on the type of error code. This application does not limit the specific implementation method for the control device 101 to determine the cause of the fault.
[0110] and, Figure 8 In the illustrated embodiment, the control device 101 uses the example of using two optical drives to write data to the fourth optical disc respectively to determine that the optical drive 103 has failed. In other embodiments, when the control device 101 determines that the optical drive 103 has written data incorrectly to the third optical disc, it can only perform the operation of replacing the optical disc once, such as replacing the optical disc in the optical drive 103 from the third optical disc to the fourth optical disc, and when the optical drive 103 still has an error in writing data to the fourth optical disc, the control device 101 can directly determine that the optical drive 103 has failed.
[0111] It is worth noting that other reasonable step combinations that can be thought of by those skilled in the art based on the above description also fall within the scope of protection of this application. Secondly, those skilled in the art should also be familiar with that the embodiments described in the specification are all preferred embodiments, and the actions involved are not necessarily required by this application.
[0112] Combination of the above Figures 1 to 8 The optical storage system provided in the embodiment of the present application and the fault handling method based on the optical storage system are introduced. Next, with reference to the accompanying drawings, the control device provided in the embodiment of the present application is introduced from the perspective of functional modules and the perspective of hardware structure.
[0113] See also Figure 9 , which shows a structural schematic diagram of a control device. Figure 9 The control device 900 shown is applied to an optical storage system, which also includes a moving device, at least one optical drive, multiple optical disc cartridges, and a spare disc cartridge. The multiple optical disc cartridges include a first optical disc cartridge, the first optical disc cartridge includes at least one optical disc, the spare disc cartridge includes at least one optical disc, and at least one optical drive includes the first optical drive.
[0114] like Figure 9 As shown, the control device 900 includes a control module 901, and the control module 901 is used to:
[0115] When it is determined that the first optical disc in the first optical disc cartridge has a fault, controlling the moving device to move the first optical disc to a spare disc cartridge;
[0116] When the first optical disc drive successfully completes writing data to the second optical disc in the spare disc cartridge, the moving device is controlled to move the second optical disc to the first optical disc cartridge.
[0117] In a possible implementation, the control module 901 is further configured to:
[0118] When it is determined that the first optical disc in the first optical disc cartridge fails, the moving device is controlled to move the second optical disc in the spare disc cartridge to the first optical disc drive, and the first optical disc drive is controlled to write data to the second optical disc.
[0119] In a possible implementation, the at least one optical drive further includes a second optical drive, and the control device 900 further includes:
[0120] The determination module 902 is configured to determine that the first optical drive fails when the first optical drive fails to write data to the second optical disc.
[0121] In a possible implementation, the determination module 902 is specifically configured to determine that the first optical drive is faulty when the first optical drive fails to write data to the second optical disc and the second optical drive succeeds in writing data to the second optical disc.
[0122] In a possible implementation, the control module 901 is further configured to:
[0123] When it is determined that the first optical drive fails, controlling the moving device to move the second optical disc to the second optical drive;
[0124] controlling the second optical drive to write data to the second optical disc;
[0125] When the second optical disc drive successfully completes writing data to the second optical disc, the moving device is controlled to move the second optical disc to the first optical disc cartridge.
[0126] In a possible implementation, the control device 900 further includes:
[0127] A fault isolation module 903 is used to control the device to perform fault isolation on the first optical drive;
[0128] Alternatively, the control device 900 further includes: an output module 904, configured to output fault warning information for the first optical drive.
[0129] In a possible implementation, the spare disk cartridge includes a hot spare disk cartridge and an empty disk cartridge. The hot spare disk cartridge is used to store the second optical disk before the first optical disk fails, and the empty disk cartridge is used to store the first optical disk after the first optical disk fails.
[0130] In a possible implementation, there are multiple hot spare disk cartridges, or there are multiple empty disk cartridges.
[0131] In a possible implementation, the spare disc cartridge includes a plurality of optical disc slots, and the plurality of optical disc slots include a first optical disc slot and a second optical disc slot;
[0132] Before determining that the first optical disc has failed, the second optical disc is stored in the first optical disc slot and no optical disc is stored in the second optical disc slot; after determining that the first optical disc has failed, no optical disc is stored in the first optical disc slot and the first optical disc is stored in the second optical disc slot.
[0133] In a possible implementation, the control device 900 further includes an output module 904 configured to:
[0134] Count the number of discs taken out from the spare tray;
[0135] When the number of optical discs taken out from the spare disc tray is equal to a threshold, a prompt message is output, and the prompt message is used to prompt the spare disc tray to be replaced.
[0136] In one possible implementation, the first optical disc cartridge includes a plurality of optical discs, and the plurality of optical discs store data based on a redundant array of independent disks RAID technology;
[0137] Then, the control module 901 is specifically configured to: when it is determined that a first optical disc among the multiple optical discs fails, control the first optical disc drive to reconstruct data for a second optical disc using data stored on other optical discs among the multiple optical discs except the first optical disc.
[0138] because Figure 9 The control device 900 shown corresponds to the control device 101 in the above embodiments. Figure 9 The specific implementation method of the control device 900 shown and its technical effects can be found in the relevant descriptions of the above embodiments, which will not be repeated here.
[0139] Figure 10 This is a hardware structure diagram of a control device 1000 provided in this application. The control device 1000 can, for example, implement the control device 101 in the above embodiments.
[0140] like Figure 10As shown, the control device 1000 includes a processor 1001, a memory 1002, and a communication interface 1003. The processor 1001, the memory 1002, and the communication interface 1003 communicate through a bus 1004, and may also communicate through other means such as wireless transmission. The memory 1002 is used to store instructions, and the processor 1001 is used to execute the instructions stored in the memory 1002. Furthermore, the control device 1000 may also include a memory unit 1005, and the memory unit 1005 may be connected to the processor 1001, the storage medium 1002, and the communication interface 1003 through the bus 1004. The memory 1002 stores program code, and the processor 1001 may call the program code stored in the memory 1002 to perform the following operations:
[0141] When determining that a first optical disc in a first optical disc cartridge has failed, a control device controls a moving device to move the first optical disc to a spare disc cartridge; the control device belongs to an optical storage system, the optical storage system further comprising a moving device, at least one optical drive, a plurality of optical disc cartridges, and a spare disc cartridge, the plurality of optical disc cartridges including a first optical disc cartridge, the first optical disc cartridge including at least one optical disc, the spare disc cartridge including at least one optical disc, and the at least one optical drive including a first optical drive;
[0142] When the first optical drive successfully completes writing data to the second optical disc in the spare disc cartridge, the moving device is controlled to move the second optical disc to the first optical disc cartridge.
[0143] It should be understood that in this embodiment, the processor 1001 may be a CPU, or may be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs) or other programmable logic devices, discrete gate or transistor logic devices, discrete device components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc.
[0144] The memory 1002 may include a read-only memory and a random access memory, and provides instructions and data to the processor 1001. The memory 1002 may also include a nonvolatile random access memory.
[0145] The memory 1002 may be a volatile memory or a non-volatile memory, or may include both volatile and non-volatile memories. The non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), which is used as an external cache. By way of example and not limitation, many forms of RAM are available, such as static RAM (SRAM), dynamic random access memory (DRAM), synchronous DRAM (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link DRAM (SLDRAM), and direct rambus RAM (DR RAM).
[0146] The communication interface 1003 is used to communicate with other devices connected to the control device 1000. In addition to the data bus, the bus 1004 may also include a power bus, a control bus, and a status signal bus. However, for the sake of clarity, various buses are labeled as bus 1004 in the figure.
[0147] It should be understood that the control device 1000 according to the embodiment of the present application may correspond to the control device 101 in the embodiment of the present application, and may correspond to executing the method executed by the control device 101 in the embodiment of the present application. The above-mentioned and other operations and / or functions implemented by the control device 1000 are respectively for implementing the process of the method executed by the control device 101 in the above-mentioned embodiments. For the sake of brevity, they will not be repeated here.
[0148] The present application also provides a computer-readable storage medium. The computer-readable storage medium can be any available medium that can be stored by a computing device or a data storage device such as a data center that contains one or more available media. The available medium can be a magnetic medium (e.g., a floppy disk, a hard disk, a magnetic tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid-state drive). The computer-readable storage medium includes instructions that instruct the computing device to execute the above-mentioned fault handling method.
[0149] The present application also provides a computer program product. The computer program product includes one or more computer instructions. When the computer instructions are loaded and executed on a computing device, the computer program product fully or partially generates the process or function described in the present application.
[0150] The computer instructions may be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions may be transmitted from one website, computer, or data center to another website, computer, or data center via wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means.
[0151] The computer program product may be a software installation package. When any of the aforementioned fault handling methods is required, the computer program product may be downloaded and executed on a computing device.
[0152] The above embodiments can be implemented in whole or in part by software, hardware, firmware or any other combination. When implemented using software, the above embodiments can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded or executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from one website, computer, server or data center to another website, computer, server or data center via a wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) method. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that contains one or more available media sets. The available medium can be a magnetic medium (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium. The semiconductor medium can be a solid-state drive.
[0153] The terms used in the above embodiments are only for the purpose of describing specific embodiments and are not intended to limit the present application. As used in the specification and claims of this application, the singular expressions "one", "a kind of", "said", "above", "the" and "this" are intended to also include expressions such as "one or more", unless the context clearly indicates otherwise. It should also be understood that in the embodiments of the present application, "one or more" refers to one, two or more; the character " / " generally indicates that the objects associated with each other are in an "or" relationship. In the embodiments of the present application. "Simultaneously" means within the same time period, including situations at the same time. The terms "first", "second", etc. in the specification, claims and drawings of this application are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the terms used in this way can be interchangeable where appropriate, and this is merely a way of distinguishing objects with the same properties when describing them in the embodiments of the present application.
[0154] References to "one embodiment" or "some embodiments" in this specification mean that a particular feature, structure, or characteristic described in conjunction with that embodiment is included in one or more embodiments of the present application. Thus, phrases such as "in one embodiment," "in some embodiments," "in other embodiments," and "in yet other embodiments" appearing in various places in this specification do not necessarily refer to the same embodiment, but rather mean "one or more but not all embodiments," unless otherwise specifically emphasized. The terms "including," "comprising," "having," and variations thereof mean "including but not limited to," unless otherwise specifically emphasized.
[0155] The above description is merely a specific embodiment of the present application, but the scope of protection of the present application is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in the present application, and such modifications or substitutions should be included in the scope of protection of the present application. Therefore, the scope of protection of the present application should be based on the scope of protection of the claims.
Claims
1. An optical storage system, characterized in that: The optical storage system includes a control device, a moving device, at least one optical drive, a plurality of optical disc cartridges, and a spare disc cartridge, wherein the plurality of optical disc cartridges include a first optical disc cartridge, the first optical disc cartridge includes at least one optical disc, the spare disc cartridge includes at least one optical disc, and the at least one optical drive includes a first optical drive; The control device is used to control the moving device to move the first optical disc to the spare disc tray when it is determined that the first optical disc in the first optical disc tray has failed, and to control the moving device to move the second optical disc to the first optical disc tray when the first optical drive successfully completes writing data to the second optical disc in the spare disc tray.
2. The optical storage system according to claim 1, wherein: The control device is further configured to control the moving device to move the second optical disc in the spare disc tray to the first optical drive when it is determined that the first optical disc in the first optical disc tray fails, and control the first optical drive to write data to the second optical disc.
3. The optical storage system according to claim 1, wherein: The at least one optical drive further includes a second optical drive, and the control device is further configured to: When the first optical drive fails to write data to the second optical disc, it is determined that the first optical drive fails.
4. The optical storage system according to claim 3, wherein: The control device is used to: If the first optical drive fails to write data to the second optical disc and the second optical drive succeeds in writing data to the second optical disc, it is determined that the first optical drive fails.
5. The optical storage system according to claim 3 or 4, characterized in that: The control device is also used for: When it is determined that the first optical drive fails, controlling the moving device to move the second optical disc to the second optical drive; controlling the second optical drive to write data to the second optical disc; When the second optical drive successfully completes writing data to the second optical disc, the moving device is controlled to move the second optical disc to the first optical disc cartridge.
6. The optical storage system according to claim 5, characterized in that The control device is also used for: performing fault isolation on the first optical drive; Alternatively, fault warning information for the first optical drive is output.
7. The optical storage system according to any one of claims 1 to 6, characterized in that: The spare disk cartridge includes a hot spare disk cartridge and an empty disk cartridge. The hot spare disk cartridge is used to store the second optical disk before the first optical disk fails, and the empty disk cartridge is used to store the first optical disk after the first optical disk fails.
8. The optical storage system according to claim 7, wherein: There are multiple hot spare disk cartridges, or there are multiple empty disk cartridges.
9. The optical storage system according to any one of claims 1 to 8, characterized in that: The spare disc cartridge comprises a plurality of optical disc slots, wherein the plurality of optical disc slots comprises a first optical disc slot and a second optical disc slot; Before determining that the first optical disc has failed, the second optical disc is stored in the first optical disc slot, and no optical disc is stored in the second optical disc slot; after determining that the first optical disc has failed, no optical disc is stored in the first optical disc slot, and the first optical disc is stored in the second optical disc slot.
10. The optical storage system according to any one of claims 1 to 6, characterized in that: The control device is also used for: Counting the number of optical discs taken out from the spare disc tray; When the number of optical discs taken out from the spare disc tray is equal to a threshold, a prompt message is output, where the prompt message is used to prompt the spare disc tray to be replaced.
11. The optical storage system according to any one of claim 2, characterized in that: The first optical disc cartridge includes a plurality of optical discs, and the plurality of optical discs store data based on the Redundant Array of Independent Disks RAID technology; The control device is specifically used for: When it is determined that a first optical disc among the multiple optical discs fails, the first optical disc drive is controlled to reconstruct data for the second optical disc using data stored on other optical discs among the multiple optical discs except the first optical disc.
12. A fault handling method, characterized in that: The method is applied to an optical storage system, which includes a control device, a moving device, at least one optical drive, a plurality of optical disc cartridges, and a spare disc cartridge, wherein the plurality of optical disc cartridges includes a first optical disc cartridge, the first optical disc cartridge includes at least one optical disc, the spare disc cartridge includes at least one optical disc, and the at least one optical drive includes a first optical drive; The method comprises: When it is determined that the first optical disc in the first optical disc cartridge has a fault, the control device controls the moving device to move the first optical disc to the spare disc cartridge; When the first optical drive successfully completes writing data to the second optical disc in the spare disc cartridge, the control device controls the moving device to move the second optical disc to the first optical disc cartridge.
13. The method according to claim 12, characterized in that The method further comprises: When determining that the first optical disc in the first optical disc cartridge fails, the control device controls the moving device to move the second optical disc in the spare disc cartridge to the first optical drive, and controls the first optical drive to write data to the second optical disc.
14. The method according to claim 12, characterized in that The at least one optical drive further includes a second optical drive, and the method further includes: When the first optical drive fails to write data to the second optical disc, the control device determines that the first optical drive fails.
15. The method according to claim 14, characterized in that When the first optical drive fails to write data to the second optical disc, the control device determines that the first optical drive fails, including: When the first optical drive fails to write data to the second optical disc and the second optical drive succeeds in writing data to the second optical disc, the control device determines that the first optical drive fails.
16. The method according to claim 14 or 15, characterized in that The method further comprises: When it is determined that the first optical drive fails, the control device controls the moving device to move the second optical disc to the second optical drive; The control device controls the second optical drive to write data to the second optical disc; When the second optical drive successfully completes writing data to the second optical disc, the control device controls the moving device to move the second optical disc to the first optical disc cartridge.
17. The method according to claim 16, characterized in that The method further comprises: The control device performs fault isolation on the first optical drive; Alternatively, the control device outputs fault warning information for the first optical drive.
18. The method according to any one of claims 12 to 17, characterized in that The spare disk cartridge includes a hot spare disk cartridge and an empty disk cartridge. The hot spare disk cartridge is used to store the second optical disk before the first optical disk fails, and the empty disk cartridge is used to store the first optical disk after the first optical disk fails.
19. The method according to claim 18, characterized in that There are multiple hot spare disk cartridges, or there are multiple empty disk cartridges.
20. The method according to any one of claims 12 to 19, characterized in that The spare disc cartridge comprises a plurality of optical disc slots, wherein the plurality of optical disc slots comprises a first optical disc slot and a second optical disc slot; Before determining that the first optical disc has failed, the second optical disc is stored in the first optical disc slot, and no optical disc is stored in the second optical disc slot; after determining that the first optical disc has failed, no optical disc is stored in the first optical disc slot, and the first optical disc is stored in the second optical disc slot.
21. The method according to any one of claims 12 to 17, characterized in that The method further comprises: The control device counts the number of optical discs taken out from the spare disc tray; When the number of optical discs taken out from the spare disc tray is equal to a threshold, the control device outputs a prompt message, where the prompt message is used to prompt the spare disc tray to be replaced.
22. The method according to any one of claims 13, characterized in that The first optical disc cartridge includes a plurality of optical discs, and the plurality of optical discs store data based on the Redundant Array of Independent Disks RAID technology; The controlling the first optical drive to write data to the second optical disc includes: When it is determined that a first optical disc among the multiple optical discs fails, the first optical disc drive is controlled to reconstruct data for the second optical disc using data stored on other optical discs among the multiple optical discs except the first optical disc.
23. A control device, characterized in that: The control device includes a processor and a memory, and the processor is used to execute instructions stored in the memory, so that the control device executes the fault handling method according to any one of claims 12 to 22.