Information processing device and program
The information processing apparatus addresses data consistency and reliability issues in RAID systems by dynamically managing storage media roles, ensuring continuous operation and reliable backups without manual intervention.
Patent Information
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- CASIO HUMAN SYSTEMS CO LTD
- Filing Date
- 2021-09-21
- Publication Date
- 2026-07-09
- Estimated Expiration
- Not applicable · inactive patent
Smart Images

Figure 0007887152000001 
Figure 0007887152000002 
Figure 0007887152000003
Abstract
Description
Technical Field
[0001] The present invention relates to an information processing apparatus and a program.
Background Art
[0002] In a computer system, for the purpose of improving the reliability of data, a RAID (Redundant Arrays of Inexpensive Disks) system having data redundancy by a disk array system is known. The RAID system is classified into RAID 1, 5, 6, etc., each having different features. For example, RAID 1 (mirror disk) records the same data on a plurality of storage (auxiliary) media at the same time, giving redundancy to the data and improving the fault tolerance of the system. That is, it is possible to continue operation with a storage medium that can operate even when a single storage medium fails. Also, a highly reliable system can be constructed relatively easily.
[0003] The RAID system is an effective means in case of a hard failure, but when an incorrect operation is performed due to a higher-level software defect or human error, incorrect data is mirrored to a plurality of storage media as normal operation. Therefore, a backup at a timing depending on business operation is required for the RAID system.
[0004] Generally, a backup is performed on a separate storage medium (for example, an optical medium, a flash memory, a storage on a network, etc.) when the business stops. In this case, it is generally a backup only of user data such as a database, and the backup of data such as that of an OS (Operating System) depends on the RAID system.
[0005] As a system that combines RAID and backup, for example, a disk array device is known that includes two master HDDs (Hard Disk Drives) for RAID and a backup HDD, and copies (backups) data from the master HDDs to the backup HDD at predetermined set intervals, and when one of the master HDDs fails, the backup HDD takes over as the master and continues operations (see Patent Document 1). In the event of a failure, the backup HDD is used as the master at the user's instruction, and further at the user's instruction, the data stored on the backup HDD is copied to the two master HDDs to recover, and the system is restarted to rebuild (reconfigure) the two master HDDs.
[0006] Furthermore, a disk array device is known that has multiple RAID groups, each having multiple disk drives, and backs up the data from each RAID group to a corresponding partition among multiple partitions on a spare drive (see Patent Document 2). [Prior art documents] [Patent Documents]
[0007] [Patent Document 1] Japanese Patent Publication No. 2004-86756 [Patent Document 2] Japanese Patent Publication No. 2003-186630 [Overview of the project] [Problems that the invention aims to solve]
[0008] Data on a storage medium needs to be backed up in a logically consistent state, with multiple files and records maintaining consistency as a database. Furthermore, the consistency of the file system managing the files themselves (e.g., NTFS (NT File System) or FAT (File Allocation Table)) is also necessary, requiring the suppression of writes to the source storage medium. Therefore, with the disk array devices described in Patent Documents 1 and 2, continuous operations were not possible from the start to the end of the backup process; operations had to be stopped at the time of backup.
[0009] Furthermore, in the disk array device described in Patent Document 1, when one master HDD fails, the data from the backup HDD acting as the master is copied to two master HDDs in response to user instructions. However, depending on the timing of the user's instructions, the contents of the backup HDD may have already been updated, resulting in the loss of backup data acquired at predetermined intervals and making data security impossible. For this reason, in the disk array device described in Patent Document 1 and in configurations where backups are taken manually, there was a risk that the reliability of the backup data would decrease due to human error.
[0010] Furthermore, in the disk array device described in Patent Document 1, there is a period from when the backup HDD becomes the master until the RAID is reconstructed using the two master HDDs during the recovery operation, during which the configuration is not that of a RAID. Therefore, there is a period when the redundancy for the original RAID hardware is lost, resulting in reduced reliability, and the reliability of RAID (redundant data) in the event of hardware failure decreases.
[0011] The objectives of this invention are to prevent business interruptions due to backups, improve the reliability of backup data, and prevent a decrease in RAID reliability in the event of a failure. [Means for solving the problem]
[0012] To solve the above problems, the information processing apparatus of the present invention is: Shutdown of the information processing device or termination of business processing using the information processing deviceThe system comprises a determination means for determining whether or not it is the timing, and a control means, wherein the control means is determined by the determination means. The aforementioned When it is determined to be a timing issue, from multiple storage media, The aforementioned Before it is determined that it is the timing, a storage medium other than the storage medium in which the redundant data was stored is selected as the storage medium for storing the redundant data, and the determination means The aforementioned When it is determined that it is a timing, from the multiple storage media, The aforementioned Before it is determined that the timing is critical, the storage medium on which the redundant data was stored is selected as the storage medium for storing the backup data, and from the multiple storage media, The aforementioned Before it is determined that the timing is right, the control means selects a storage medium other than the storage medium in which the redundant data was stored, whose data guarantee period has expired, as the storage medium for storing the redundant data, and the control means The aforementioned After the timing When the aforementioned information processing device is started up or when the aforementioned business process is performed In the storage medium selected as the storage medium for storing the redundant data, the data of the storage medium in which the redundant data was stored is rebuilt. The aforementioned Before it is determined that it is the right timing, the storage medium selected as the storage medium for storing the backup data is, The aforementioned This is backup data from before it was determined to be a timing issue. [Effects of the Invention]
[0013] According to the present invention, it is possible to prevent business interruptions due to backups, improve the reliability of backup data, and prevent a decrease in the reliability of RAID in the event of a failure. [Brief explanation of the drawing]
[0014] [Figure 1] This diagram shows the functional configuration of a PC according to the first embodiment of the present invention. [Figure 2] This figure shows the configuration of the media table in the first embodiment. [Figure 3] This is a flowchart of the operational process. [Figure 4] It is a flowchart showing the first rebuild process. [Figure 5] It is a diagram showing the selection screen of the first embodiment. [Figure 6] It is a flowchart showing the shutdown process. [Figure 7] It is a flowchart showing the first storage medium switching process. [Figure 8] It is a diagram showing the data storage states of the storage medium of the first embodiment at multiple points in time. [Figure 9] It is a diagram showing the configuration of the medium table of the second embodiment. [Figure 10] It is a diagram showing the selection screen of the second embodiment. [Figure 11] It is a flowchart showing the second rebuild process. [Figure 12] It is a flowchart showing the second storage medium switching process. [Figure 13] It is a diagram showing the data storage states of the storage medium of the second embodiment at multiple points in time. [Figure 14] It is a diagram showing the configuration of the medium table of the third embodiment. [Figure 15] It is a flowchart showing the third storage medium switching process. [Figure 16] It is a diagram showing the data storage states of the storage medium of the third embodiment at multiple points in time. [Figure 17] It is a diagram showing the data storage states of the subsequent storage medium of FIG. 16 at multiple points in time.
Embodiments for Carrying Out the Invention
[0015] Hereinafter, the first, second, and third embodiments of the present invention will be described in detail in order with reference to the accompanying drawings. Note that, although various technically preferable limitations are imposed on the embodiments described below for carrying out the present invention, the scope of the present invention is not limited to the following embodiments and illustrated examples.
[0016] (First Embodiment) A first embodiment of the present invention will be described with reference to Figures 1 to 8. First, the device configuration of this embodiment will be described with reference to Figure 1. Figure 1 is a block diagram showing the functional configuration of the PC (Personal Computer) 100 of this embodiment.
[0017] As shown in Figure 1, the PC100 as an information processing device in this embodiment is an information processing device used in a company or the like, where an employee of the company executes any business application program (business app) to perform business processing. The business processing is processing related to any business of the company, for example, the processing of a daily task, such as the input and modification of employee information. The data stored in the PC100 (including programs and data used by the programs) is made redundant by RAID1, and the data can be backed up.
[0018] RAID is a technology that improves redundancy by combining multiple storage media, such as HDDs, to operate as a single virtual storage medium. RAID1 is a technology (mirroring) that improves redundancy by writing the same data (redundant data) to at least two storage media. In this embodiment (and other embodiments), RAID1 will be used as the RAID configuration.
[0019] The PC100 comprises a motherboard 1, an operating unit 30 as an operating means, a display unit 40, a communication unit 50, a power control unit 60, a disk array controller 70, and storage media 80, 81, 82, 83, 84.
[0020] Motherboard 1 is the main electronic circuit board used in PC100. Motherboard 1 implements a control unit 10 and a timing unit 20. The control unit 10 has a CPU (Central Processing Unit) 11 as a control means, RAM (Random Access Memory) 12 and a storage unit 13.
[0021] The CPU 11 controls various parts of the PC 100. The CPU 11 reads various programs stored in the memory unit 13, loads them into the RAM 12, and executes various processes in cooperation with the loaded programs. The RAM 12 is a volatile semiconductor memory that can read and write information, providing the CPU 11 with a work area for temporary storage of data and programs.
[0022] The memory unit 13 is a semiconductor memory capable of reading and writing information, such as flash memory, and stores various data and programs. In particular, the memory unit 13 stores an operation program for executing the operation process described later, including the IPL (Initial Program Loader), and a shutdown program for executing the shutdown process described later. The IPL is the first program to run when the PC100 as a computer is started up (booted up), and is executed before the OS (Operating System) programs stored in the memory media 80-84 are started.
[0023] The timing unit 20 is a real-time clock that measures the current date and time and outputs this current date and time information to the CPU 11.
[0024] The operation unit 30 has a keyboard with various keys and a pointing device such as a mouse that accepts position input, and accepts key input and position input from the user, and outputs the operation information to the CPU 11.
[0025] The display unit 40 has a display panel such as an LCD (Liquid Crystal Display) or an EL (Electro-Luminescence) display, and displays various display information input from the CPU 11 or the like on the display panel.
[0026] The communication unit 50 consists of a wired communication module such as USB (Universal Serial Bus) and a wireless communication module including an antenna, and transmits and receives information with external devices via wired and wireless communication. The CPU 11 can communicate with external devices via the communication unit 50.
[0027] The power control unit 60, in accordance with the control of the CPU 11, controls the supply or cessation of power to each part of the PC 100 during PC 100 operation, including power-on and shutdown, via a power supply unit (not shown) connected to a commercial power supply, battery, etc.
[0028] The disk array controller 70 has storage media 80-84 connected in an array and controls the reading and writing of data to storage media 80-84 according to the control of the CPU 11. The disk array controller 70 includes a storage unit 71. The storage unit 71 is made of semiconductor memory capable of reading and writing information, such as flash memory. The storage unit 71 stores the media table 200, which will be described later. The disk array controller 70 may be implemented on the motherboard 1. Alternatively, the storage unit 13 may include the storage unit 71.
[0029] Storage media 80 to 84 are physically independent storage media capable of reading and writing data, and each is composed of semiconductor memory such as an HDD, SSD (Solid State Drive), or flash memory. Storage media 80 to 84 store data such as the OS program, various application programs, and various data used by those programs.
[0030] The storage media 80-84 can be freely enabled or disabled as targets for data storage management in the operation and shutdown processes described later. Two of the enabled storage media function as the storage media of the RAID1 pair, while the storage media other than those of the RAID1 pair function as backup storage media for the RAID1 pair.
[0031] Here, the PC100 is configured to have five storage media 80-84, but the number of storage media is not limited to this and can be any number of three or more. Furthermore, the storage media 80-84 are not limited to being installed inside the PC100. For example, the storage media 80-84 may be configured as external devices of the PC100 and connected to the PC100 (and its CPU 11 via its disk array controller 70) via the communication unit 50.
[0032] Next, the information stored in the storage unit 71 will be described with reference to Figure 2. Figure 2 is a diagram showing the configuration of the media table 200 in this embodiment.
[0033] As shown in Figure 2, the media table 200, which is stored in the storage unit 71, is table information for managing the status of storage media 80 to 84 and is modifiable. The media table 200 has the following items: table ID 210, valid flag 220, primary 230, and standby 240.
[0034] Table ID 210 is the identification information for the storage medium under management for data storage using the media table 200. Here, Table ID 210 takes the values "0", "1", "2", and "3", and these represent the identification information for storage mediums 80, 81, 82, and 83, respectively.
[0035] The Valid Flag 220 is a configuration flag that indicates whether data storage on the storage medium corresponding to table ID 210 is enabled or disabled. If the Valid Flag 220 is enabled, it is indicated as "TRUE"; if disabled, it is indicated as "FALSE". Storage mediums with Valid Flag 220 set to "TRUE" are enabled for data storage management in the operation and shutdown processes described later, and can be included in RAID1 pairs or as backup targets. Storage mediums with Valid Flag 220 set to "FALSE" are disabled for data storage management in the operation and shutdown processes described later, and cannot be included in RAID1 pairs or as backup targets.
[0036] Furthermore, in the ascending order of the codes (80-84) of all storage media, if the valid flag 220 of a storage media with a predetermined code is set to "FALSE", then storage media with codes larger than that code will also be set to invalid (equivalent to "FALSE") as targets for data storage management. For example, in the media table 200 of Figure 2, since the valid flag 220 of storage media 83 with table ID 210 "3" is "FALSE", storage media 84 with a code larger than storage media 83 is also set to invalid as targets for data storage management, and the column with table ID 210 "4" is omitted. Here, the storage media that are valid as targets for data storage management are storage media 80-82.
[0037] Primary 230 indicates whether the storage medium corresponding to table ID 210 is a storage medium that will be read during startup (when the PC 100 is started up). Primary 230 is shown as "TRUE" if it is a storage medium that will be read during startup, and as "FALSE" if it is not a storage medium that will be read during startup. The storage medium that will be read during startup is the main storage medium (the primary storage medium of RAID1) that is basically fixed as part of a RAID1 pair of storage media (storage media that store the same redundant data to each other). Therefore, a storage medium for which Primary 230 is "FALSE" is a storage medium other than the one that will be read during startup (a standby or backup storage medium, as described later), or a storage medium for which the valid flag 220 is "FALSE". Here, it is assumed that the storage medium that will be read during startup is fixed as storage medium 80. However, when performing a normal startup using redundant data from RAID1, the primary storage medium of RAID1 remains fixed. However, when performing a backup startup (recovery startup) using backup data from the backup storage medium, the primary storage medium of RAID1 is changed.
[0038] Standby 240 indicates whether the storage medium corresponding to table ID 210 is a sub-storage medium (mirror media, or standby storage medium for RAID1) that can be paired with the primary storage medium of RAID1 where Primary 230 is "TRUE". Standby 240 is indicated as "TRUE" if it is a standby storage medium for RAID1, and as "FALSE" if it is not a standby storage medium for RAID1. The standby storage medium for RAID1 can be changed to a backup storage medium where RAID1 backup data is stored. A storage medium where Standby 240 is "FALSE" can be a primary storage medium for RAID1, a backup storage medium, or a storage medium where the valid flag 220 is "FALSE".
[0039] In summary, a storage medium with the enabled flag 220 set to "TRUE", primary 230 set to "FALSE", and standby 240 set to "TRUE" is the standby storage medium in RAID1. A storage medium with the enabled flag 220 set to "TRUE", primary 230 set to "FALSE", and standby 240 set to "FALSE" is the backup storage medium. Here, the storage medium that forms the RAID1 pair of storage medium 80, which is read at startup, will be either storage medium 81 or 82.
[0040] Next, the operation of PC100 will be explained with reference to Figures 3 to 8. Figure 3 is a flowchart of the operation process. Figure 4 is a flowchart of the first rebuild process. Figure 5 is a diagram showing the selection screen 300 of this embodiment. Figure 6 is a flowchart of the shutdown process. Figure 7 is a flowchart of the first storage medium switching process. Figure 8 is a diagram showing the data storage state of storage media 80 to 82 of the first embodiment at multiple points in time.
[0041] First, the operational process performed on PC100 will be explained with reference to Figures 3 to 5. The operational process involves starting up PC100 and putting it into a system operational state for performing business operations, as well as changing one of the storage media in the RAID1 pair to a backup storage media and performing a rebuild. It is assumed that PC100 is in a shutdown (power off) state beforehand, and that two of the storage media 80 to 84 are set to a RAID1 pair. Furthermore, the operational process in this embodiment is for the case where there are three valid storage media (storage media 80 to 82) with the validity flag 220 set to "TRUE", as described in the media table 200.
[0042] Then, in the PC100, triggered by a power-on input from the user pressing the power button, the CPU11 executes operation processing according to the operation program stored in the memory unit 13.
[0043] As shown in Figure 3, first, the CPU 11 sets a predetermined timeout (for example, 10 seconds) for the selection screen in step S12, which will be described later, and obtains the current date and time information from the timing unit 20 to start the timer count (step S11). Then, the CPU 11 generates a selection screen that accepts input from the user to choose whether or not to perform a backup startup using the backup data stored in the backup storage medium (or to perform a normal startup using the data stored in the primary storage medium of RAID1), displays it on the display unit 40, and accepts selection input from the user via the operation unit 30 (step S12).
[0044] The selection screen displayed in step S12 is, for example, the selection screen 300 shown in Figure 5. The selection screen 300 includes the message 301, "Do you want to start from the backup media (backup storage medium)?", and the user selects "Y" to start from the backup, or "N" not to start from the backup (start normally). The user can select whether to start from the backup without being aware of which storage medium is being used for the backup.
[0045] Then, CPU 11 determines whether or not backup startup was selected in step S12 (step S13). If backup startup is selected (step S13; YES), CPU 11 performs a recovery rebuild setting to set the data read destination for startup to the backup storage medium (step S14).
[0046] If backup startup is not selected (step S13; NO), the CPU 11 determines in step S12 whether normal startup was selected (step S15). If normal startup is not selected (step S15; NO), the CPU 11 obtains current date and time information from the timing unit 20 and determines whether the elapsed time corresponding to the current date and time information from the timer start in step S11 has exceeded the set time set in step S11 (step S16).
[0047] If the set time has not elapsed (step S16; NO), the process proceeds to step S12. If normal startup is selected (step S15; YES), or if the set time has elapsed (step S16; YES), the CPU 11 performs a normal rebuild setting, setting the startup data read destination to the primary storage medium of RAID1 (step S17).
[0048] After step S17, the CPU 11 performs the first rebuild process (step S18A). After step S14, the CPU 11 performs the first rebuild process (step S18B). Now, referring to Figure 4, the first rebuild process in steps S18A and S18B will be explained. As shown in Figure 4, first, the CPU 11 assigns 0 to the variables Table ID, Primary ID, and Standby ID (step S31). Table ID is a variable corresponding to Table ID 210 of media table 200. Primary ID is a variable of Table ID corresponding to the primary storage medium of RAID1. Standby ID is a variable of Table ID corresponding to the standby storage medium of RAID1.
[0049] Then, the CPU 11, via the disk array controller 70, refers to the media table 200 stored in the storage unit 71 and determines whether the valid flag 220 corresponding to the table ID 210 of the current variable is "TRUE" (step S32). If the valid flag 220 is "TRUE" (step S32; YES), the CPU 11 determines whether the primary 230 corresponding to the table ID 210 of the current variable is "TRUE" in the media table 200 referred to in step S32 (step S33).
[0050] If primary 230 is "TRUE" (step S33; YES), CPU 11 assigns the table ID of the current variable to primary ID (step S34). If primary 230 is "FALSE" (step S33; NO), CPU 11 determines whether standby 240, which corresponds to the table ID 210 of the current variable, is "TRUE" in media table 200 referenced in step S32 (step S35).
[0051] If standby 240 is "TRUE" (step S35; YES), CPU 11 assigns the current variable's table ID to standby ID (step S36). After step S34 or S36 is executed, or if standby 240 is "FALSE" (step S35; NO), CPU 11 increments the current variable's table ID by 1 (step S37) and proceeds to step S32.
[0052] If the valid flag 220 is "FALSE" (step S32; NO), the CPU 11 determines in step S17 whether or not a normal rebuild was configured (step S38). If a normal rebuild was configured (step S38; YES), the CPU 11 copies the data stored in the primary storage medium of the RAID1 corresponding to the primary ID to the storage medium corresponding to the standby ID via the disk array controller 70 (composing a RAID1 pair with the primary storage medium of the RAID1 of the primary ID and the standby storage medium of the RAID1 of the standby ID), asynchronously with the reading of boot data in step S19 (step S39), and terminates the first rebuild process.
[0053] If a normal rebuild is not configured (i.e., a recovery rebuild is configured in step S14) (step S38; NO), the CPU 11, via the disk array controller 70, sets the primary 230 of the standby ID table ID 210 to "TRUE" and the standby 240 of the standby ID table ID 210 to "FALSE" in the media table 200 stored in the storage unit 71 (step S40).
[0054] Then, the CPU 11, via the disk array controller 70, sets the primary 230 of the primary ID table ID 210 in the media table 200 stored in the storage unit 71 to "FALSE" and sets the standby 240 of the primary ID table ID 210 to "TRUE" (step S41).
[0055] Then, the CPU 11, via the disk array controller 70, copies the data stored in the backup storage medium corresponding to the standby ID to the primary storage medium of the RAID1 corresponding to the primary ID (composing a RAID1 pair with the primary storage medium of the RAID1 for the primary ID and the backup storage medium), which is done asynchronously with the reading of the boot data in step S19 (step S42), and the first rebuild process ends.
[0056] From step S39 or S42 onward, the CPU 11 manages real-time access via the disk array controller 70 to ensure that the data stored in the primary storage medium of the RAID1 with table ID 210 where primary 230 of media table 200 is "TRUE" and the standby storage medium of the RAID1 with table ID 210 where standby 240 is "TRUE" are the same data in a RAID1 pair. For example, when the CPU 11 writes predetermined data to the primary storage medium of the RAID1 via the disk array controller 70, it writes the same predetermined data to the standby storage medium of the RAID1 in parallel with the write operation.
[0057] Returning to Figure 3, the CPU 11 reads boot data from the primary storage medium of RAID1 with table ID 210 where primary 230 of media table 200 is "TRUE" via the disk array controller 70, and issues a boot (startup, startup) instruction (step S19). The boot data includes the OS program, data for initializing the PC100 devices, etc. Then, the CPU 11 uses the boot data read in step S19 to initialize the OS and the PC100 devices and starts up (starts up) the PC100 (step S20).
[0058] Then, the CPU 11 reads the business application (business application program) from the primary storage medium of RAID1 in step S19 via the disk array controller 70 and executes business processing by starting it on the OS (step S21). The CPU 11 then continues the system operation state in which it executes business processing on the OS (step S22). In the system operation state, the CPU 11 can freely accept input of business processing information from the user via the operation unit 30 and execute business processing.
[0059] Next, with reference to Figures 6 and 7, the shutdown process performed on PC100 will be explained. The shutdown process involves shutting down PC100 and modifying the media table 200 so that the RAID1 standby storage medium will be changed when PC100 is started up next time.
[0060] Assume that the PC100 is running and the system is in operation as described in step S22. While the system is in operation, if the PC100 receives a command from the user to terminate a business application, for example via the operation unit 30, the CPU11 will execute a shutdown process according to the shutdown program stored in the memory unit 13.
[0061] As shown in Figure 6, first, the CPU 11 terminates the currently running business application (step S50). Then, the CPU 11 determines whether or not it is time for a shutdown by checking whether or not a command to terminate the business application has been input from the user via the operation unit 30 (step S51). If it is not time for a shutdown (step S51; NO), the process proceeds to step S51. If it is time for a shutdown (step S51; YES), the CPU 11 performs post-processing for shutting down each operating device of the PC 100 (step S52). Then, the CPU 11 executes the first storage medium switching process (step S53).
[0062] Now, referring to Figure 7, the first storage medium switching process in step S53 will be explained. As shown in Figure 7, first, 0 is assigned to the variables Table ID, Standby ID, and Free ID (step S61). Table ID is a variable corresponding to Table ID 210 of media table 200. Standby ID is a variable of Table ID corresponding to the standby storage medium of RAID1. Free ID is a variable of Table ID corresponding to the backup storage medium.
[0063] Then, the CPU 11, via the disk array controller 70, refers to the media table 200 stored in the storage unit 71 and determines whether the valid flag 220 corresponding to the table ID 210 of the current variable is "TRUE" (step S62). If the valid flag 220 is "TRUE" (step S62; YES), the CPU 11 determines whether the primary 230 corresponding to the table ID 210 of the current variable is "TRUE" in the media table 200 referred in step S62 (step S63).
[0064] If primary 230 is "FALSE" (step S63; NO), CPU 11 determines whether standby 240, which corresponds to the table ID 210 of the current variable, is "TRUE" in the media table 200 referenced in step S62 (step S64). If standby 240 is "FALSE" (step S64; NO), CPU 11 assigns the table ID of the current variable to free ID (step S65). If standby 240 is "TRUE" (step S64; YES), CPU 11 assigns the table ID of the current variable to standby ID (step S66).
[0065] After step S65 or S66 is executed, or if primary 230 is "TRUE" (step S63; YES), CPU 11 increments the table ID of the current variable by 1 (step S67) and proceeds to step S62.
[0066] If the valid flag 220 is "FALSE" (step S62; NO), the CPU 11, via the disk array controller 70, sets the primary 230 of the standby ID table ID 210 to "FALSE" and the standby 240 of the standby ID table ID 210 to "FALSE" in the media table 200 stored in the storage unit 71 (step S68). As a result of step S68, the current standby storage medium of RAID1 is changed to the backup storage medium at the next startup.
[0067] Then, the CPU 11, via the disk array controller 70, sets the primary 230 of the free ID table ID 210 to "FALSE" and the standby 240 of the standby ID table ID 210 to "TRUE" in the media table 200 stored in the storage unit 71 (step S69), and terminates the first storage medium switching process. As a result of step S69, the current backup storage medium will be changed to the RAID1 standby storage medium at the next startup.
[0068] Returning to Figure 6, the CPU 11, under the control of the power supply control unit 60, turns off the power to the PC 100 to complete the shutdown (step S54), and terminates the shutdown process.
[0069] Next, with reference to Figure 8, specific examples of the operation process and shutdown process of this embodiment will be described.
[0070] Assume that the media table 200 shown in Figure 2 is already stored in the storage unit 71 of PC100. Then, as shown in Figure 8, assume that the startup process is executed for the first time on the first day of PC100 operation. During the startup process, normal startup is selected in step S12, normal startup is performed in steps S17, S18A, S19-S21, and the system operation state is continued in step S22. At this time, the primary storage medium 80 with table ID 210 set to "TRUE" and the standby storage medium 81 with table ID 210 set to "TRUE" are configured as a RAID1 pair, and the same redundant data is stored in them.
[0071] Storage medium 80 is the primary storage medium of RAID1, and storage medium 81 is the standby storage medium of RAID1. In Figure 8, the two storage mediums enclosed by the dotted line (represented by "○") are assumed to function as a RAID1 pair, and each point in time on the figure corresponds from oldest to newest, from top to bottom. These are the same in Figures 13, 16, and 17 of the other embodiments.
[0072] Then, at the end of the first day's business processing, the shutdown process is executed. At this time, in steps S68 and S69 of the first storage medium switching process in step S53, the standby 240 of table ID 210 (=1) of storage medium 81 in the media table 200 is changed to "FALSE", and the standby 240 of table ID 210 (=2) of storage medium 82 is changed to "TRUE". As a result, in the media table 200, the RAID1 pair for the next startup is set to storage media 80 and 82, and the data stored in storage medium 81 becomes the backup data B1 of the RAID1 at the time of this shutdown. At this point, however, the data stored in storage media 80 and 81 is essentially still the redundant data of the RAID1 pair.
[0073] Then, on the second day, the operation process is executed and normal startup is performed. In step S39 of the first rebuild process in step S18A of the operation process, the media table 200, which was changed at the end of the business process on the first day, is used to rebuild the RAID1 pair of the primary storage medium 80 in RAID1, changing the partner of the RAID1 pair from storage medium 81 to storage medium 82. As a result, the storage mediums 80 and 82, which are the RAID1 pair, store the same redundant data.
[0074] Then, at the end of the second day's business processing, the shutdown process is executed. At this time, in steps S68 and S69 of the first storage medium switching process in step S53, the standby 240 of table ID 210 (=2) of storage medium 82 in the media table 200 is changed to "FALSE", and the standby 240 of table ID 210 (=1) of storage medium 81 is changed to "TRUE". As a result, in the media table 200, the RAID1 pair for the next startup is set to storage media 80 and 81, and the data stored in storage medium 82 becomes the RAID1 backup data B2 for this shutdown.
[0075] Then, on the third day, the operation process is executed and a normal startup is performed. In this case, in step S39 of the first rebuild process in step S18 of the operation process, the media table 200, which was changed at the end of the business process on the second day, is used to rebuild the RAID1 pair of the primary storage medium 80 in RAID1, changing from storage medium 82 to storage medium 81. As a result, the backup data B1 is erased, and the storage media 80 and 81, which are the RAID1 pair, store the same redundant data.
[0076] Here, we will explain the case where the operation process is executed and a recovery startup (backup startup) is performed on the third day. In this case, the operation process selects a recovery startup in step S12, the recovery startup is performed in steps S14, S18B to S21, and the system operation state is continued in step S22. At this time, the primary storage medium of RAID1 is changed to storage medium 81, the standby storage medium of RAID1 is changed to storage medium 80, and the RAID1 backup data B1 that is substantially stored in storage medium 81 is stored in storage medium 80 and rebuilt. As a result, the RAID1 pair storage media 81 and 80 store the same redundant data based on the backup data B1, and the data stored in storage medium 82 is the same RAID1 backup data B2 from the previous shutdown.
[0077] As described above, according to this embodiment, the PC100 is equipped with a CPU 11 that determines whether or not it is time for a shutdown. When the CPU 11 determines that it is time for a shutdown, it selects from the multiple storage media 80 to 84 a storage medium other than the storage medium in which redundant data was stored before it was determined that it was time for a shutdown (for example, storage medium 81) to store the redundant data. When the CPU 11 determines that it is time for a shutdown, it selects from the multiple storage media 80 to 84 a storage medium in which redundant data was stored before it was determined that it was time for a shutdown (for example, storage medium 82) to store the backup data.
[0078] Thus, since data is constantly synchronized (redundant) as the storage medium of the RAID1 pair during continuous operation, the latest state is retained when the system shuts down, eliminating the need to manually perform backups at the end of normal business hours. Furthermore, the consistency of the file system that manages the files themselves (e.g., NTFS or FAT) is normally synchronized to the storage medium when the PC100 computer system shuts down. Therefore, since backups are not performed at shutdown, business interruptions due to backup execution can be prevented. In addition, if backup processing is performed before the user's departure time, the user needs to wait for the backup to complete, which places a heavy burden on the user. However, in this embodiment, backups are not performed at shutdown, thus reducing the user's workload and improving user convenience (for example, encouraging earlier departure times).
[0079] Furthermore, in the event of a physical failure, the storage medium that was previously disconnected from RAID1 is unrelated to the pair of storage media in the RAID1 configuration, and backup data will not be lost. The backup data from the previous shutdown is guaranteed against errors caused by higher-level software malfunctions or human error. Therefore, the reliability of backup data can be improved.
[0080] Furthermore, there is no period of time between shutdown and the next startup when there are no storage media for the RAID1 pair. This prevents a decrease in the reliability of RAID1 in the event of a failure. As a result, while maintaining the redundancy of RAID1, the time required for backup is eliminated, and the previous generation of backup data is maintained, making it easy to manage the history of the data.
[0081] Furthermore, after shutdown, the CPU 11 rebuilds the data from the storage medium (e.g., storage medium 80) where the redundant data was stored in the storage medium selected to store redundant data (e.g., storage medium 81), and before it is determined that it is a shutdown, it sets the storage medium selected to store backup data (e.g., storage medium 82) to the backup data from before it was determined that it was a shutdown (e.g., backup data B2). As a result, the data from the storage medium before the switch is automatically set to backup data at the next startup, which further improves the reliability of the backup data.
[0082] Furthermore, when the CPU 11 determines that it is time to shut down based on the media table 200, which contains current state information for the storage media 80-84, it selects a storage medium (e.g., storage medium 81) from among the multiple storage media 80-84 that does not contain redundant data stored before it is determined to be time to shut down (e.g., storage media 80, 82) as the storage medium for storing redundant data. When the CPU 11 determines that it is time to shut down based on the media table 200, it selects a storage medium (e.g., storage medium 82) from among the multiple storage media 80-84 that contains redundant data stored before it is determined to be time to shut down as the storage medium for storing backup data. This makes it easy and automatic to manage (switch) the storage media.
[0083] Furthermore, the PC100 includes an operation unit 30 that accepts input to select the data to be read from when the PC100 starts up, from a storage medium that stores redundant data (e.g., storage medium 80) and a storage medium that stores backup data from before shutdown (e.g., backup data B1) (e.g., storage medium 81). The CPU 11 reads data from the selected storage medium and performs startup. Therefore, it is possible to easily select and execute a normal startup using RAID1 redundant data and a backup startup using backup data.
[0084] (Second Embodiment) A second embodiment of the present invention will be described with reference to Figures 9 to 13. Figure 9 is a diagram showing the configuration of the media table 200A. Figure 10 is a diagram showing the selection screen 300A. Figure 11 is a flowchart of the second rebuild process. Figure 12 is a flowchart of the second storage medium switching process. Figure 13 is a diagram showing the data storage state of storage media 80 to 83 of the second embodiment at multiple time points.
[0085] The device configuration of this embodiment uses the PC100 of the first embodiment described above. However, the storage unit 71 stores the media table 200A shown in Figure 9 instead of the media table 200 of the first embodiment.
[0086] Next, with reference to Figure 9, the configuration of the media table 200A stored in the storage unit 71 will be described.
[0087] As shown in Figure 9, media table 200A has the same table ID 210, valid flag 220, primary 230, and standby 240 entries as media table 200, and a last updated date and time 250 entry.
[0088] In media table 200, the validity flag 220 was enabled ("TRUE") for storage media 80, 81, and 82 with table IDs 210 "0", "1", and "2", respectively, while the validity flag 220 was disabled ("FALSE") for storage media 83 (and storage media 84) with table ID 210 "3". In contrast, in media table 200A of this embodiment, the validity flag 220 is enabled ("TRUE") for storage media 80, 81, 82, and 83 with table IDs 210 "0", "1", "2", and "3", while the validity flag 220 is disabled ("FALSE") for storage media 84 with table ID 210 "4".
[0089] The last update timestamp 250 is the date and time information for the final (latest) update of data to the storage medium corresponding to table ID 210. Here, the last update timestamp 250 for storage mediums 80, 81, 82, and 83 with table ID 210 "0", "1", "2", and "3" respectively, for which the valid flag 220 is valid ("TRUE"), will be represented by the variables "d0", "d1", "d2", and "d3", respectively. The variables "d0", "d1", "d2", and "d3" for the last update timestamp 250 will be updated as appropriate to the date and time information of the final update in accordance with the data update to each storage medium 80, 81, 82, and 83.
[0090] Furthermore, in storage medium 84 where the valid flag 220 is invalid ("FALSE") and table ID 210 is "4", no data is stored in the first place, so the last update time 250 is set to "0".
[0091] Next, the operation of the PC100 in this embodiment will be described with reference to Figures 10 to 13.
[0092] In this embodiment as well, the operation process shown in Figure 3 and the shutdown process shown in Figure 6 are executed, similar to the first embodiment described above. However, in this embodiment, the first rebuild process in step S18B of the shutdown process is replaced with the second rebuild process shown in Figure 11, and the first storage medium switching process in step S53 of the shutdown process is replaced with the second storage medium switching process shown in Figure 12. For this reason, the explanation of the parts that are the same as the operation process and shutdown process in the first embodiment described above will be omitted, and the differences will be explained mainly.
[0093] First, the operational process performed on PC100 will be explained with reference to Figures 10 and 11. It is assumed that PC100 is initially in a shut-down (power-off) state, and that two of the storage media 80-84 are configured as a RAID1 pair. Furthermore, the operational process in this embodiment assumes that there are four valid storage media (storage media 80-83) with the validity flag 220 set to "TRUE," as described in media table 200A.
[0094] Then, in the PC100, triggered by a power-on input from the user pressing the power button, the CPU11 executes operation processing according to the operation program stored in the memory unit 13.
[0095] Steps S11 to S17, S18A, and S19 to S22 are the same as in the first embodiment. However, in step S12, the CPU 11 generates a selection screen that accepts a selection input for whether or not to perform a backup startup using backup data stored in the backup storage medium, and a selection input for which backup storage medium to use to perform the backup startup, and displays it on the display unit 40, and accepts the selection input from the user via the operation unit 30.
[0096] The selection screen displayed in step S12 is, for example, the selection screen 300A shown in Figure 10. The selection screen 300A includes message 301, in which the user selects and inputs "Y" to start the backup or "N" to not start the backup (start normally). It also includes message 302, "Which backup media (backup storage medium) do you want to restore to? (1: 2021.8.19, 2: 2021.8.18)?", in which the user selects and inputs either the first backup storage medium "1" or the second backup storage medium "2".
[0097] In the first embodiment, since there are three storage media with the valid flag 220 in the media table 200 set to "TRUE", there is one backup storage media other than the storage media in the RAID1 pair. In contrast, in this embodiment, since there are four storage media with the valid flag 220 in the media table 200A set to "TRUE", there are two backup storage media other than the storage media in the RAID1 pair. The user is given the option to select which of these two backup storage media will be used as the backup source for the backup startup.
[0098] In message 302, "1" represents the storage medium for the first backup, and "2" represents the storage medium for the second backup. The backup storage medium is the storage medium of table ID 210 in media table 200A where primary 230 and standby 240 are "FALSE". "2021.8.19" is the last modified date and time 250 corresponding to table ID 210 of the storage medium for the first backup in media table 200A. Similarly, "2021.8.18" is the last modified date and time 250 corresponding to table ID 210 of the storage medium for the second backup. Users can select and input the backup storage medium based only on the last modified date and time, without being aware of which storage medium it is.
[0099] Then, in step S18B, the CPU 11 executes a second rebuild process. The second rebuild process in step S18B will now be explained with reference to Figure 11. As shown in Figure 11, first, the CPU 11 assigns 0 to the variables Table ID and Primary ID, and assigns n to Standby ID (step S71). The Standby ID n is the Table ID 210 of the backup storage medium selected in step S12 in the media table 200A. If no selection of backup storage medium is made in step S12 (for example, if a timeout occurs due to step S16; YES), the Table ID 210 of the backup storage medium with the later last update time 250 may be automatically set.
[0100] Steps S72 to S76 are the same as steps S32 to S34, S37, and S38 of the first rebuild process in Figure 4, respectively.
[0101] If a normal rebuild is configured (step S76; YES), the CPU 11, via the disk array controller 70, copies the data stored on the primary storage medium of RAID1 corresponding to the primary ID to the storage medium corresponding to the standby ID, asynchronously with the reading of the boot data in step S19. The CPU 11 then obtains the date and time information of the copy from the timing unit 20, and updates the last update date and time 250 in the media table 200A, which corresponds to the table ID 210 of the destination storage medium, with the obtained date and time information of the copy (step S77), and terminates the second rebuild process.
[0102] Steps S78 and S79 are the same as steps S40 and S41 of the first rebuild process in Figure 4, respectively.
[0103] Then, the CPU 11, via the disk array controller 70, copies the data stored in the backup storage medium corresponding to the standby ID to the primary storage medium of RAID1 corresponding to the primary ID, asynchronously with the reading of the boot data in step S19. The CPU 11 obtains the date and time information of the copy from the timing unit 20, and updates the last update date and time 250 in the media table 200A, which corresponds to the table ID 210 of the destination storage medium, with the obtained date and time information of the copy (step S80), and finishes the second rebuild process.
[0104] Furthermore, in the first rebuild process of step S18A of the operation process, the date and time information of the copy and the last update date and time 250 are updated, similar to steps S77 and S80.
[0105] Next, with reference to Figure 12, the shutdown process performed on PC100 will be explained. It is assumed that the operation process has already been performed on PC100 and the system operation state of step S22 is continuing. While the system operation state is continuing, if a shutdown instruction is input from the user, for example via the operation unit 30, on PC100, the CPU 11 will execute the shutdown process according to the shutdown program stored in the storage unit 13.
[0106] As shown in Figure 6, steps S51 and S52 are the same as in the first embodiment. Then, in step S53, the CPU 11 executes a second storage medium switching process. The second storage medium switching process will now be described with reference to Figure 12.
[0107] As shown in Figure 12, first, the CPU 11 assigns 0 to the variables Table ID, Standby ID, Free ID, and Oldest Date and Time (step S91). The Oldest Date and Time is a variable representing the last update date and time of the storage medium with the oldest data update among all backup storage media (storage media corresponding to Table ID 210 where Primary 230 and Standby 240 in media table 200A are "FALSE").
[0108] Steps S92 to S95 are the same as steps S62 to S64 and S66 of the first storage medium switching process in Figure 7. If standby 240 is "FALSE" (step S94; NO), CPU 11 determines whether the oldest date and time is 0 or not (step S96). If the oldest date and time is 0 (step S96; YES), CPU 11 assigns the last update date and time 250, which corresponds to the table ID 210 of the current variable, to the oldest date and time (step S97).
[0109] After step S97 is executed, or if the oldest date and time is not 0 (step S96; NO), the CPU 11 determines whether the last modified date and time 250 corresponding to the current variable's table ID 210 is less than or equal to (or earlier than) the oldest date and time (step S98). If the last modified date and time 250 is earlier than the oldest date and time (step S98; YES), the CPU 11 assigns the table ID of the current variable to the free ID (step S99).
[0110] If primary 230 is "TRUE" (step S93; YES), or after step S95 or S99 has been executed, or if the last modified date and time 250 is later than the oldest date and time (step S98; NO), CPU 11 executes step S100. Steps S100 to S102 are the same as steps S67 to S69 of the first storage medium switching process in Figure 7.
[0111] Next, with reference to Figure 13, specific examples of the operation process and shutdown process of this embodiment will be described.
[0112] It is assumed that the media table 200A shown in Figure 9 is already stored in the storage unit 71 of PC100. Furthermore, it is assumed that at the last update time 250 of media table 200A, the initial setting is such that d2 of storage medium 82 (table ID 210=2) < d3 of storage medium 83 (table ID 210=3) (d2 is earlier than d3).
[0113] Then, as shown in Figure 13, the operation process is executed for the first time on the first day of operation of PC100. During the operation process, normal startup is selected in step S12, normal startup is performed in steps S18A, S19~S21, and the system operation state is continued in step S22. At this time, the primary 230 is the storage medium 80 with table ID 210 set to "TRUE", and the standby 240 is the storage medium 81 with table ID 210 set to "TRUE", configured as a RAID1 pair, and the same redundant data is stored in them. Storage medium 80 is the primary storage medium of RAID1, and storage medium 81 is the standby storage medium of RAID1.
[0114] Then, at the end of the first day's business processing, the shutdown process is executed. At this time, in step S99 of the second storage medium switching process in step S53, among the backup storage media 82 and 83, the table ID 210 (=2) of storage medium 82, which corresponds to d2 whose last update date and time 250 in media table 200A is earlier than d3, is assigned to the free ID. Then, in steps S101 and S102, the standby 240 of table ID 210 (=1) of storage medium 81 in media table 200A is changed to "FALSE", and the standby 240 of table ID 210 (=2) of storage medium 82 is changed to "TRUE", and the data stored in storage medium 81 is made into the RAID1 backup data B11 at the time of this shutdown. In media table 200A, the RAID1 pair for the next startup is set to storage media 80 and 82, but at this point, the data stored on storage media 80 and 81 is essentially still the redundant data for the RAID1 pair.
[0115] Then, on the second day, the operation process is executed and a normal startup is performed. In step S39 of the first rebuild process in step S18A of the operation process, the media table 200A, which was modified at the end of the business process on the first day, is used to rebuild the RAID1 pair of the primary storage medium 80 in RAID1, changing the partner of the RAID1 pair from storage medium 81 to storage medium 82. As a result, the storage mediums 80 and 82, which are the RAID1 pair, store the same redundant data.
[0116] Then, at the end of the business processing on the second day, the shutdown process is executed. At this time, in step S99 of the second storage medium switching process in step S53, the table ID 210 (=3) of storage medium 83, which corresponds to d3, where the last update date and time 250 of media table 200A is earlier than d1, is assigned to the free ID.
[0117] In steps S101 and S102, the standby 240 of table ID 210 (=2) of storage medium 82 in media table 200A is changed to "FALSE", and the standby 240 of table ID 210 (=3) of storage medium 83 is changed to "TRUE", and the data stored in storage medium 82 is used as the RAID1 backup data B12 for this shutdown.
[0118] Then, on the third day, the operation process is executed and a normal startup is performed. In this case, in step S39 of the first rebuild process in step S18A of the operation process, the RAID1 pair of the primary storage medium 80 of the RAID1 is rebuilt so that it changes from storage medium 82 to storage medium 83, based on the media table 200A that was changed at the end of the business process on the second day. As a result, the data stored in storage medium 81 remains as backup data B11, and the storage mediums 80 and 83, which are the RAID1 pair, store the same redundant data.
[0119] Then, at the end of the business processing on the third day, the shutdown process is executed. At this time, in step S99 of the second storage medium switching process in step S53, the table ID 210 (=1) of storage medium 81, which corresponds to d1, one of the backup storage media 81 and 82, whose last update date and time 250 in media table 200A is older than d2, is assigned to the free ID.
[0120] In steps S101 and S102, the standby 240 of table ID 210 (=3) of storage medium 83 in media table 200A is changed to "FALSE", and the standby 240 of table ID 210 (=1) of storage medium 81 is changed to "TRUE", and the data stored in storage medium 83 is used as the RAID1 backup data B13 for this shutdown.
[0121] Then, on the fourth day, the operation process is executed and a normal startup is performed. In this case, in step S39 of the first rebuild process in step S18A of the operation process, the RAID1 pair of the primary storage medium 80 of the RAID1 is rebuilt so that it changes from storage medium 83 to storage medium 81, based on the media table 200A that was changed at the end of the business process on the third day. As a result, the backup data B11 is erased, the data stored in storage medium 82 remains as backup data B12, and the storage mediums 80 and 81, which are the RAID1 pair, store the same redundant data.
[0122] As described above, according to this embodiment, when the CPU 11 determines that it is time to shut down, it selects from the multiple storage media 80 to 84, excluding the storage media (e.g., storage media 81, 82) that had redundant data stored before it was determined to be time to shut down, the storage media with the oldest last modified date (e.g., storage media 81) as the storage media for storing redundant data. Therefore, at the next startup, backup data with a more recent last modified date and a higher likelihood of being important can be retained, further improving the reliability of the backup data. In addition, if the number of storage media is increased, the number of backup data with different backup dates can be increased. For example, if the storage media of PC100 is set to a RAID1 pair of 2 drives + 7 drives, in addition to the RAID1 redundant data, 7 days' worth (1 week's worth) of backup data can be retained.
[0123] (Third embodiment) A third embodiment of the present invention will be described with reference to Figures 14 to 17. Figure 14 is a diagram showing the configuration of the media table 200B of this embodiment. Figure 15 is a flowchart showing the third storage medium switching process. Figure 16 is a diagram showing the data storage state of storage media 80 to 83 at multiple time points in the third embodiment. Figure 17 is a diagram showing the data storage state of storage media 80 to 83 at multiple time points, continuing from Figure 16.
[0124] The device configuration of this embodiment uses the PC100 of the first embodiment described above. However, the storage unit 71 stores the media table 200B shown in Figure 14 instead of the media table 200 of the first embodiment.
[0125] Next, with reference to Figure 14, the configuration of the media table 200B stored in the storage unit 71 will be described.
[0126] As shown in Figure 14, media table 200B has the same entries as media table 200A in Figure 9: table ID 210, valid flag 220, primary 230, standby 240, last modified date and time 250, and guarantee period 260.
[0127] In media table 200B, similar to media table 200A, the validity flag 220 is set to "TRUE" for storage media 80, 81, 82, and 83 with table ID 210 "0", "1", "2", and "3", while the validity flag 220 is set to "FALSE" for storage media 84 with table ID 210 "4".
[0128] The guarantee period 260 is information about the period during which data stored on the storage medium corresponding to table ID 210 is guaranteed not to be updated. Here, the guarantee period 260 for storage medium 83 of table ID 210 (=3), where the validity flag 220 is valid ("TRUE"), is represented by the variable "t3". In other words, new data updates to storage medium 83 are prohibited during the guarantee period 260 (=t3) after the data has been updated.
[0129] Here, for example, if the period for which data is guaranteed not to be updated is one month, then t3 represents the number of days in the current month minus 2. In this case, the backup data stored in the storage medium 83 corresponding to the guaranteed period 260 (=t3) will be monthly backup data.
[0130] Furthermore, storage media 80-82 are assumed to have no restrictions on the period during which new data updates are prohibited after data has been updated, and the guarantee period 260 corresponding to table ID 210 (=0-2) of storage media 80-82 is set to "0". Also, storage media 84 for table ID 210 (=4), where the valid flag 220 is invalid ("FALSE"), does not store data, so the guarantee period 260 corresponding to table ID 210 (=4) of storage media 84 is set to "0".
[0131] Next, the operation of the PC100 in this embodiment will be described with reference to Figures 15 to 17.
[0132] In this embodiment as well, the operation process shown in Figure 3 and the shutdown process shown in Figure 6 are executed, similar to the first embodiment described above. However, in this embodiment, similar to the second embodiment, the first rebuild process in step S18B of the shutdown process is replaced with the second rebuild process shown in Figure 11. Also, the first storage medium switching process in step S53 of the shutdown process is replaced with the third storage medium switching process shown in Figure 15. For this reason, the explanation of the parts that are the same as the operation process and shutdown process in the first and second embodiments described above will be omitted, and the differences will be explained mainly.
[0133] First, the operation process performed on PC100 is the same as in the second embodiment. Next, the shutdown process performed on PC100 will be described with reference to Figure 15. Assume that the operation process has already been performed on PC100 and the system operation state of step S22 is continuing. While the system operation state is continuing, if a shutdown instruction is input from the user, for example via the operation unit 30, on PC100, the CPU 11 will execute the shutdown process according to the shutdown program stored in the storage unit 13.
[0134] As shown in Figure 6, steps S51 and S52 are the same as in the first embodiment. Then, in step S53, the CPU 11 executes a third storage medium switching process. The third storage medium switching process will now be described with reference to Figure 15.
[0135] As shown in Figure 15, steps S111 to S118 are the same as steps S91 to S98 of the second storage medium switching process in Figure 12. If the last update date and time 250 is earlier than the oldest date and time (step S118; YES), the CPU 11 obtains the current date and time information from the timekeeping unit 20 and determines whether the guarantee period 260 corresponding to the current variable's table ID 210 is less than (current date and time information - (the last update date and time 250 corresponding to the current variable's table ID 210) (step S119). In other words, in step S119, it is determined whether the period from the last data update to the current date and time in the backup storage medium for the current variable's table ID 210 is longer than the guarantee period 260.
[0136] If the guarantee period 260 is less than (current date and time information - last updated date and time 250) (step S119; YES), the CPU 11 assigns the table ID of the current variable to the free ID (step S120). If the primary 230 is "TRUE" (step S113; YES), or after the execution of step S115 or S120, or if the last updated date and time 250 is later than or equal to the oldest date and time (step S118; NO), or if the guarantee period 260 is greater than or equal to (current date and time information - last updated date and time 250) (step S119; NO), the CPU 11 executes step S100. Steps S121 to S123 are the same as steps S100 to S102 of the second storage medium switching process in Figure 12.
[0137] Next, with reference to Figures 16 and 17, specific examples of the operation and shutdown processes of this embodiment will be described.
[0138] It is assumed that the media table 200B shown in Figure 13 is already stored in the storage unit 71 of PC100. Furthermore, it is assumed that the initial settings are such that, at the last update time 250 of media table 200B, d2 of storage medium 82 (table ID 210=2) < d3 of storage medium 83 (table ID 210=3) (d2 is earlier than d3), and d3 is the last day of the previous month. In addition, it is assumed that the operation and shutdown processes are executed daily.
[0139] Then, as shown in Figure 16, the operation process is executed for the first time on the first day of operation of PC100 (the beginning of the month). During the operation process, normal startup is selected in step S12, normal startup is performed in steps S18A, S19~S21, and the system operation state is continued in step S22. At this time, the primary 230 is the storage medium 80 with table ID 210 set to "TRUE", and the standby 240 is the storage medium 81 with table ID 210 set to "TRUE", configured as a RAID1 pair, and the same redundant data is stored in them. Storage medium 80 is the primary storage medium of RAID1, and storage medium 81 is the standby storage medium of RAID1.
[0140] Then, at the end of the first day's business processing, the shutdown process is executed. At this time, in step S120 of the third storage medium switching process in step S53, among the backup storage media 82 and 83, the table ID 210 (=2) of storage medium 82, which corresponds to d2 whose last update date and time 250 in media table 200B is earlier than d3, is assigned to the free ID. Then, in steps S122 and S123, the standby 240 of table ID 210 (=1) of storage medium 81 in media table 200B is changed to "FALSE", and the standby 240 of table ID 210 (=2) of storage medium 82 is changed to "TRUE", and the data stored in storage medium 81 becomes the RAID1 backup data B21 at the time of this shutdown. In media table 200B, the RAID1 pair for the next startup is set to storage media 80 and 82, but at this point, the data stored on storage media 80 and 81 is essentially still the redundant data for the RAID1 pair.
[0141] Then, on the second day, the operation process is executed and normal startup is performed. In step S39 of the first rebuild process in step S18A of the operation process, the media table 200B, which was changed at the end of the business process on the first day, is used to rebuild the RAID1 pair of the primary storage medium 80 in RAID1, changing from storage medium 81 to storage medium 82. As a result, the storage mediums 80 and 82, which are the RAID1 pair, store the same redundant data.
[0142] Then, at the end of the business processing on the second day, the shutdown process is executed. At this time, in step S120 of the third storage medium switching process in step S53, the table ID 210 (=1) of storage medium 81, which corresponds to d1 (not d3) among the backup storage media 81 and 83, where the period from the last update date and time 250 of media table 200B to the current date and time information is not longer than the guarantee period 260 (=t3), is assigned to the free ID.
[0143] In steps S122 and S123, the standby 240 of table ID 210 (=2) of storage medium 82 in media table 200B is changed to "FALSE", and the standby 240 of table ID 210 (=1) of storage medium 81 is changed to "TRUE", and the data stored in storage medium 82 is made into the RAID1 backup data B22 for this shutdown.
[0144] Then, on the third day, the operation process is executed and a normal startup is performed. In this case, in step S39 of the first rebuild process in step S18A of the operation process, the media table 200B, which was changed at the end of the business process on the second day, is used to rebuild the RAID1 pair of the primary storage medium 80 from storage medium 82 to storage medium 81. As a result, the daily backup data B21 is erased, and the storage media 80 and 81, which are the RAID1 pair, store the same redundant data.
[0145] Then, at the end of the business processing on the third day, the shutdown process is executed. At this time, in step S120 of the third storage medium switching process in step S53, the table ID 210 (=2) of storage medium 82, which corresponds to d2 (not d3) among the backup storage media 82 and 83, where the period from the last update date and time 250 of media table 200B to the current date and time information is not longer than the guarantee period 260 (=t3), is assigned to the free ID.
[0146] In steps S122 and S123, the standby 240 of table ID 210 (=1) of storage medium 81 in media table 200B is changed to "FALSE", and the standby 240 of table ID 210 (=2) of storage medium 82 is changed to "TRUE", and the data stored in storage medium 81 is used as the RAID1 backup data B23 for this shutdown.
[0147] Similarly, let's assume that the system has progressed to the day before the end of the month. Let's assume that on the day before the end of the month, the operational process is executed and a normal startup is performed. In this case, in step S39 of the first rebuild process in step S18A of the operational process, the RAID1 pair of the primary storage medium 80 of the RAID1 is rebuilt so that it changes from storage medium 82 to storage medium 81, using the media table 200B that was changed at the end of the business process two days before the end of the month. As a result, the storage mediums 80 and 81, which are the RAID1 pair, store the same redundant data, and the data stored in storage medium 82 is stored as the daily backup data B24 of the RAID1 from the previous shutdown.
[0148] Then, at the end of business processing one day before the end of the month, the shutdown process is executed. At this time, in step S120 of the third storage medium switching process in step S53, among the backup storage media 82 and 83, the table ID 210 (=3) of storage medium 83 that corresponds to d3 prior to d2, and whose current date and time information period from the last update date and time 250 of media table 200B is longer than the guarantee period 260 (=t3), is assigned to the free ID.
[0149] In steps S122 and S123, the standby 240 of table ID 210 (=1) of storage medium 81 in media table 200B is changed to "FALSE", and the standby 240 of table ID 210 (=3) of storage medium 83 is changed to "TRUE", and the data stored in storage medium 81 is used as the RAID1 daily backup data B25 for this shutdown.
[0150] Then, as shown in Figure 17, let's assume that the operational process is executed and a normal startup is performed at the end of the month. In this case, in step S39 of the first rebuild process in step S18A of the operational process, the media table 200B, which was changed at the end of the business process one day before the end of the month, is used to rebuild the RAID1 pair of the primary storage medium 80 from storage medium 81 to storage medium 83. As a result, the storage media 80 and 83, which are the RAID1 pair, store the same redundant data.
[0151] Then, at the end of the month when business processing is completed, the shutdown process is executed. At this time, in step S120 of the third storage medium switching process in step S53, the table ID 210 (=2) of storage medium 82, which corresponds to d2 earlier than d1 of the last update date and time 250 in the media table 200B, is assigned to the free ID.
[0152] In steps S122 and S123, the standby 240 of table ID 210 (=3) of storage medium 83 in media table 200B is changed to "FALSE", and the standby 240 of table ID 210 (=2) of storage medium 82 is changed to "TRUE", and the data stored in storage medium 83 is used as the monthly backup data B26 for RAID1 during this shutdown.
[0153] Then, on the first day of the month, the operational process is executed and a normal startup is performed. In this case, in step S39 of the first rebuild process in step S18A of the operational process, the media table 200B, which was changed at the end of the business process at the end of the month, is used to rebuild the RAID1 pair of the primary storage medium 80 from storage medium 83 to storage medium 82. As a result, the data stored in storage medium 81 remains as the daily backup data B25, and the RAID1 pair storage media 80 and 82 store the same redundant data.
[0154] Then, at the end of business processing on the first day of the month, the shutdown process is executed. At this time, in step S120 of the third storage medium switching process in step S53, the table ID 210 (=1) of storage medium 81, which corresponds to d1 (not d3) among the backup storage media 81 and 83, where the period from the last update date and time 250 of media table 200B to the current date and time information is not longer than the guarantee period 260 (=t3), is assigned to the free ID.
[0155] In steps S122 and S123, the standby 240 of table ID 210 (=2) of storage medium 82 in media table 200B is changed to "FALSE", and the standby 240 of table ID 210 (=1) of storage medium 81 is changed to "TRUE", and the data stored in storage medium 82 is made into the RAID1 daily backup data B27 at the time of this shutdown.
[0156] Then, on the second day of the month, the operational process is executed and a normal startup is performed. In this case, in step S39 of the first rebuild process in step S18A of the operational process, the media table 200B, which was changed at the end of the business process at the end of the month, is used to rebuild the RAID1 pair of the primary storage medium 80 from storage medium 82 to storage medium 81. As a result, the data stored in storage medium 83 remains the monthly backup data B26, and the RAID1 pair of storage media 80 and 81 stores the same redundant data.
[0157] Then, at the end of business processing on the second day of the month, the shutdown process is executed. At this time, in step S120 of the third storage medium switching process in step S53, the table ID 210 (=2) of storage medium 82, which corresponds to d2 (not d3) among the backup storage media 82 and 83, where the period from the last update date and time 250 of media table 200B to the current date and time information is not longer than the guarantee period 260 (=t3), is assigned to the free ID.
[0158] In steps S122 and S123, the standby 240 of table ID 210 (=1) of storage medium 81 in media table 200B is changed to "FALSE", and the standby 240 of table ID 210 (=2) of storage medium 82 is changed to "TRUE", and the data stored in storage medium 81 is used as the RAID1 daily backup data B28 for this shutdown.
[0159] As described above, according to this embodiment, when the CPU 11 determines that it is time to shut down, it selects from among the multiple storage media 80 to 84, a storage medium other than the storage medium (e.g., storage media 82, 83) where redundant data was stored before it was determined that it was time to shut down (e.g., storage media 80, 81), that has had its data guarantee period expired (e.g., storage medium 83), as the storage medium for storing redundant data. Therefore, it retains backup data whose guarantee period has not expired (e.g., monthly backup data), and can retain backup data for any guarantee period.
[0160] The above description discloses an example in which ROM 73 is used as a computer-readable medium for the program according to the present invention, but the invention is not limited to this example. Other computer-readable mediums that can be used include flash memory and portable recording media such as CD-ROMs. Furthermore, a carrier wave can also be used as a medium for providing the program data according to the present invention via a communication line.
[0161] The above description of the embodiment is merely an example of the information processing device and program according to the present invention, and is not limited thereto.
[0162] For example, in the above embodiment, the storage medium 80 is always configured to be the primary storage medium of RAID1 when a normal startup is performed, but the system is not limited to this, and the primary storage medium of RAID1 may be changed as appropriate even during a normal startup.
[0163] Furthermore, in the above embodiment, the configuration is such that the RAID1 pair storage media and the backup storage media are switched at a certain timing, such as when the PC100 is shut down, but the system is not limited to this. For example, the configuration may be such that the RAID1 pair storage media and the backup storage media are switched at a certain timing, such as when business processing is completed, when the information processing device (PC100) is started up, or at a timing desired by the user (for example, a timing set by the user through operation input).
[0164] Furthermore, while the above embodiment uses a configuration with two (a pair) RAID1 storage media for storing redundant data, it is not limited to this. For example, a configuration with a group of three or more RAID1 storage media for storing redundant data is also possible.
[0165] Although embodiments of the present invention have been described, the scope of the present invention is not limited to the embodiments described above, but includes the scope of the invention as described in the claims and its equivalents. The invention described in the claims initially attached to the application for this patent is listed below. The claim numbers listed below are the same as those in the claims initially attached to the application for this patent. [Note] <Claim 1> A means for determining whether or not a certain timing is occurring, Control means and Equipped with, The control means is When the determination means determines that a certain timing has occurred, a storage medium other than the storage medium in which redundant data was stored before the determination of the certain timing is selected from among the multiple storage media to be used as the storage medium for storing the redundant data. When the determination means determines that a certain timing has occurred, the storage medium in which the redundant data was stored before the determination of the certain timing is selected from the plurality of storage media as the storage medium for storing the backup data. Information processing device. <Claim 2> The control means is After a certain timing, in the storage medium selected as the storage medium for storing the redundant data, the data of the storage medium in which the redundant data was stored is rebuilt. The information processing apparatus according to claim 1, wherein the storage medium selected as a storage medium for storing the backup data before it is determined that a certain timing has occurred is used to store the backup data from before the determination of a certain timing. <Claim 3> The control means is The information processing apparatus according to claim 1 or 2, wherein when the determination means determines that a certain timing has occurred, the information processing apparatus selects from the plurality of storage media, excluding the storage media in which the redundant data was stored before the determination of the certain timing occurred, the storage media with the oldest last update date and time, as the storage media for storing the redundant data. <Claim 4> The control means is The information processing apparatus according to any one of claims 1 to 3, wherein when the determination means determines that a certain timing has occurred, the apparatus selects from the plurality of storage media, other than the storage media in which the redundant data was stored before the determination of the certain timing occurred, a storage media whose data guarantee period has expired, as the storage media for storing the redundant data. <Claim 5> The control means is Based on the current state information of the plurality of storage media, when the determination means determines that a certain timing has occurred, a storage medium other than the storage medium in which redundant data was stored before the determination of the certain timing is selected from the plurality of storage media as the storage medium for storing the redundant data. An information processing apparatus according to any one of claims 1 to 4, wherein, based on the current state information of the plurality of storage media, when the determination means determines that a certain timing has occurred, the storage media in which the redundant data was stored before the determination of the certain timing was made is selected from the plurality of storage media as the storage media for storing the backup data. <Claim 6> The information processing device is equipped with an operating means that accepts input for selecting the data to be read from a storage medium that stores redundant data and a storage medium that stores backup data from a certain point in time, when the information processing device is started up. The information processing apparatus according to any one of claims 1 to 5, wherein the control means reads data from the selected input storage medium and starts up the information processing apparatus. <Claim 7> Computers, A means for determining whether or not a certain timing is occurring. To function as a control mechanism, The control means is When the determination means determines that a certain timing has occurred, a storage medium other than the storage medium in which redundant data was stored before the determination of the certain timing is selected from among the multiple storage media to be used as the storage medium for storing the redundant data. A program that, when the determination means determines that a certain timing has occurred, selects from the plurality of storage media the storage medium in which the redundant data was stored before the determination of the certain timing occurred, as the storage medium for storing backup data. [Explanation of Symbols]
[0166] 100 PC 1 Motherboard 10 Control Unit 11 CPU 12 RAM 13 Storage section 20 Timing section 30 Control section 40 Display section 50 Communications Department 60 Power supply control unit 70 Disk Array Controllers 71 Memory section 80,81,82,83,84 Storage medium
Claims
1. A determination means for determining whether or not it is time to shut down an information processing device or to terminate a business process using the information processing device, Control means and Equipped with, The control means is When the aforementioned determination means determines that the timing is such, a storage medium other than the storage medium in which redundant data was stored before the determination that the timing is such is selected from among the multiple storage media to be used as the storage medium for storing the redundant data. When the determination means determines that the timing is such, the storage medium in which the redundant data was stored before the determination that the timing is such is selected from the plurality of storage media as the storage medium for storing the backup data. From the aforementioned plurality of storage media, a storage medium other than the storage medium in which the redundant data was stored before the timing was determined to have occurred, whose data guarantee period has expired, is selected as the storage medium for storing the redundant data. The control means is When the information processing device is started up or when the business process is performed after the aforementioned timing, the data in the storage medium selected as the storage medium for storing the redundant data is rebuilt in the storage medium in which the redundant data was stored. An information processing device that, before it is determined that the aforementioned timing has occurred, uses the storage medium selected as the storage medium for storing the backup data as the backup data from before it was determined that the aforementioned timing has occurred.
2. The control means is The information processing apparatus according to claim 1, wherein when the determination means determines that the timing is such, the information processing apparatus selects from the plurality of storage media, excluding the storage media in which the redundant data was stored before the determination that the timing is such, the storage media with the oldest last update time, as the storage media for storing the redundant data.
3. The control means is Based on the current state information of the plurality of storage media, when the determination means determines that the timing is met, a storage medium other than the storage medium in which redundant data was stored before the determination that the timing is met is selected from the plurality of storage media as the storage medium for storing the redundant data. The information processing apparatus according to claim 1 or 2, wherein, based on the current state information of the plurality of storage media, when the determination means determines that the timing is such, the storage medium in which the redundant data was stored before the determination that the timing is such is selected from the plurality of storage media as the storage medium for storing the backup data.
4. The information processing device includes an operating means for receiving input to select the data to be read from a storage medium that stores redundant data and a storage medium that stores backup data from a previous timing, when the information processing device is started up. The information processing apparatus according to any one of claims 1 to 3, wherein the control means reads data from the selected input storage medium and starts up the information processing apparatus.
5. Computers, A determination means for determining whether it is time to shut down an information processing device or to terminate a business process using the information processing device. To function as a control mechanism, The control means is When the aforementioned determination means determines that the timing is such, a storage medium other than the storage medium in which redundant data was stored before the determination that the timing is such is selected from among the multiple storage media to be used as the storage medium for storing the redundant data. When the determination means determines that the timing is such, the storage medium in which the redundant data was stored before the determination that the timing is such is selected from the plurality of storage media as the storage medium for storing the backup data. From the aforementioned plurality of storage media, a storage medium other than the storage medium in which the redundant data was stored before the timing was determined to have occurred, whose data guarantee period has expired, is selected as the storage medium for storing the redundant data. The control means is When the information processing device is started up or when the business process is performed after the aforementioned timing, the data in the storage medium selected as the storage medium for storing the redundant data is rebuilt in the storage medium in which the redundant data was stored. A program that, before it is determined that the aforementioned timing has occurred, sets the storage medium selected as the storage medium for storing the backup data to the backup data from before it was determined that the aforementioned timing had occurred.