WO2015162717A1 - 計算機 - Google Patents
計算機 Download PDFInfo
- Publication number
- WO2015162717A1 WO2015162717A1 PCT/JP2014/061394 JP2014061394W WO2015162717A1 WO 2015162717 A1 WO2015162717 A1 WO 2015162717A1 JP 2014061394 W JP2014061394 W JP 2014061394W WO 2015162717 A1 WO2015162717 A1 WO 2015162717A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- data
- database
- management unit
- flag
- record
- Prior art date
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/14—Error detection or correction of the data by redundancy in operation
- G06F11/1402—Saving, restoring, recovering or retrying
- G06F11/1446—Point-in-time backing up or restoration of persistent data
- G06F11/1458—Management of the backup or restore process
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F12/00—Accessing, addressing or allocating within memory systems or architectures
- G06F12/02—Addressing or allocation; Relocation
- G06F12/08—Addressing or allocation; Relocation in hierarchically structured memory systems, e.g. virtual memory systems
- G06F12/0802—Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches
- G06F12/0875—Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches with dedicated cache, e.g. instruction or stack
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/21—Design, administration or maintenance of databases
- G06F16/215—Improving data quality; Data cleansing, e.g. de-duplication, removing invalid entries or correcting typographical errors
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/23—Updating
- G06F16/2308—Concurrency control
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/23—Updating
- G06F16/2379—Updates performed during online database operations; commit processing
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0602—Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
- G06F3/061—Improving I/O performance
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0628—Interfaces specially adapted for storage systems making use of a particular technique
- G06F3/0655—Vertical data movement, i.e. input-output transfer; data movement between one or more hosts and one or more storage devices
- G06F3/0656—Data buffering arrangements
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/06—Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
- G06F3/0601—Interfaces specially adapted for storage systems
- G06F3/0668—Interfaces specially adapted for storage systems adopting a particular infrastructure
- G06F3/0671—In-line storage system
- G06F3/0683—Plurality of storage devices
- G06F3/0685—Hybrid storage combining heterogeneous device types, e.g. hierarchical storage, hybrid arrays
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F2212/00—Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
- G06F2212/60—Details of cache memory
Definitions
- the present invention relates to management of data consistency in a database system.
- the database is constructed on a low-speed storage medium such as an HDD (Hard Disk Drive). Therefore, the access speed to the database is slow and the processing speed cannot be increased.
- HDD Hard Disk Drive
- a processing unit that executes processing using a database temporarily stores data in a buffer provided on a volatile main memory, and is asynchronous with processing using the database.
- a technique for perpetuating (commiting) the processing result is known (for example, see Patent Document 1).
- the processor reads data into a cache memory included in the processor to increase the processing speed, and executes processing using the read data.
- the processor writes data stored in the cache memory at a predetermined timing to the nonvolatile storage medium.
- the processor In the case of a system using the write-through method, the processor writes the same data to the cache memory and the nonvolatile storage medium at the same time. On the other hand, in the case of a system using the write-back method, the processor writes data only to the cache memory. The write data is written to the main memory asynchronously from the cache memory.
- a general processor often uses a write-back method.
- the program executed by the processor does not distinguish whether the data is written to the cache memory or the main memory, and designates a certain logical address on the memory to execute the data writing process.
- the processing for reflecting the data written in the cache memory by the processor in the main memory is processed in the background separately from the operation of the program described above, using the hardware function on the system side.
- a typical example of the invention disclosed in the present application is as follows. That is, a computer that executes processing using a database, wherein the computer includes a processor having a cache memory and a nonvolatile memory connected to the processor, and the database is stored on the nonvolatile memory. And the computer includes a database management unit that executes processing on the database, and a write processing unit that writes data stored in the cache memory to the database, the write processing unit including the database When a commit request for transaction processing using is received, data manipulated in the transaction processing among data stored in the cache memory is written to the database.
- data stored in the flash memory is written to the database when the transaction process is committed, so that occurrence of data inconsistency can be suppressed.
- FIG. It is a block diagram explaining the structural example of the computer system of a present Example 1.
- FIG. It is a block diagram explaining the software configuration of the computer of the present Example 1.
- It is explanatory drawing which shows the structure of the memory space in the computer of a present Example 1.
- It is explanatory drawing which shows the structural example of the database of the present Example 1.
- FIG. It is explanatory drawing which shows an example of the object management table of the present Example 1.
- FIG. 3 is an explanatory diagram illustrating an example of data arrangement in a main memory and a cache memory according to the first embodiment.
- It is explanatory drawing which shows an example of the free list of the present Example 1.
- FIG. 6 is a flowchart for explaining an example of a writing process of data stored in a cache memory executed by a writing processing unit according to the first embodiment;
- FIG. 6 is an explanatory diagram illustrating an example of a program code used for writing data stored in the cache memory according to the first embodiment.
- FIG. 6 is an explanatory diagram illustrating an example of a program code used for writing data stored in the cache memory according to the first embodiment.
- FIG. 6 is an explanatory diagram illustrating an example of a program code used for writing data stored in the cache memory according to the first embodiment. It is a flowchart explaining the flow of the transaction processing of the present Example 1. It is a flowchart explaining the flow of the transaction processing of the present Example 1.
- FIG. 1 is a block diagram illustrating a configuration example of a computer system according to the first embodiment.
- the computer system includes a computer 100 and a client device 101.
- the computer 100 and the client device 101 are connected via a network.
- the network may be any network as long as the computer 100 and the client device 101 can communicate with each other.
- the type of network may be either WAN or LAN, and the network connection method may be either wireless or wired.
- the number of computers 100 and client devices 101 may be two or more.
- the computer 100 executes a predetermined process using a database.
- the computer 100 includes a processor 110, a volatile memory 121, a nonvolatile memory 122, an IO hub 130, an IO bus 140, an input device 151, a display 152, a network interface 153, an HBA 154, and an HDD 155.
- main memory when the volatile memory 121 and the nonvolatile memory 122 are not distinguished, they are also referred to as main memory.
- the processor 110 and the volatile memory 121 are connected via a memory link 125, and the processor 110 and the nonvolatile memory 122 are similarly connected via a memory link 125.
- the processor 110 and the IO hub 130 are connected via an IO link 131.
- the IO hub 130 is connected to the input device 151, the display 152, the network interface 153, and the HBA 154 via the IO bus 140.
- the HDD 155 is connected to the IO bus 140 via the HBA 154.
- the computer 100 is connected to the client apparatus 101 via the network interface 153.
- the processor 110 is an arithmetic device that executes a program stored in the main memory.
- the functions of the computer 100 are realized by the processor 110 executing a program stored in the main memory.
- the processor 110 includes a plurality of cores 111, a cache controller 113, a cache 114, an IO link controller 115, and a memory controller 116.
- the core 111 is an arithmetic unit that executes a predetermined operation, and includes a cache 112.
- the cache 112 and the cache 114 are cache memories that temporarily store data processed by the processor 110.
- the cache 112 and the cache 114 are not distinguished, they are also referred to as a cache memory.
- the cache controller 113 controls data in the cache memory.
- the IO link controller 115 controls IO devices such as the input device 151 and the network interface 153.
- the memory controller 116 controls access to the main memory.
- the volatile memory 121 and the non-volatile memory 122 are storage media that store programs executed by the processor 110 and information necessary for the programs.
- the volatile memory 121 may be a DRAM (Dynamic Random Access Memory) or the like.
- DRAM Dynamic Random Access Memory
- PCM Phase Change Memory
- ReRAM Resistance Random Access memory
- the input device 151 is a device for inputting various settings and instructions to the computer 100.
- the display 152 is a device that displays the status of the computer 100, processing results, and the like.
- the network interface 153 is an interface for connecting to other devices via a network.
- the HBA 154 is an interface for connecting to a storage device such as the HDD 155. In this embodiment, the HBA 154 is connected to the internal HDD 155, but may be connected to an external storage system (not shown).
- the client device 101 is a computer used by a user or the like, transmits various instructions to the computer 100, and receives processing results and the like from the computer 100.
- the client device 101 includes a processor (not shown), a memory (not shown), and a network interface (not shown).
- FIG. 2 is a block diagram illustrating the software configuration of the computer 100 according to the first embodiment.
- the arrows shown in FIG. 2 indicate the access relationship between function units and the access relationship between function units and information.
- the computer 100 includes a plurality of database management units 200, an object management unit 210, a write processing unit 220, a database 230, an object management table 240, and a free list 250.
- the database management unit 200, the object management unit 210, and the write processing unit 220 are realized by the processor 110 executing a program stored in the main memory.
- a program that realizes the function unit is executed by the processor 110.
- the database 230 stores a plurality of database objects 400 (see FIG. 4). Details of the database object 400 stored in the database 230 will be described later with reference to FIG.
- the object management table 240 stores information for managing the database object 400. Details of the object management table 240 will be described later with reference to FIG.
- the free list 250 stores information for managing free areas in the memory space. Details of the free list 250 will be described later with reference to FIG.
- the database management unit 200 executes various processes for the database 230.
- the database management unit 200 has a buffer for storing the identifier of the record to be processed of the database object 400.
- the computer 100 includes a database management unit 200 for each client device 101. The present embodiment is not limited to the number of database management units 200.
- the object management unit 210 manages the database object 400 stored in the database 230.
- the object management unit 210 arbitrates the processing request received from each database management unit 200, and executes addition processing, update processing, deletion processing, and the like on the database object 400 of the database 230 based on the processing request. .
- the object management unit 210 controls the data so that the data is written into a certain logical address. Note that this embodiment can be applied regardless of whether the cache memory of the system is the write-through method or the write-back method.
- the write processing unit 220 collectively writes data stored in the cache memory to the main memory when the transaction process is committed.
- the database management unit 200, the object management unit 210, and the write processing unit 220 may be realized as functions included in an OS (Operating System) or may be realized as applications that run on the OS.
- OS Operating System
- FIG. 3 is an explanatory diagram illustrating the configuration of the memory space 300 in the computer 100 according to the first embodiment.
- the computer 100 includes a volatile memory 121 and a nonvolatile memory 122 as main memory. Therefore, the memory space 300 includes a volatile memory area 310 provided by the volatile memory 121 and a non-volatile memory area 320 provided by the non-volatile memory 122.
- a program for realizing the database management unit 200, the object management unit 210, and the write processing unit 220 is stored in the volatile memory area 310, and the database 230, the object management table 240, and the free list 250 are stored in the nonvolatile memory area. 320 is stored.
- a program that implements the database management unit 200 is stored in the non-volatile memory area 320, the state in which the failure has occurred may be permanently maintained. . Therefore, in order not to maintain the failure state, a program for realizing each processing unit is stored in the volatile memory area 310.
- a method of setting an address area for mapping the volatile memory area 310 and the non-volatile memory area 320 in the UEFI or BIOS in advance is conceivable.
- the boot loader loads the OS into the volatile memory area 310, the OS reads out a program that realizes each functional unit into the volatile memory area 310, and reads out various information into the nonvolatile memory area 320. .
- the computer 100 includes the volatile memory 121 and the nonvolatile memory 122, but may be configured to include only the nonvolatile memory 122. In this case, the entire memory space 300 becomes a nonvolatile memory area 320.
- FIG. 4 is an explanatory diagram illustrating a configuration example of the database 230 according to the first embodiment.
- the database 230 includes a plurality of database objects 400.
- the database object 400 is an object handled in a database such as a table or a table.
- a table format object will be described as an example. Note that the present embodiment is not limited to the data format of the database object 400.
- the database object 400 is table format data including a plurality of records.
- the database object 400 shown in FIG. 4 includes L records.
- a record is composed of two pieces of data: control data 410 and record data 420.
- the record data 420 is the record data itself, and it can be seen that the record shown in FIG. 4 is composed of N columns 421.
- the control data 410 is data for controlling the record. In this embodiment, the transaction processing result is reflected in the database object 400 based on the control data 410.
- the control data 410 includes O_ID 411, R_ID 412, X_ID 413, C_ID 414, UPD 415, UNDO 416, and DEL 417.
- O_ID 411 is an identifier of the database object 400.
- R_ID 412 is an identifier of a record in the database object 400.
- a data identifier for example, a file name or the like is included in the record data 420.
- X_ID 413 is an identifier of a transaction that is a processing unit using a database.
- C_ID 414 is an identifier of a command executed for the record.
- UPD 415, UNDO 416, and DEL 417 are flags indicating the state of the record.
- UPD 415 is a flag indicating whether a record to be newly added or a record to be updated, and stores either “0” or “1”.
- the UNDO 416 is a flag indicating whether or not the record is a pre-update record, and stores either “0” or “1”.
- DEL 417 is a flag indicating whether or not the record is to be deleted, and stores either “0” or “1”.
- UPD 415 When UPD 415 is “0”, UNDO 416 is “0”, and DEL 417 is “0”, this indicates that the record is a record before the start of transaction processing or a committed record.
- UPD 415 When the UPD 415 is “1”, the UNDO 416 is “0”, and the DEL 417 is “0”, this indicates that the record is updated or added by the database management unit 200.
- UPD 415 When UPD 415 is “0”, UNDO 416 is “1”, and DEL 417 is “0”, this indicates that the record is not updated.
- the UPD 415 When the UPD 415 is “0”, the UNDO 416 is “0”, and the DEL 417 is “1”, this indicates that the record is deleted by the database management unit 200.
- FIG. 5 is an explanatory diagram illustrating an example of the object management table 240 according to the first embodiment.
- the object management table 240 stores information for managing the database object 400. Specifically, the object management table 240 includes an O_ID 501, a type 502, an object definition 503, and a start pointer 504.
- O_ID 501 is an identifier of the database object 400 and is the same as O_ID 411.
- a type 502 indicates the type of the database object 400.
- the type 502 stores information such as “table” and “index”.
- the object definition 503 is definition information on the data structure of the database object 400.
- the object definition 503 stores information such as the number of columns and the size of data stored in each column.
- the start pointer 504 is a pointer for accessing the database object 400.
- the start pointer 504 stores the top address of the storage area in which the database object 400 is stored.
- FIG. 6 is an explanatory diagram illustrating an example of data arrangement in the main memory and the cache memory according to the first embodiment.
- One record 430 of the database object 400 is divided into memory blocks 600 and stored in the plurality of memory blocks 600 of the nonvolatile memory 122.
- the record 1 (430-1) of the database object 400 includes three memory blocks 1 (600-1), 2 (600-2), and 3 (600-3) of the nonvolatile memory 122. It is stored in one memory block 600.
- the processor 110 reads record data used for processing in units of the memory block 600 and stores the read data in the cache line 610.
- data stored in the memory block 1 (600-1) is stored in the cache line 1 (610-1).
- a memory management unit (not shown) installed in the system determines a cache line for storing data based on a logical address specified by a program data write instruction.
- FIG. 7 is an explanatory diagram illustrating an example of the free list 250 according to the first embodiment.
- the entry 700 includes a list pointer 701 and a memory block pointer 702.
- the list pointer 701 is a pointer indicating the entry 700 next to the entry 700 in the free list 250. All entries 700 included in the free list 250 can be traced based on the list pointer 701.
- the list pointer 701 stores the top address of the storage area in which the next entry 700 is stored.
- the memory block pointer 702 is a pointer for accessing the memory block 600 in which no data is stored.
- the memory block pointer 702 stores the top address of the memory block 600 and the like.
- FIG. 8 is a flowchart for explaining an example of additional processing executed by the database management unit 200 according to the first embodiment.
- the database management unit 200 starts an addition process for accepting an instruction to add a record 430 from the client device 101 or the like. At this time, O_ID, R_ID, and the like are input to the database management unit 200.
- the database management unit 200 generates control data 410 for the new record 430 (step S101). Specifically, the database management unit 200 sets predetermined values for the O_ID 411, the R_ID 412, the X_ID 413, and the C_ID 414. In addition, the database management unit 200 sets “1” in the UPD 415 and sets “0” in each of the UNDO 416 and the DEL 417.
- the database management unit 200 generates record data 420 of the new record 430 (Step S102). Since the process for generating the record data 420 may be a known process, a detailed description thereof is omitted. Note that the database management unit 200 calculates the size of the new record 430 based on the generated control data 410 and the generated record data 420.
- the database management unit 200 transmits a write instruction for the new record 430 to the object management unit 210 (step S103).
- the write instruction includes the control data 410, the record data 420, and the record size of the new record 430 in the object management unit 210.
- the database management unit 200 receives a write completion notification from the object management unit 210 (step S104), and records the R_ID 412 and the record size of the record 430 to be added to the buffer (step S105).
- the database management unit 200 notifies the client device 101 or the like where the process instructing the addition of the new record 430 operates (step S106), and then ends the addition process.
- FIG. 9 is a flowchart illustrating an example of the deletion process executed by the database management unit 200 according to the first embodiment.
- the database management unit 200 starts the deletion process when it receives an instruction to delete the record 430 from the client device 101 or the like. At this time, O_ID, R_ID, and the like are input to the database management unit 200.
- the database management unit 200 generates control data 410 to be set in the record 430 to be deleted (step S201). Specifically, the database management unit 200 sets predetermined values for the O_ID 411, the R_ID 412, the X_ID 413, and the C_ID 414. In addition, the database management unit 200 sets “1” in the DEL 417 and sets “0” in each of the UPD 415 and the UNDO 416.
- the database management unit 200 transmits an instruction to write the control data 410 to the object management unit 210 (step S202).
- the database management unit 200 receives a write completion notification from the object management unit 210 (step S203), and records the R_ID 412 and the record size of the record 430 to be deleted in the buffer (step S204).
- the database management unit 200 notifies the client apparatus 101 or the like where the process that requested the deletion of the record 430 is operating (step S205), and then ends the deletion process.
- the database management unit 200 is characterized in that the control data 410 is generated in order to delete the record 430 at the time of commit. That is, the database management unit 200 uses the record itself stored in the database object 400 as a log.
- FIG. 10 is a flowchart illustrating an example of update processing executed by the database management unit 200 according to the first embodiment.
- the database management unit 200 starts an additional process for receiving an update instruction for the record 430 from the client device 101 or the like. At this time, O_ID, R_ID, the value of the record data 420 to be updated, and the like are input to the database management unit 200.
- the database management unit 200 first generates an update record 430 based on the input data.
- the update record 430 represents a record generated from data to be overwritten. That is, the update record 430 corresponds to the record 430 in which the data has been updated.
- the database management unit 200 generates control data 410 and record data 420 of the update record 430 (Step S301, Step S302).
- the database management unit 200 sets predetermined values for the O_ID 411, the R_ID 412, the X_ID 413, and the C_ID 414. In addition, the database management unit 200 sets “1” in the UPD 415 and sets “0” in each of the UNDO 416 and the DEL 417. In addition, the database management unit 200 generates record data 420 using the input value. The database management unit 200 calculates the size of the update record 430 from the generated control data 410 and record data 420.
- the database management unit 200 transmits an instruction to write the update record 430 to the new storage area to the object management unit 210 (step S303).
- the write instruction for the update record 430 includes the control data 410, the record data 420, and the record size of the update record 430.
- the database management unit 200 receives a write completion notification from the object management unit 210 (step S304).
- the database management unit 200 generates control data 410 of the update target record 430 (step S305). Specifically, the database management unit 200 sets predetermined values for the O_ID 411, the R_ID 412, the X_ID 413, and the C_ID 414. Further, the database management unit 200 sets “1” in the UNDO 416 and sets “0” in each of the UPD 415 and the DEL 417.
- the record 430 to be updated represents the record 430 before being updated. That is, it corresponds to the record 430 before the data is overwritten.
- the database management unit 200 transmits an instruction to write the control data 410 of the update target record 430 to the object management unit 210 (step S306).
- the write instruction of the control data 410 of the update target record 430 includes the control data 410 of the update target record.
- the database management unit 200 receives a write completion notification from the object management unit 210 (step S307), and records the R_ID 412 and the record size of the update target record 430 in the buffer (step S308).
- the database management unit 200 notifies the client device 101 or the like where the process that requested the deletion of the record 430 is operating (step S309), and then ends the deletion process.
- the database management unit 200 does not update the record 430 directly at this point even if an instruction to update the record 430 is given.
- the database management unit 200 is characterized in that an update record 430 is generated in order to add a record 430 updated at the time of commit. That is, the database management unit 200 uses the record itself stored in the database object 400 as a log.
- FIG. 11 is a flowchart for explaining an example of a record reading process executed by the object management unit 210 according to the first embodiment.
- the object management unit 210 receives an instruction to read the record 430 from the database management unit 200 (step S401).
- the instruction includes the O_ID of the database object 400 including the record 430 to be read, the R_ID of the record 430 to be read, and the record size.
- the object management unit 210 refers to the object management table 240 and acquires the data format of the database object 400 to be accessed (step S402). Specifically, the object management unit 210 searches for an entry with the O_ID 501 that matches the input O_ID, and acquires information stored in the type 502 of the searched entry and the object definition 503.
- the object management unit 210 calculates the address of the record 430 to be read in the main memory (step S403). Specifically, the object management unit 210 calculates the address of the record 430 in the main memory by applying a predetermined hash function to the R_ID of the record 430 to be read. Note that the address of the record 430 may be calculated using another known method.
- the object management unit 210 calculates the number of memory blocks 600 that store data of the record 430 to be read based on the input record size (step S404).
- the object management unit 210 reads data stored in the memory block 600 of the main memory based on the calculated address and the number of memory blocks 600 (step S405). Specifically, the object management unit 210 identifies the memory block 600 corresponding to the calculated address. The object management unit 210 reads data stored in the memory block 600 by the number of calculated memory blocks 600, starting from the identified memory block 600.
- the object management unit 210 generates a record from the data read from the memory block 600 based on the data format acquired in step S402 (step S406). At this time, since the same X_ID and C_ID are assigned to the data read from the memory block 600, the object management unit 210 deletes the X_ID and C_ID from the data and generates a record.
- the object management unit 210 transmits the generated record to the database management unit 200 that is the request source of the read request (step S407), and ends the process.
- FIG. 12 is a flowchart illustrating an example of a record addition process executed by the object management unit 210 according to the first embodiment.
- the object management unit 210 receives a write instruction from the database management unit 200 (step S501).
- the write instruction of this embodiment includes a write instruction for a new record 430 (step S103), a write instruction for an update record 430 (step S303), and a write instruction for control data 410 of a record 430 to be deleted (step S202). ), And four write instructions for writing the control data 410 of the record 430 to be updated (step S306).
- the write instruction for the new record 430 and the write instruction for the update record 430 include control data 410, record data 420, and a record size.
- the write instruction for the new record 430 and the write instruction for the update record 430 are also referred to as a record write instruction.
- the control data 410 is included in the write instruction of the control data 410 of the record 430 to be deleted and the control data 410 of the record 430 to be updated.
- the write instruction for the control data 410 of the record 430 to be deleted and the control data 410 of the record 430 to be updated are also referred to as a control data write instruction.
- the object management unit 210 determines whether or not the accepted write instruction is a record write instruction (step S502). For example, the object management unit 210 determines whether the received writing instruction is a record writing instruction based on information included in the writing instruction.
- the object management unit 210 When it is determined that the accepted write instruction is a record write instruction, the object management unit 210 generates data to be stored in the memory block 600 using the control data 410 and the record data 420 (step S503). Specifically, the object management unit 210 divides each of the control data 410 and the record data 420 into data in units of memory blocks, and gives the same X_ID and C_ID to each divided data.
- the object management unit 210 calculates the address of the new record 430 or the update record in the main memory (step S504). Specifically, the object management unit 210 calculates the address of the new record 430 or the update record 430 in the main memory by applying a predetermined hash function to the R_ID 412 included in the control data 410. Note that the address of the record 430 may be calculated using another known method.
- the object management unit 210 secures the memory block 600 for storing the new record 430 and the update record 430 in the main memory (step S505). Specifically, the object management unit 210 refers to the free list 250 and acquires as many entries 700 as the number of data generated in step S503. At this time, the object management unit 210 deletes the entry 700 acquired from the free list 250.
- the object management unit 210 writes the data generated in step S503 in the secured memory block 600 (step S506). Specifically, the object management unit 210 writes the generated data into the memory block 600 based on the acquired memory block pointer 702 of the entry 700.
- the object management unit 210 transmits a write completion notification to the database management unit 200 that is the request source of the write request (step S510), and ends the process.
- step S502 If it is determined in step S502 that the received write instruction is a control data write instruction, the object management unit 210 uses the control data 410 to generate data to be stored in the memory block 600 (step S507). . Specifically, the object management unit 210 divides the control data 410 into data in memory block units, and assigns the same X_ID and C_ID to the divided data.
- the object management unit 210 identifies the memory block 600 to which the control data 410 is written (step S508).
- the object management unit 210 calculates the address of the record 430 to be updated in the main memory by applying a predetermined hash function to the R_ID 412 included in the control data 410.
- control data 410 is written in the memory blocks 600 corresponding to the number of generated data, starting from the memory block 600 corresponding to the calculated address.
- the object management unit 210 may secure the memory block 600 that stores the control data 410 by executing the same process as in step S505. In this case, the object management unit 210 deletes the data from the memory block 600 in which the control data 410 before update is stored.
- the object management unit 210 writes the data generated from the control data 410 to the specified memory block 600 (step S509). As a result, the control data 410 of the record 430 to be deleted or the record 430 to be updated is updated.
- the object management unit 210 transmits a write completion notification to the database management unit 200 that is the request source of the write request (step S510), and ends the process.
- FIG. 13 is a flowchart illustrating an example of a commit process and a rollback process executed by the database management unit 200 according to the first embodiment.
- the database management unit 200 starts processing upon receiving a request.
- the database management unit 200 determines whether the received request is a commit or a rollback (step S601). In this embodiment, it is assumed that a commit statement or a rollback statement is explicitly specified in SQL.
- the database management unit 200 transmits a start instruction to the write processing unit 220 (step S602).
- the notification includes the R_ID and the record size recorded in the buffer. Processing executed by the writing processing unit 220 will be described later with reference to FIG.
- the database management unit 200 After receiving the completion notification from the write processing unit 220 (step S603), the database management unit 200 transmits an instruction to read the record 430 whose UPD 415 is “1” to the object management unit 210 (step S604). .
- the object management unit 210 executes the processing of step S401 and step S402, and then refers to the control data 410 of all the records 430 of the database object 400, and the record whose UPD 415 is “1” Search for 430. Thereafter, the object management unit 210 performs the processing from step S403 to step S407 on the retrieved record 430.
- the database management unit 200 After receiving the record 430 from the object management unit 210, the database management unit 200 generates control data 410 for updating the read record 430 (step S605). Specifically, the database management unit 200 sets predetermined values for the O_ID 411, the R_ID 412, the X_ID 413, and the C_ID 414. In addition, the database management unit 200 sets “0” in each of the UPD 415, UNDO 416, and DEL 417.
- the database management unit 200 transmits an instruction to write the control data 410 of the record 430 to the object management unit 210 (step S606).
- the instruction to write the control data 410 of the record 430 includes the control data 410 of the record 430 generated in step S601.
- the object management unit 210 executes the processing from step S507 to step S510.
- the database management unit 200 transmits, to the object management unit 210, an instruction to delete the record 430 whose UNDO 416 is “0” and the record 430 whose DEL 417 is “0” (step S607).
- the deletion instruction of the record 430 includes information indicating that the condition of the record 430 to be deleted, that is, the record 430 whose UNDO 416 is “0” and the record 430 whose DEL 417 is “0” is the deletion target. Processing executed when the object management unit 210 receives a deletion instruction will be described later with reference to FIG.
- the database management unit 200 ends the processing after receiving the write completion notification and the deletion completion notification from the object management unit 210.
- step S608 If it is determined that the accepted request is a rollback, the database management unit 200 transmits an instruction to read the record 430 in which DEL417 is “1” to the object management unit 210 (step S608). Since step S608 is the same process as step S604, the description thereof is omitted.
- the database management unit 200 After receiving the read completion notification from the object management unit 210, the database management unit 200 generates control data 410 for updating the read record 430 (step S609). Specifically, the database management unit 200 sets predetermined values for the O_ID 411, the R_ID 412, the X_ID 413, and the C_ID 414. In addition, the database management unit 200 sets “0” in each of the UPD 415, UNDO 416, and DEL 417.
- the database management unit 200 transmits an instruction to write the control data 410 of the record 430 to the object management unit 210 (step S610).
- the instruction to write the control data 410 of the record 430 includes the control data 410 of the record 430 generated in step S609.
- the object management unit 210 executes the processing from step S507 to step S510.
- the database management unit 200 transmits an instruction to read the record 430 in which UNDO 416 is “1” to the object management unit 210 (step S611).
- the processing in step S611 has the same contents as the processing in step S604, and thus description thereof is omitted.
- the database management unit 200 After receiving the read completion notification from the object management unit 210, the database management unit 200 generates control data 410 for updating the read record 430 (step S612). Specifically, the database management unit 200 sets predetermined values for the O_ID 411, the R_ID 412, the X_ID 413, and the C_ID 414. In addition, the database management unit 200 sets “0” in each of the UPD 415, UNDO 416, and DEL 417.
- the database management unit 200 transmits an instruction to write the control data 410 of the record 430 to the object management unit 210 (step S613).
- the instruction to write the control data 410 of the record 430 includes the control data 410 of the record 430 generated in step S601.
- the object management unit 210 executes the processing from step S507 to step S510.
- the database management unit 200 transmits an instruction to delete the record 430 whose UPD 415 is “1” to the object management unit 210 (step S614). Processing executed when the object management unit 210 receives a deletion instruction will be described later with reference to FIG.
- the database management unit 200 ends the processing after receiving the write completion notification and the deletion completion notification from the object management unit 210.
- FIG. 14 is a flowchart illustrating an example of a record deletion process executed by the object management unit 210 according to the first embodiment.
- the object management unit 210 receives a deletion instruction from the database management unit 200 (step S701).
- the object management unit 210 searches for a record to be deleted based on the condition of the record 430 to be deleted included in the deletion instruction (step S702).
- the object management unit 210 refers to the database object 400 and searches for the record 430 whose UNDO 416 is “1”. Note that the search process is a known technique, and thus detailed description thereof is omitted.
- the object management unit 210 deletes the record 430 retrieved from the database object 400 (step S703).
- the object management unit 210 adds the memory block 600 storing the data of the deleted record 430 to the free list 250 (step S704).
- the object management unit 210 creates the entry 700 and sets the address of the memory block 600 in which the data of the deleted record 430 is stored in the memory block pointer 702. Further, the object management unit 210 searches for an entry whose list pointer 701 is “NULL”, and sets the address of the newly created entry 700 in the list pointer 701. The object management unit 210 repeatedly executes the process described above for the number of memory blocks 600 to which the process is added.
- the object management unit 210 transmits a deletion completion notification to the requesting database management unit 200 (step S705), and ends the process.
- FIG. 15 is a flowchart illustrating an example of a writing process of data stored in the cache memory executed by the writing processing unit 220 according to the first embodiment.
- FIG. 16A, FIG. 16B, and FIG. 16C are explanatory diagrams illustrating an example of a program code used for writing data stored in the cache memory according to the first embodiment.
- the write processing unit 220 starts processing upon receiving a start instruction from the database management unit 200.
- the start instruction includes the R_ID of the record 430 and the record size.
- the writing processing unit 220 selects one processing target record 430 (step S801).
- the write processing unit 220 identifies the cache line 610 that stores the data of the record 430 to be processed (step S802). Specifically, the following processing is executed.
- the write processing unit 220 calculates the address of the record 430 in the main memory by applying a predetermined hash function to R_ID.
- the write processing unit 220 calculates the number of memory blocks 600 in which data of the record 430 is stored by dividing the record size by the size of the cache line 610.
- the write processing unit 220 calculates an offset from the size of the cache line 610 and the number of memory blocks 600. The above is the description of the process in step S802.
- the writing processing unit 220 starts a critical section (step S803). This is because the data stored in the cache line 610 needs to be atomically written to the main memory. Therefore, the write processing unit 220 prohibits writing to the specified cache line 610.
- the write processing unit 220 writes the data stored in the cache memory to the main memory (step S804).
- the write processing unit 220 writes the data stored in the cache memory to the main memory, and then ends the critical section (step S805). As a result, the write prohibition on the cache line 610 is released.
- FIG. 16A shows a program code for synchronizing the cache memory and the main memory.
- the program code includes an instruction to write data stored in the cache memory.
- “BulkWtMM (linear address)” corresponds to the write command.
- FIG. 16B and FIG. 16C show an example of a program code defining a write command.
- the program code shown in FIG. 16B is a program that instructs writing of all the cache lines 610 in which the data of the record corresponding to the address specified in (linear address) is stored, and deleting the data from the cache line 610. Code.
- the program code shown in FIG. 16C includes writing of the cache line 610 storing the changed data among all the cache lines 610 storing the data of the record corresponding to the address designated in (linear address), This is a program code for instructing reading of data written from the main memory.
- the program code shown in FIG. 16C is a cache control program code according to the MESIF protocol.
- program code for writing the data stored in the cache memory to the main memory is not limited to that described above.
- the writing processing unit 220 determines whether or not the processing has been completed for the records 430 corresponding to all the R_IDs included in the start instruction (step S806).
- the writing processing unit 220 returns to step S801 and executes the processing from step S802 to step S806 for the other records 430.
- the write processing unit 220 transmits a completion notification to the requesting database management unit 200 (step S807), and ends the processing.
- FIG. 17A, FIG. 17B, and FIG. 17C are flowcharts for explaining the flow of transaction processing according to the first embodiment.
- a database object 400 (1) is assumed at the start of transaction processing. It is assumed that the record data 420 includes two columns “C1” and “C2”. Column C1 is an identifier of record data 420, and column C2 is an actual value of record data 420.
- the client apparatus 101 requests addition of a new record 430 in which the column C1 is “1002” and the column C2 is “GHI” (step S901).
- the identifier of the additional command of the new record 430 is “001”.
- the following processing is executed.
- the database management unit 200 instructs the object management unit 210 to write a new record 430 in which the column C1 is “1002” and the column C2 is “GHI” (step S103).
- the object management unit 210 creates a database object with a record 430 in which O_ID 411 is “000”, R_ID 412 is “R3”, X_ID 413 is “002”, C_ID 414 is “001”, UPD 415 is “1”, UNDO 416 and DEL 417 are “0”.
- 400 (1) is added (step S506). As a result, the state of the database object 400 (2) is obtained.
- the client apparatus 101 requests deletion of the record 430 whose column C1 is “1000” (step S902).
- the identifier of the record deletion command is “002”.
- the following processing is executed.
- the database management unit 200 instructs the object management unit 210 to write the control data 410 of the record 430 whose column C1 is “1000” (step S202).
- the object management unit 210 writes the control data 410 to the record 430 whose column C1 is “1000” (step S509).
- the DEL 417 of the record 430 is updated from “0” to “1”. Therefore, the database object 400 (3) is brought into a state.
- the client apparatus 101 requests an update of the value in the column C2 of the record in which the column C1 is “1001” to “JKL” (step S903).
- the identifier of the record update command is “003”. At this time, the following processing is executed.
- the database management unit 200 instructs writing of an update record in which the column C1 is “1001” and the column C2 is “JKL” (step S303).
- the object management unit 210 adds a record 430 in which O_ID 411 is “000”, R_ID 412 is “R4”, X_ID 413 is “002”, C_ID 414 is “003”, UPD 415 is “1”, UNDO 416 and DEL 417 are “0”. (Step S506).
- the database management unit 200 instructs writing of the control data 410 of the update target record 430 (step S306).
- the object management unit 210 writes the control data 410 to the record 430 in which the column C1 is “1001” and the UNDO 416 is “0” (step S509). As a result, the UNDO 416 of the record 430 is updated from “0” to “1”.
- the database object 400 (4) is brought into a state.
- the client apparatus 101 determines whether or not a series of operations has been completed (step S904).
- step S905 the client apparatus 101 requests commit (step S905).
- the identifier of the commit command is “004”. At this time, the following processing is executed.
- the database management unit 200 transmits a processing start instruction of the writing processing unit 220 (step S602). After receiving the completion notification from the write processing unit 220 (step S603), the database management unit 200 instructs writing of the control data 410 of the record 430 in which the UPD 415 is “1” (step S606).
- the object management unit 210 writes the control data 410 in the record 430 in which the UPD 415 is “1” (step S509). As a result, the UPD 415 of the record 430 is updated from “1” to “0”.
- the database management unit 200 instructs the deletion of the record 430 in which the UNDO 416 is “1” and the record 430 in which the DEL 417 is “1” (step S607).
- the object management unit 210 searches the record 430 whose UNDO 416 is “1” and the record 430 whose DEL 417 is “1” (step S702), and deletes the record 430 searched from the database object 400 (step S703).
- the database object 400 (5) is brought into a state.
- step S906 the client apparatus 101 requests rollback (step S906).
- the rollback command identifier is “005”. At this time, the following processing is executed.
- the database management unit 200 instructs writing of the control data 410 of the record whose DEL 417 is “1” (step S610).
- the object management unit 210 writes the control data 410 in the record 430 in which the DEL 417 is “1” (step S509). As a result, the DEL 417 of the record 430 is updated from “1” to “0”.
- the database management unit 200 instructs writing of the control data 410 of the record whose UNDO 416 is “1” (step S613).
- the object management unit 210 writes the control data 410 to the record 430 in which the UNDO 416 is “1” (step S509). As a result, the UNDO 416 of the record 430 is updated from “1” to “0”.
- the object management unit 210 instructs the deletion of the record 430 in which the UPD 415 is “1” (step S614).
- the object management unit 210 searches the record 430 whose UPD 415 is “1” (step S702), and deletes the record 430 searched from the database object 400 (step S703).
- FIG. 18 is a flowchart illustrating an example of a rollback process executed by the object management unit 210 according to the first embodiment.
- the object management unit 210 starts a rollback process described below when a failure occurs before the commit is completed and a rollback process execution instruction is received from the database management unit 200 or the like.
- the execution instruction includes the identifier of the database object 400 to be processed.
- the object management unit 210 refers to the object management table 240 and acquires the address of the database object 400 to be processed (step S1001). Specifically, the object management unit 210 searches for an entry whose O_ID 501 matches the identifier included in the execution instruction, and acquires an address stored in the start pointer 504 of the searched entry.
- the object management unit 210 determines whether or not the processing has been completed for all the records 430 of the database object 400 (step S1002).
- the object management unit 210 selects one processing target record 430 from the database object 400 (step S1003). Specifically, the object management unit 210 selects one R_ID.
- the database management unit 200 refers to the memory block 600 in which the data of the selected record 430 is stored, and checks the X_ID and C_ID of the data stored in the memory block 600 (step S1004). The database management unit 200 determines whether the X_ID and C_ID of the data stored in all the memory blocks 600 match (step S1005).
- the database management unit 200 If it is determined that the X_ID and C_ID of the data stored in all the memory blocks 600 match, the database management unit 200 returns to step S1002.
- step S1006 If it is determined that the X_ID and C_ID of the data stored in all the memory blocks 600 do not match, the record 430 having the same X_ID and C_ID is updated (step S1006), and then the process returns to step S1002. Specifically, the following processing is executed.
- the database management unit 200 transmits a write instruction for updating the DEL 417 to “0” to the object management unit 210.
- the database management unit 200 transmits an instruction to delete the record 430 to the object management unit 210.
- the database management unit 200 transmits a write instruction for updating the UNDO 416 to “0” to the object management unit 210.
- step S1002 When it is determined in step S1002 that the processing has been completed for all the records 430 of the database object 400, the object management unit 210 transmits a processing completion notification to the database management unit 200 (step S1007), and then ends the processing. To do.
- FIG. 19 is a flowchart illustrating an example of the initialization process executed by the object management unit 210 according to the first embodiment.
- the object management unit 210 receives an initialization instruction from the object management unit 210 (step S1101).
- the initialization instruction includes the size of the storage area allocated to the database 230 and the address of the storage area.
- the object management unit 210 divides the storage area allocated to the database 230 into storage areas of a predetermined size (memory block size), adds each storage area to the free list 250 (step S1102), and then ends the processing. .
- the object management unit 210 divides the storage area allocated to the database 230 into a plurality of memory blocks 600 and generates as many entries 700 as the number of memory blocks 600 in the free list 250.
- the object management unit 210 sets the address of another entry 700 in the list pointer 701 of the entry 700, and sets the address of one memory block 600 in the memory block pointer 702.
- the database management unit 200 and the object management unit 210 are provided separately, but the database management unit 200 and the object management unit 210 may be combined into one functional unit.
- the database management unit 200 may include the functions of the object management unit 210.
- the computer 100 writes the record data related to the transaction process among the data stored in the cache memory of the processor 110 to the main memory (nonvolatile memory 122). .
- the state of data stored in the cache memory matches the state of data stored in the main memory. That is, data consistency can be ensured.
- the computer 100 can ensure data consistency while maintaining data persistence by updating the control data 410 when the record 430 is operated. This enables rollback without using a log storage area. Therefore, the storage area of the nonvolatile storage medium can be used effectively.
- this invention is not limited to the above-mentioned Example, Various modifications are included. Further, for example, the above-described embodiments are described in detail for easy understanding of the present invention, and are not necessarily limited to those provided with all the described configurations. Further, a part of the configuration of each embodiment can be added to, deleted from, or replaced with another configuration.
- each of the above-described configurations, functions, processing units, processing means, and the like may be realized by hardware by designing a part or all of them with, for example, an integrated circuit.
- the present invention can also be realized by software program codes that implement the functions of the embodiments.
- a storage medium in which the program code is recorded is provided to the computer, and a processor included in the computer reads the program code stored in the storage medium.
- the program code itself read from the storage medium realizes the functions of the above-described embodiments, and the program code itself and the storage medium storing it constitute the present invention.
- Examples of storage media for supplying such program codes include flexible disks, CD-ROMs, DVD-ROMs, hard disks, SSDs (Solid State Drives), optical disks, magneto-optical disks, CD-Rs, magnetic tapes, A non-volatile memory card, ROM, or the like is used.
- program code for realizing the functions described in this embodiment can be implemented by a wide range of programs or script languages such as assembler, C / C ++, Perl, Shell, PHP, Java, and the like.
- the program code is stored in a storage means such as a hard disk or memory of a computer or a storage medium such as a CD-RW or CD-R.
- a processor included in the computer may read and execute the program code stored in the storage unit or the storage medium.
- control lines and information lines indicate those that are considered necessary for the explanation, and do not necessarily indicate all the control lines and information lines on the product. All the components may be connected to each other.
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Databases & Information Systems (AREA)
- Data Mining & Analysis (AREA)
- Human Computer Interaction (AREA)
- Quality & Reliability (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
Description
図1は、本実施例1の計算機システムの構成例を説明するブロック図である。
Claims (14)
- データベースを用いた処理を実行する計算機であって、
前記計算機は、キャッシュメモリを有するプロセッサと、前記プロセッサに接続される不揮発性メモリとを備え、
前記不揮発性メモリ上には、前記データベースが構築され、
前記計算機は、
前記データベースに対する処理を実行するデータベース管理部と、
前記キャッシュメモリに格納されるデータを前記データベースに書き込む書込処理部と、を備え、
前記書込処理部は、前記データベースを用いたトランザクション処理のコミット要求を受け付けた場合、前記キャッシュメモリに格納されるデータのうち、前記トランザクション処理において操作されたデータを前記データベースに書き込むことを特徴とする計算機。 - 請求項1に記載の計算機であって、
前記データベース管理部は、
前記トランザクション処理において操作されたデータの識別子及びデータサイズを記録するバッファを有し、
前記コミット要求を受け付けた場合、前記バッファに記録された前記データの識別子及び前記データサイズを前記書込処理部に出力し、
前記書込処理部は、
前記データの識別子及び前記データサイズに基づいて、前記トランザクション処理において操作されたデータを特定し、
前記特定されたデータが格納される記憶領域に対する書き込みを禁止し、
前記特定されたデータを前記データベースに書き込み、
前記特定されたデータの書き込みが完了した後、前記特定されたデータが格納される記憶領域に対する書き込みを再開することを特徴とする計算機。 - 請求項2に記載の計算機であって、
前記データベース管理部は、
前記トランザクション処理において、前記データベースに対する処理の対象となるデータに処理状態を示すフラグを付与し、
前記キャッシュメモリに格納されるデータを前記データベースに書き込んだ旨を通知する完了通知を前記書込処理部から受信し、
前記フラグに基づいて、前記トランザクション処理における前記データベースの処理内容を反映させることを特徴とする計算機。 - 請求項3に記載の計算機であって、
前記データベース管理部は、前記トランザクション処理の障害発生によってロールバック処理の実行が要求された場合、前記フラグに基づいて、前記データベースを前記トランザクション処理が実行される前の状態にロールバックすることを特徴とする計算機。 - 請求項4に記載の計算機であって、
前記データベース管理部は、
前記データベースに格納される第1のデータを更新する場合、更新された第1のデータを生成し、更新されたデータであることを示す第1のフラグが付与された前記更新された第1のデータを前記データベースに追加し、
更新前のデータであることを示す第2のフラグを前記第1のデータに付与し、
前記書込処理部から前記完了通知を受信した場合、前記第1のフラグが付与されたデータから当該第1のフラグを削除し、前記第2のフラグが付与されたデータを前記データベースから削除し、
前記ロールバック処理の実行が要求された場合、前記第2のフラグが付与されたデータから当該第2のフラグを削除し、前記第1のフラグが付与されたデータを前記データベースから削除することを特徴とする計算機。 - 請求項4に記載の計算機であって、
前記データベース管理部は、
前記データベースに格納される第2のデータを削除する場合、削除されるデータであることを示す第3のフラグを前記第2のデータに付与し、
前記書込処理部から前記完了通知を受信した場合、前記第3のフラグが付与されたデータを前記データベースから削除し、
前記ロールバック処理の実行が要求された場合、前記第3のフラグが付与されたデータから当該第3のフラグを削除することを特徴とする計算機。 - 請求項4に記載の計算機であって、
前記データベース管理部は、
前記データベースに第3のデータを追加する場合、追加されるデータであること示す第4のフラグが付与された前記第3のデータを前記データベースに追加し、
前記書込処理部から前記完了通知を受信した場合、前記第4のフラグが付与されたデータから当該第4のフラグを削除し、
前記ロールバック処理の実行が要求された場合、前記第4のフラグが付与されたデータを前記データベースから削除することを特徴とする計算機。 - データベースを用いた処理を実行する計算機におけるデータ管理方法であって、
前記計算機は、キャッシュメモリを有するプロセッサと、前記プロセッサに接続される不揮発性メモリとを備え、
前記不揮発性メモリ上には、前記データベースが構築され、
前記計算機は、データベース管理部と、書込処理部とを備え、
前記データ管理方法は、
前記データベース管理部が、トランザクション処理における処理命令に基づいて前記データベースに対する処理を実行する第1のステップと、
前記データベース管理部が、前記トランザクション処理のコミット要求を受け付けた場合、前記書込処理部に処理の開始指示を出力する第2のステップと、
前記書込処理部が、前記処理の開始指示を受け付けた場合、前記キャッシュメモリに格納されるデータのうち、前記トランザクション処理において操作されたデータを前記データベースに書き込む第3のステップと、を含むことを特徴とするデータ管理方法。 - 請求項8に記載のデータ管理方法であって、
前記データベース管理部は、前記トランザクション処理において操作されたデータの識別子及びデータサイズを記録するバッファを有し、
前記第2のステップでは、前記データベース管理部が、前記バッファに記録された前記データの識別子及び前記データサイズを前記書込処理部に出力し、
前記第3のステップは、
前記データの識別子及び前記データサイズに基づいて、前記トランザクション処理において操作されたデータを特定するステップと、
前記特定されたデータが格納される記憶領域に対する書き込みを禁止するステップと、
前記特定されたデータを前記データベースに書き込むステップと、
前記特定されたデータの書き込みが完了した後、前記特定されたデータが格納される記憶領域に対する書き込みを再開するステップと、を含むことを特徴とするデータ管理方法。 - 請求項9に記載のデータ管理方法であって、
前記データ管理方法は、
前記データベース管理部が、前記トランザクション処理において、前記データベースに対する処理の対象となるデータに処理状態を示すフラグを付与する第4のステップと、
前記データベース管理部が、前記キャッシュメモリに格納されるデータを前記データベースに書き込んだ旨を通知する完了通知を前記書込処理部から受信する第5のステップと、
前記データベース管理部が、前記フラグに基づいて、前記トランザクション処理における前記データベースの処理内容を反映させる第6のステップと、を含むことを特徴とするデータ管理方法。 - 請求項10に記載のデータ管理方法であって、
前記データ管理方法は、
前記データベース管理部が、前記トランザクション処理の障害発生によってロールバック処理の実行が要求された場合、前記フラグに基づいて、前記データベースを前記トランザクション処理が実行される前の状態にロールバックする第7のステップを含むことを特徴とするデータ管理方法。 - 請求項11に記載のデータ管理方法であって、
前記第4のステップは、
前記データベースに格納される第1のデータを更新する場合、更新された第1のデータを生成し、更新されたデータであることを示す第1のフラグが付与された前記更新された第1のデータを前記データベースに追加するステップと、
更新前のデータであることを示す第2のフラグを前記第1のデータに付与するステップと、を含み、
前記第6のステップは、
前記第1のフラグが付与されたデータから当該第1のフラグを削除するステップと、
前記第2のフラグが付与されたデータを前記データベースから削除するステップと、を含み、
前記第7のステップは、
前記第2のフラグが付与されたデータから当該第2のフラグを削除するステップと、
前記第1のフラグが付与されたデータを前記データベースから削除するステップと、を含むことを特徴とするデータ管理方法。 - 請求項11に記載のデータ管理方法であって、
前記第4のステップは、前記データベースに格納される第2のデータを削除する場合、削除されるデータであることを示す第3のフラグを前記第2のデータに付与するステップを含み、
前記第6のステップは、前記第3のフラグが付与されたデータを前記データベースから削除するステップを含み、
前記第7のステップは、前記第3のフラグが付与されたデータから当該第3のフラグを削除するステップを含むことを特徴とするデータ管理方法。 - 請求項11に記載のデータ管理方法であって、
前記第4のステップは、追加されるデータであること示す第4のフラグが付与された前記第3のデータを前記データベースに追加するステップを含み、
前記第6のステップは、前記第4のフラグが付与されたデータから当該第4のフラグを削除するステップを含み、
前記第7のステップは、前記ロールバック処理の実行が要求された場合、前記第4のフラグが付与されたデータを前記データベースから削除するステップを含むことを特徴とするデータ管理方法。
Priority Applications (3)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
US15/303,293 US10430287B2 (en) | 2014-04-23 | 2014-04-23 | Computer |
EP14889792.9A EP3136245B1 (en) | 2014-04-23 | 2014-04-23 | Computer |
PCT/JP2014/061394 WO2015162717A1 (ja) | 2014-04-23 | 2014-04-23 | 計算機 |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
PCT/JP2014/061394 WO2015162717A1 (ja) | 2014-04-23 | 2014-04-23 | 計算機 |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2015162717A1 true WO2015162717A1 (ja) | 2015-10-29 |
Family
ID=54331907
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/JP2014/061394 WO2015162717A1 (ja) | 2014-04-23 | 2014-04-23 | 計算機 |
Country Status (3)
Country | Link |
---|---|
US (1) | US10430287B2 (ja) |
EP (1) | EP3136245B1 (ja) |
WO (1) | WO2015162717A1 (ja) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2017183096A1 (ja) * | 2016-04-19 | 2017-10-26 | 株式会社日立製作所 | 計算機システム及び不揮発性メモリの冗長化方法 |
TWI771646B (zh) * | 2019-09-19 | 2022-07-21 | 日商鎧俠股份有限公司 | 記憶裝置及記憶體控制器 |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112783556B (zh) * | 2021-01-06 | 2023-04-07 | 南阳理工学院 | 信息处理方法、信息处理装置及终端设备 |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2000347909A (ja) * | 1999-06-07 | 2000-12-15 | Hitachi Ltd | トランザクション処理向けストレージ方法および装置、トランザクショナルストレージ |
JP2001527242A (ja) * | 1997-12-22 | 2001-12-25 | ティモシー アール リーモント | ロックグループを用いた楽観的並行処理制御のためのきめ細やかな整合性をもたらす仕組み |
JP2012128596A (ja) * | 2010-12-14 | 2012-07-05 | Canon Inc | データベースシステム、その情報処理方法、およびそのプログラム |
Family Cites Families (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP3070494B2 (ja) * | 1996-11-15 | 2000-07-31 | ヤマハ株式会社 | 光ディスク記録装置 |
US6457021B1 (en) | 1998-08-18 | 2002-09-24 | Microsoft Corporation | In-memory database system |
US7356650B1 (en) | 2005-06-17 | 2008-04-08 | Unisys Corporation | Cache apparatus and method for accesses lacking locality |
JPWO2008139521A1 (ja) * | 2007-04-27 | 2010-07-29 | 富士通株式会社 | リモートファイルシステム、端末装置およびサーバ装置 |
US20090012959A1 (en) * | 2007-07-06 | 2009-01-08 | Nokia Corporation | Method, Apparatus and Computer Program Product for Providing Presentation of a Media Collection |
US8732143B2 (en) | 2010-08-27 | 2014-05-20 | Microsoft Corporation | Reducing locking during database transactions |
US8335771B1 (en) * | 2010-09-29 | 2012-12-18 | Emc Corporation | Storage array snapshots for logged access replication in a continuous data protection system |
CA2819373A1 (en) * | 2010-12-09 | 2012-06-14 | Amgen Inc. | Bicyclic compounds as pim inhibitors |
US9047178B2 (en) | 2010-12-13 | 2015-06-02 | SanDisk Technologies, Inc. | Auto-commit memory synchronization |
US8990166B2 (en) * | 2011-03-25 | 2015-03-24 | Sap Se | Variable page sizing for improved physical clustering |
JP6036470B2 (ja) * | 2013-03-26 | 2016-11-30 | 富士通株式会社 | 情報処理システム、情報処理装置、情報処理方法、及び情報処理プログラム |
-
2014
- 2014-04-23 WO PCT/JP2014/061394 patent/WO2015162717A1/ja active Application Filing
- 2014-04-23 EP EP14889792.9A patent/EP3136245B1/en active Active
- 2014-04-23 US US15/303,293 patent/US10430287B2/en not_active Expired - Fee Related
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2001527242A (ja) * | 1997-12-22 | 2001-12-25 | ティモシー アール リーモント | ロックグループを用いた楽観的並行処理制御のためのきめ細やかな整合性をもたらす仕組み |
JP2000347909A (ja) * | 1999-06-07 | 2000-12-15 | Hitachi Ltd | トランザクション処理向けストレージ方法および装置、トランザクショナルストレージ |
JP2012128596A (ja) * | 2010-12-14 | 2012-07-05 | Canon Inc | データベースシステム、その情報処理方法、およびそのプログラム |
Non-Patent Citations (2)
Title |
---|
HIROMU KATO: "Kiso/Genri o Rikai shite Kaihatsu Koritsu no Kojo o Mezasu Database Katsuyo Gijutsu no Tettei Kenkyu", INTERFACE, vol. 28, no. 10, 1 October 2002 (2002-10-01), pages 86 - 96, XP008184314 * |
See also references of EP3136245A4 * |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2017183096A1 (ja) * | 2016-04-19 | 2017-10-26 | 株式会社日立製作所 | 計算機システム及び不揮発性メモリの冗長化方法 |
US10552088B2 (en) | 2016-04-19 | 2020-02-04 | Hitachi, Ltd. | Computer system and method for redundantizing nonvolatile memory |
TWI771646B (zh) * | 2019-09-19 | 2022-07-21 | 日商鎧俠股份有限公司 | 記憶裝置及記憶體控制器 |
Also Published As
Publication number | Publication date |
---|---|
EP3136245B1 (en) | 2019-07-03 |
EP3136245A1 (en) | 2017-03-01 |
US10430287B2 (en) | 2019-10-01 |
US20170039110A1 (en) | 2017-02-09 |
EP3136245A4 (en) | 2017-10-18 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US10983955B2 (en) | Data unit cloning in memory-based file systems | |
US9361326B2 (en) | Selectable data migration | |
JP2018028715A (ja) | ストレージ制御装置、ストレージシステムおよびストレージ制御プログラム | |
US10891074B2 (en) | Key-value storage device supporting snapshot function and operating method thereof | |
JP2009205333A (ja) | 計算機システム、ストレージ装置及びデータ管理方法 | |
WO2010109568A1 (ja) | ストレージ装置 | |
EP2669806B1 (en) | Storage system | |
US20120185516A1 (en) | Computer data file merging based on file metadata | |
WO2015162717A1 (ja) | 計算機 | |
US9886361B2 (en) | Shifting a defrag operation in a mirrored system | |
US11176089B2 (en) | Systems and methods for implementing dynamic file systems | |
JP6033420B2 (ja) | ストレージシステムおよびストレージシステムの制御方法 | |
JP2016062406A (ja) | メモリシステム、メモリシステムの制御方法及びプログラム | |
JP6089855B2 (ja) | 仮想化システム、仮想サーバ、ファイル書き込み方法、及びファイル書き込みプログラム | |
US20160026548A1 (en) | Storage control device and storage system | |
KR101834082B1 (ko) | 다중 ssd 시스템 관리 장치 및 방법 | |
KR101618999B1 (ko) | 네트워크 부트 시스템 | |
KR100939814B1 (ko) | 플래시 메모리의 로그파일 관리 및 기록방법 | |
JP2013109404A (ja) | 情報処理装置 | |
KR101375794B1 (ko) | 데이터베이스의 성능을 향상하기 위한 방법 및 장치 | |
KR20230025322A (ko) | 호스트, 호스트의 동작 방법 및 스토리지 시스템 | |
WO2014010016A1 (ja) | プログラム、データ管理方法、および情報処理装置 | |
EP3314390B1 (en) | Returning coherent data in response to a failure of a storage device when a single input/output request spans two storage devices | |
JP6492863B2 (ja) | 拡張記憶制御装置、拡張記憶制御システム、拡張記憶制御方法、及び、拡張記憶制御プログラム | |
WO2018055751A1 (ja) | 計算機システム及び記憶制御方法 |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 14889792 Country of ref document: EP Kind code of ref document: A1 |
|
WWE | Wipo information: entry into national phase |
Ref document number: 15303293 Country of ref document: US |
|
REEP | Request for entry into the european phase |
Ref document number: 2014889792 Country of ref document: EP |
|
WWE | Wipo information: entry into national phase |
Ref document number: 2014889792 Country of ref document: EP |
|
NENP | Non-entry into the national phase |
Ref country code: DE |
|
NENP | Non-entry into the national phase |
Ref country code: JP |