WO2014199568A1 - 永続記憶装置へのデータ書込制御方法 - Google Patents

永続記憶装置へのデータ書込制御方法 Download PDF

Info

Publication number
WO2014199568A1
WO2014199568A1 PCT/JP2014/002620 JP2014002620W WO2014199568A1 WO 2014199568 A1 WO2014199568 A1 WO 2014199568A1 JP 2014002620 W JP2014002620 W JP 2014002620W WO 2014199568 A1 WO2014199568 A1 WO 2014199568A1
Authority
WO
WIPO (PCT)
Prior art keywords
data
computer
cache
storage device
version number
Prior art date
Application number
PCT/JP2014/002620
Other languages
English (en)
French (fr)
Inventor
光樹 祐成
Original Assignee
日本電気株式会社
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 日本電気株式会社 filed Critical 日本電気株式会社
Priority to US14/893,998 priority Critical patent/US9767023B2/en
Priority to JP2015522498A priority patent/JPWO2014199568A1/ja
Priority to CN201480033917.XA priority patent/CN105339906B/zh
Publication of WO2014199568A1 publication Critical patent/WO2014199568A1/ja

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F12/00Accessing, addressing or allocating within memory systems or architectures
    • G06F12/02Addressing or allocation; Relocation
    • G06F12/08Addressing or allocation; Relocation in hierarchically structured memory systems, e.g. virtual memory systems
    • G06F12/0802Addressing of a memory level in which the access to the desired data or data block requires associative addressing means, e.g. caches
    • G06F12/0806Multiuser, multiprocessor or multiprocessing cache systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/17Details of further file system functions
    • G06F16/172Caching, prefetching or hoarding of files
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input 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/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0604Improving or facilitating administration, e.g. storage management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input 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/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/061Improving I/O performance
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input 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/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0646Horizontal data movement in storage systems, i.e. moving data in between storage devices or systems
    • G06F3/0647Migration mechanisms
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input 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/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0646Horizontal data movement in storage systems, i.e. moving data in between storage devices or systems
    • G06F3/065Replication mechanisms
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input 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/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0655Vertical data movement, i.e. input-output transfer; data movement between one or more hosts and one or more storage devices
    • G06F3/0656Data buffering arrangements
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input 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/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0668Interfaces specially adapted for storage systems adopting a particular infrastructure
    • G06F3/067Distributed or networked storage systems, e.g. storage area networks [SAN], network attached storage [NAS]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2212/00Indexing scheme relating to accessing, addressing or allocation within memory systems or architectures
    • G06F2212/62Details of cache specific to multiprocessor cache arrangements

Definitions

  • the present invention relates to a method for controlling data writing to a permanent storage device, a computer system, a storage computer, a cache computer, and a program.
  • KVS key value store
  • a corresponding unique indicator is set for data (value: value)
  • KV data data in which a key and a value are paired
  • a device having a function capable of storing KV data distributed to a plurality of servers is called distributed KVS.
  • the distributed KVS is a kind of distributed database, and places importance on scalability and throughput.
  • the distributed KVS is mainly used in a system that does not require strong data consistency.
  • a cache In a distributed processing system such as distributed KVS, use of a cache is known as a technique for improving data processing performance.
  • the use of a cache is a technique for increasing the speed by storing data that is frequently used in a high-speed storage device, thereby eliminating the waste of reading from the low-speed permanent storage device (see, for example, Patent Document 1).
  • FIG. 15 is a conceptual diagram of a distributed processing system 1000 that uses a cache and is related to the present invention.
  • the distributed processing system 1000 includes a computer 1200 and a plurality of computers 1300 connected to the computer 1200 via a network 1100.
  • the computer 1200 includes a permanent storage device 1220 that permanently stores the data 1210.
  • the permanent storage device 1220 is composed of, for example, an HDD (Hard Disk Drive).
  • Data 1210 on the permanent recording device 1220 has a data body 1211, identification information 1212, and a version number 1213.
  • the data body 1211 is a numerical value or a character string.
  • the identification information 1212 is an identifier that uniquely identifies the data 1210.
  • the version number 1213 represents the latest time when the data 1210 is updated.
  • Each of the plurality of computers 1300 includes a cache 1320 that stores copy data 1310 of data 1210 acquired from the permanent storage device 1220 of the computer 1200.
  • the cache 1320 is composed of, for example, a RAM (Random Access Memory).
  • the data 1310 has a data body 1311, identification information 1312, and version number 1213 corresponding to the data body 1211, identification information 1212, and version number 1213 of the original data 1210.
  • Each computer 1300 obtains data 1210 from the permanent storage device 1220 of the computer 1200 in advance and copies it to the cache 1320 as data 1310. Next, each computer 1300 executes processing using the data 1310 copied onto the cache 1320. At this time, when each computer 1300 updates the data body 1311 of the data 1310, the computer 1300 rewrites the version number 1313 based on the update time.
  • one computer 1300-1 rewrites the data body 1311-1 of the data 1310-1 on the cache 1320-1 from “D1” to “D2”, and changes the version number 1313-1 from “T1” to “D1”. Rewritten as “T2”. Further, the other computer 1300-2 changes the data body 1311-2 of the data 1310-2 on the cache 1320-2 from “D1” to “D3” at the time after the computer 1300-1 updates the data 1310-1. The version number 1313-2 is rewritten from “T1” to “T3”.
  • Each computer 1300 reflects the data 1310 updated on the cache 1320 in the permanent storage device 1210 of the computer 1200 in preparation for the loss of cache data due to the failure of the computer 1300 itself. Specifically, each computer 1300 periodically executes, for example, an operation of reading updated data 1310 not yet reflected in the persistent storage device 1210 from the cache 1320 and transmitting it to the computer 1200. In the example illustrated in FIG. 15, the computer 1300-1 transmits the updated data 1310-1 to the computer 1200, and the computer 1300-2 transmits the updated data 1310-2 to the computer 1200.
  • the computer 1200 updates the original data 1210 on the permanent storage device 1220 based on the updated data 1310 received from the computer 1300. Specifically, the computer 1200 reads the data 1210 having the same data identifier 1212 as the data identifier 1312 included in the updated data 1310 received from the computer 1300 from the permanent storage device 1220, the version number 1213 of the data 1210 and the above The version number 1313 of the data 1310 is compared. If the update time indicated by the version number 1313 is more recent than the update time indicated by the version number 1213, the computer 1200 displays the data body 1211 and the version number 1213 of the data 1210 on the permanent storage device 1220. The data body 1311 and the version number 1313 of the data 1310 received from the computer 1300 are overwritten.
  • the overwriting as described above is not performed.
  • the data on the permanent storage device 1220 is updated and updated with the updated data having a new update time.
  • data that is not reflected in the permanent storage device is transmitted and received between computers in vain.
  • the computer 1300-2 updates the data 1310-2 at the time after the computer 1300-1 updates the data 1310-1.
  • the computer 1300-1 transmits the updated data 1310-1 to the computer 1200.
  • An event occurs.
  • the computer 1200 updates the data 1210 of the permanent storage device 1220 with the received updated data 1310-2.
  • An object of the present invention is to provide a data write control method for a permanent storage device that solves the above-mentioned problem, that is, the problem that data that does not need to be reflected in the persistent storage device is transmitted and received between computers. There is.
  • a method for controlling data writing to a permanent storage device includes: A first computer and a plurality of second computers, wherein the first computer has a permanent storage device for storing a set of data, identification information of the data, and a version number of the data;
  • the second computer has a cache that holds a copy of the data acquired from the persistent storage device, and controls writing of data on the cache to the persistent storage device in a computer system.
  • the second computer sends confirmation data having the identification information and the version number of the copy data updated on the cache of the own computer to the first computer;
  • the first computer writes the confirmation data received from the second computer to the permanent storage device based on the confirmation data received from the second computer and the storage information of the permanent storage device Extracting the identification information and the version number relating to the necessary copy data, and sending response data having the extracted identification information and the version number to the second computer;
  • the second computer sends the first computer to the first computer for writing to the permanent storage device based on the response data received from the first computer and the storage information of the cache. Determine the copy data.
  • a computer system provides: A first computer; A plurality of second computers;
  • the first computer is A persistent storage device for storing a set of data, identification information of the data, and a version number of the data;
  • a first control unit Each said second computer is A cache that holds copy data of the data obtained from the persistent storage device;
  • a second control unit The second control unit of the second computer transmits confirmation data having the identification information and the version number of the copy data updated on the cache of the own computer to the first computer,
  • the first control unit of the first computer uses the confirmation data received from the second computer based on the confirmation data received from the second computer and the storage information of the permanent storage device.
  • the identification information and the version number relating to the copy data that needs to be written to the permanent storage device are extracted, and response data including the extracted identification information and the version number is transmitted to the second computer And Based on the response data received from the first computer and the storage information in the cache, the second control unit of the second computer transfers the information to the first computer to write to the permanent storage device.
  • the copy data on the cache to be transmitted is determined.
  • a storage computer is: A storage computer connected via a network to a plurality of cache computers each having a cache; A persistent storage device for storing a set of data, identification information of the data, and a version number of the data; A control unit, The controller is Receiving confirmation data having the identification information and the version number of the copy data updated on the cache from the cache computer holding the copy data of the data on the permanent storage device in the cache; Based on the received confirmation data and the storage information of the permanent storage device, the identification information and the version related to the copy data that needs to be written to the permanent storage device from the confirmation data received from the cache computer Extract the number and Response data having the extracted identification information and the version number is transmitted to the cache computer.
  • a cache computer is: A cache computer connected via a network to a storage computer having a permanent storage device for storing a set of data, data identification information and a version number of the data; A cache that holds copy data of the data obtained from the persistent storage device; A control unit, The controller is Sending confirmation data having the identification information and the version number of the copy data updated on the cache to the storage computer; Receiving response data having the identification information and the version number relating to the copy data that needs to be written to the permanent storage device from the storage computer; Based on the received response data and the storage information of the cache, the copy data on the cache to be transmitted to the storage computer for writing to the permanent storage device is determined.
  • a program is: A storage computer connected through a network to a plurality of cache computers each having a cache, A permanent storage device for storing a set of data, identification information of the data, and a version number of the data; Function as a controller, The control unit Receiving confirmation data having the identification information and the version number of the copy data updated on the cache from the cache computer holding the copy data of the data on the permanent storage device in the cache; Based on the received confirmation data and the storage information of the permanent storage device, the identification information and the version related to the copy data that needs to be written to the permanent storage device from the confirmation data received from the cache computer Extract the number and Response data having the extracted identification information and the version number is transmitted to the cache computer.
  • a program is: A cache computer connected through a network to a storage computer having a permanent storage device that stores a set of data, data identification information and a version number of the data; A cache that holds copy data of the data obtained from the persistent storage device; Function as a controller, The control unit Sending confirmation data having the identification information and the version number of the copy data updated on the cache to the storage computer; From the storage computer, receiving response data having the identification information and the version number related to the copy data that needs to be written to the permanent storage device, Based on the received response data and the storage information of the cache, the copy data on the cache to be transmitted to the storage computer for writing to the permanent storage device is determined.
  • the present invention has the above-described configuration, it is possible to prevent data that does not need to be reflected in the permanent storage device from being transmitted and received between computers.
  • FIG. 1 is a block diagram of a distributed processing system according to a first embodiment of the present invention. It is a sequence chart which shows an example of operation
  • a distributed processing system 100 includes a computer 120 and a plurality of computers 130 connected to the computer 120 through a network 110.
  • the computer 120 is a computer such as a storage server (also referred to as a storage node) that permanently stores data.
  • the computer 120 includes, for example, a CPU (Central Processing Unit), a ROM (Read Only Memory), a memory such as a RAM, an external storage device that stores various information, an input / output interface, a communication interface, and a bus that interconnects these. It may be a dedicated or general purpose computer. A plurality of computers 120 may exist.
  • the computer 120 includes a permanent storage device 121 and a control unit 122 as main functional units.
  • the permanent storage device 121 is constituted by a hard disk, for example.
  • the permanent recording device 121 stores the data 1210 permanently.
  • the data 1210 includes a data body 1211, data identification information 1212, and a version number 1213.
  • the data body 1211 is a numerical value or a character string.
  • the data identification information 1212 is an identifier that uniquely identifies the data 1210.
  • the version number 1213 represents the latest time when the data 1210 is updated.
  • the version number is the update time, but the version number in the present invention may be other than the update time as long as the order is determined among a plurality of events.
  • a vector clock (Vector Clock) in a distributed key value store (KVS) called Cassandra may be used as the version number.
  • the control unit 122 manages the main control of the computer 120.
  • the control unit 122 can be realized by a CPU constituting the computer 120 and a program stored in a ROM or the like.
  • Each of the plurality of computers 130 holds a copy of the data 1210 stored in the permanent storage device 121 of the computer 120, and performs a process of referring to and updating the copy of the data 1210 according to a processing request received from a client device (not shown). And a computer such as a server for responding the processing result to the client device.
  • Each computer 130 is, for example, a dedicated or general-purpose computer including a CPU, a memory such as a ROM and a RAM, an external storage device that stores various information, an input / output interface, a communication interface, and a bus that interconnects these. It's okay. Further, although there are two computers 120 in FIG. 1, three or more computers 120 may exist.
  • Each computer 130 includes a cache 131 and a control unit 132.
  • the cache 131 has a function of holding copy data 1310 of data 1210 acquired from the computer 120.
  • the cache 131 is configured by a readable / writable memory such as a RAM.
  • the copy data 1310 on the cache 131 has a data body 1311, identification information 1312, and version number 1313 corresponding to the data body 1211, identification information 1212, and version number 1213 of the original data 1210.
  • the control unit 132 manages the main control of the computer 130.
  • the control unit 132 can be realized by a CPU constituting the computer 130 and a program stored in a ROM or the like.
  • the network 110 is a communication path between the computer 120 and the computer 130.
  • FIG. 2 is a sequence chart showing an example of the operation in the present embodiment. Hereinafter, the operation of the present embodiment will be described with reference to FIGS. 1 and 2.
  • the control unit 132 of each computer 130 obtains frequently used data 1210 from the permanent storage device 121 of the computer 120 and copies it to the cache 131 by communicating with the control unit 122 of the computer 120 (step of FIG. 2). S101, S102).
  • the data 1210 with the data body 1211 “D1”, the identification information “N1”, and the version number “T1” is copied to the cache 131 of each computer 130.
  • control unit 132 of each computer 130 executes processing related to the processing request using the copy data 1310 on the cache 131.
  • the control unit 132 rewrites the version number 1313 based on the update time.
  • one computer 130-1 rewrites the data body 1311-1 of the data 1310-1 on the cache 131-1 from “D1” to “D2” according to the processing request S103, and version number 1313. -1 is rewritten from “T1” to “T2” (S104). Further, at the time after the computer 130-1 updates the data 1310-1, the other computer 130-2 sets the data body 1311-2 of the data 1310-2 in the cache 131-2 to “D1” according to the processing request S105. To “D3”, and the version number 1313-2 is rewritten from “T1” to “T3” (step S106).
  • the control unit 132 of each computer 130 reflects the data 1310 updated on the cache 131 in the permanent storage device 121 of the computer 120 in preparation for the loss of cache data due to the failure of the own computer 130. At that time, the control unit 132 suddenly does not transmit the copy data 1310 including the updated data body 1311 to the computer 120. Instead, the control unit 132 transmits confirmation data having the identification information 1312 and the version number 1313 in the copy data 1310 to the computer 120.
  • the timing at which the control unit 132 of each computer 130 transmits the confirmation data to the computer 120 is arbitrary. For example, each computer 130 reads the updated data 1310 that has not yet been sent confirmation data to the computer 120 from the cache 131 and sends the confirmation data to the computer 120 for a period determined by the computer 130. It may be repeated periodically every time.
  • the computer 130-2 receives confirmation data having the identification information “N1” and the version number “T3” of the updated data 1310-2. It is created and transmitted to the computer 120 (step S107).
  • the control unit 122 of the computer 120 Upon receiving the confirmation data from the computer 130-2, the control unit 122 of the computer 120 creates and transmits response data (step S108).
  • the control unit 122 identifies, based on the received confirmation data and the storage information of the permanent storage device 121, the copy data that needs to be written to the permanent storage device 121 from the received confirmation data. Extract information and version number.
  • the version number “T3” paired with the identification information “N1” in the confirmation data is more recent than the version number “T1” of the data 1210 having the same identification information “N1” on the permanent storage device 121. Therefore, the identification information “N1” and the version number “T3” are extracted from the confirmation data.
  • control unit 122 transmits response data having the extracted identification information “N1” and the version number “T3” to the computer 130-2. If no identification information related to the copy data that needs to be written to the permanent storage device 121 is extracted from the confirmation data, the control unit 122 permanently identifies the identification information in the confirmation data and the identification information. Response data having a pair with the version number of the data 1210 stored in the storage device 121 is created and transmitted to the computer 130-2.
  • the control unit 132 of the computer 130-2 When the control unit 132 of the computer 130-2 receives the response data from the computer 120, the control unit 132 transmits the cache 131- to the computer 120 for persistence based on the received response data and the stored information of the cache 131-2. 2 is determined and transmitted (step S109). Specifically, for each identification information included in the response data, the control unit 132 extracts the version number 1313 of the copy data 1310 having the same identification information as the identification information from the cache 131, and the identification information in the response data. Compare with the version number paired with. Then, the control unit 132 determines and transmits copy data 1310 whose version number extracted from the cache 131 is not older than the version number in the response data as data to be transmitted to the computer 120 in order to make it permanent.
  • the version number “T3” of the copy data 1310-2 having the identification information “N1” on the cache 131-2 is more than the version number “T3” paired with the identification information “N1” in the response data. Therefore, the copy data 1310-2 is determined as data to be transmitted to the computer 120 for perpetuation. Then, the control unit 132 reads the determined copy data 1310-2 from the cache 131-2 and transmits it to the computer 120.
  • the control unit 122 of the computer 120 receives the copy data 1310-2 from the computer 130-2, the received copy data is transferred to the permanent storage device 121 based on the received copy data and the storage information of the permanent storage device 121. Whether or not to write is determined, and when it is determined to write, the writing is performed (step S110). Specifically, for each received copy data, the control unit 122 extracts the version number 1213 of the data 1210 having the same identification information as the identification information from the permanent storage device 121 and compares it with the version number in the copy data. . Then, the control unit 122 determines that the copy data having the latest version number from the version number in the permanent storage device 121 is copy data to be written, and writes the copy data in the permanent storage device 121. In this example, the version number “T3” of the copy data 1310-2 received from the computer 130-2 is more recent than the version number “T1” of the data 1210 on the permanent storage device 121. 1210 is overwritten with the copy data 1310-2.
  • the computer 130-1 transmits confirmation data having the identification information “N1” and the version number “T2” of the updated data 1310-1 to the computer 120 (step S111). .
  • the control unit 122 of the computer 120 Upon receiving the confirmation data from the computer 130-1, the control unit 122 of the computer 120 creates and transmits response data (step S112).
  • the version number “T2” of the data 1310-1 specified by the identification information “N1” in the confirmation data is the version number “T” of the data 1210 having the same identification information “N1” on the permanent storage device 121. Not more recent than T3 ". Therefore, the control unit 122 creates response data having a pair of the identification information “N1” in the confirmation data and the version number “T3” of the data 1210 stored in the permanent storage device 121 corresponding to the identification information. To the computer 130-1.
  • the control unit 132 of the computer 130-1 When the control unit 132 of the computer 130-1 receives the response data from the computer 120, the control unit 132 transmits the cache 131- to the computer 120 for persistence based on the received response data and the stored information in the cache 131-1.
  • the copy data on 1 is determined (step S113).
  • the version number “T2” of the copy data 1310-1 having the identification information “N1” on the cache 131-1 is more than the version number “T3” paired with the identification information “N1” in the response data. Not up to date. Therefore, the control unit 132 determines that the copy data 1310-1 is not transmitted to the computer 120. In this case, the control unit 132 may communicate with the control unit 122 of the computer 120 to acquire the latest data 1210 of the identification information “N1” and copy it to the cache 131-1.
  • each computer 130 does not immediately send the data updated on the cache to the computer 120, exchanges confirmation data and response data with the computer 120, and sends it to the computer 120. This is to determine data to be used.
  • the present embodiment it is possible to prevent network congestion between the computer 120 and the computer 130, thereby preventing a decrease in throughput and response time for perpetuating cache data.
  • the reason for this is that the size of the data identification information and version number is relatively small compared to the data body. This is because the amount of transmission / reception to be reduced increases due to the reduction of.
  • a second embodiment of the present invention will be described.
  • a plurality of server computers (hereinafter referred to as cache nodes) that hold cache data in an on-memory are cached in a server computer (hereinafter referred to as a storage node) that includes a remote hard disk via a communication network.
  • the present invention relates to a system for persisting data (hereinafter referred to as a cache persistence system).
  • a cache persistence system a distributed cache persistence system that is a premise of the present embodiment and its problems, an overview of the present embodiment, effects of the present embodiment, a configuration of the present embodiment, operations of the present embodiment, and examples will be described in this order.
  • the cache data persistence function is an essential function of a database server, application server, web server, or the like.
  • the server returns appropriate data (response data) to the application in response to a data request (data reference / update / addition / deletion, etc.) received from the application.
  • a cache memory is used for the purpose of solving the above problem. Since cache memory can be accessed at high speed compared to storage, data that is frequently accessed is temporarily stored in the cache memory, and the data requested by the application is obtained from the cache memory instead of the storage. Reduce the number of disk IOs and increase the response speed.
  • the cache data persistence function is a function that regularly reflects the cache data on the cache memory in the storage. The reason why this function exists will be described. In general, when a server machine on which a cache memory constituted by a volatile memory operates goes down, cache data temporarily stored in the cache memory disappears. As a result, the data update history applied to the cache data by the application disappears. Therefore, the cache data in the cache memory must be regularly reflected (permanent) in the storage, and the cache data perpetuating system provides this function.
  • a database distributed database constructed by clustering a large number (hundreds to thousands) of servers in a cluster is drawing attention.
  • a distributed database different functions are assigned to each server for the purpose of load distribution (the amount of data stored per server, the number of data processing requests to be processed, etc.) Provides applications with functionality similar to a database.
  • a cache data persistence system used in a distributed database is called a distributed cache data persistence system.
  • the distributed cache data persistence system there are a plurality of cache nodes 1, 2, 3, and a plurality of storage nodes 1, 2, 3, 4, 5, 6 as shown in FIG.
  • the cache node uses the statistical information of the data request from the application (for example, the access frequency measurement value at the table level of the database, etc.) to acquire data with high access frequency from the storage node in advance as cache data, Cache on memory. Since the application can connect to an arbitrary cache node, the cache data 1 stored in the storage node 4 may be cached in the cache node 1 and the cache node 2 in some cases. Cache data 1 cached by the cache node 1 and the cache node 2 is periodically transmitted to the storage node 4.
  • the statistical information of the data request from the application for example, the access frequency measurement value at the table level of the database, etc.
  • the storage node 4 refers to the update history described in the received cache data 1 and appropriately updates the data corresponding to the cache data 1 stored by itself. Specifically, as shown in FIG. 4, the cache data 1 cached by the cache node 1 describes the history updated on the cache node 1 together with the version number. Similarly, the cache data 1 cached by the cache node 2 also describes the history updated on the cache node 2 together with the version number. The storage node 4 matches the cache data 1 of the cache node 1 (update history) with the cache data 1 of the cache node 2 (update history), and has the latest version number 5 described in the cache data 1 of the cache node 2 Update the data 1 stored in the update data 5 and make it permanent.
  • this embodiment provides a distributed cache data persistence system that can prevent deterioration of cache data persistence performance due to network congestion.
  • the cache node 1 of the distributed cache data persistence system generates a confirmation signal (hereinafter referred to as a dial tone) for notifying the storage node 4 of a cache data transmission request.
  • Dial tone generation means 14 is provided.
  • the storage node 4 has busy tone generation means 44 that generates a response signal (hereinafter referred to as busy tone) for notifying the cache node 1 of permission to transmit cache data.
  • the cache node 1 and the storage node 4 use a data line (hereinafter referred to as a heartbeat line) 6 which is a separate line independent of the data line 5 used for transmission of cache data, and a tone for exchanging dial tone and busy tone.
  • the transmitter / receiver 15 and the tone transmitter / receiver 43 are provided.
  • the cache node 1 includes cache data control means 12 that analyzes the busy tone received from the storage node 4 and sorts out cache data to be transmitted to the storage node 4. In the distributed cache data persistence system of this embodiment, there may be different cache nodes and storage nodes having the same means as the cache node 1 and the storage node 4.
  • the cache data can be transferred by simply exchanging dial tones and busy tones for preconditioning the cache data to be transmitted between the multiple cache nodes and the multiple storage nodes.
  • the cache data can be made persistent by preventing deterioration of the cache data persistence performance due to network congestion of the data line that transmits the data.
  • the reason is that a plurality of cache nodes are prevented from redundantly persisting cache data, and only the minimum necessary cache data is transmitted from the cache node to the storage node.
  • the present embodiment includes cache nodes 1, 2, 3, and storage node 4 that can be realized by a computer, a workstation or the like having a data processing function, a data communication function, a data storage function, etc. by program control. Including.
  • FIG. 5 shows a configuration with only three cache nodes and one storage node, there may be more cache nodes and storage nodes having the same means.
  • the cache nodes 1, 2, 3 and the storage node 4 can communicate with each other using the data line 5 and the heartbeat line 6.
  • the data line 5 and the heartbeat line 6 are independent networks, and even when the data line 5 is disconnected, the cache node and the storage node can communicate with each other using the heartbeat line 6.
  • the cache nodes 1, 2 and 3 transmit the cache data to the storage node 4 using the data line 5.
  • the cache nodes 1, 2, 3 and the storage node 4 use the heartbeat line 6 to transmit tones (dial tone, busy tone) for pre-adjusting the cache data to be transmitted.
  • the cache nodes 1, 2, and 3 include a memory cache unit 11, a cache data control unit 12, a data transmission unit 13, a dial tone generation unit 14, and a tone transmission / reception unit 15.
  • the storage node 4 includes data receiving means 41, a disk 42, tone transmission / reception means 43, and busy tone generation means 44.
  • the memory cache means 11 of the cache nodes 1, 2, and 3 temporarily stores frequently accessed data in the cache memory.
  • the cache data control unit 12 periodically acquires cache data from the memory cache unit 11 and transmits the cache data from the data transmission unit 13 to the data reception unit 41 of the storage node 4 using the data line 5.
  • the data receiving means 41 records the received cache data on the disk 42 and makes it permanent.
  • the dial tone generation means 14 of the cache nodes 1, 2, and 3 generates a dial tone indicating a cache data transmission request prior to cache data transmission.
  • the tone transmission / reception unit 15 transmits the generated dial tone to the tone transmission / reception unit 43 of the storage node 4 using the heartbeat line 6.
  • the dial tone history information about cache data to be transmitted by the cache node is described.
  • the busy tone generating means 44 of the storage node 4 generates a busy tone according to the dial tone received from the cache nodes 1, 2 and 3 by the tone transmitting / receiving means 43.
  • the tone transmission / reception unit 43 transmits the generated busy tone to the tone transmission / reception unit 15 of the cache nodes 1, 2, and 3.
  • the storage node 4 analyzes the dial tone received from the cache node, and if there are a plurality of cache nodes that are attempting to transmit duplicate cache data, specifies the cache node that transmits the cache data.
  • the busy tone is transmitted to the cache node.
  • the cache data control means 12 of the cache nodes 1, 2, 3 selects the cache data to be transmitted to the storage node 4 in accordance with the busy tone received by the tone transmission / reception means 15. Specifically, the cache data control unit 12 stores the update data in the data transmission unit 13 only when the update data having a version number that is the same as or newer than the version number of the cache data described in the busy tone is held. Transmit to node 4.
  • the cache nodes 1, 2, and 3 periodically extract cache data temporarily stored in the memory from the memory according to the respective timings of the cache nodes, and start preparation for transmitting the cache data (step A1). Before actually transmitting the cache data, in order to determine the cache data to be transmitted, a dial tone is generated from the update history of the extracted cache data (step A2). The generated dial tone is transmitted via the heartbeat line 6 to the target storage node that persists the cache data extracted in step A1 (step A3).
  • the storage node 4 waits for reception of a dial tone from the cache nodes 1, 2, and 3 over a certain period (step B1).
  • the latest update data is specified for each cache data with reference to the busy tone from the cache nodes 1, 2, and 3 received during a certain period.
  • a busy tone describing a cache node that holds the latest update data for each cache data is generated (step B2).
  • the generated busy tone is transmitted to the cache nodes 1, 2, and 3 (step B3).
  • the cache nodes 1, 2, and 3 refer to the busy tone received from the storage node 4 and specify the cache data to be transmitted by itself (steps A4 and A5). Then, only the cache data specified to be transmitted by itself is transmitted to the storage node 4 (steps A6 and A7).
  • Storage node 4 writes the received cache data to its own disk 42 (steps B4 and B5).
  • the dial tone and busy tone are exchanged between the plurality of cache nodes and the plurality of storage nodes to preliminarily adjust the cache data to be persisted. . Therefore, only the minimum necessary cache data can be transmitted using the data line, and deterioration of cache data perpetuation performance due to network congestion of the data line can be prevented.
  • the distributed data cache nodes 1, 2, 3, and the storage node 4 include a data processing unit such as a CPU, a data communication unit corresponding to an Ethernet, a wireless LAN, a dedicated communication network, etc., a data storage unit such as a RAM, ROM, and HDD. It is realized by a computer, a workstation, a database or the like provided with.
  • FIG. 7 shows an example of a list of cache data possessed by the cache nodes 1, 2, and 3 on the memory at a certain time.
  • a unique identifier (cache data ID) is assigned to the cache data.
  • cache data ID For example, in a cache data persistence system in a relational database, a unique identifier is used for a record for each table such as a primary key of a record as a cache data ID. In the distributed key value store, the cache data ID may use a key value.
  • the data version number and update data are added as history data for each update. Specifically, the version number Tx_y_k and the update data Dx_y_k are additionally written when the cache data (cache data ID) y of the cache node x is updated for the kth time.
  • the cache node 1 persists cache data in the storage node 4.
  • Cache node 1 determines cache data to be transmitted to the storage node 4. For example, there is a method in which cache data whose update history addition count (update history length) exceeds a certain threshold value is determined as cache data to be transmitted. In this example, it is assumed that all of the cache data 1, 2, and 3 shown in FIG.
  • the cache node 1 Before actually sending the latest update data (D1_1_4 in the case of cache data 1) to the storage node 4, the cache node 1 creates a dial tone and sends it to the storage node 4. To do.
  • Cache node 1 sets the ID and latest version number of the cache data to be permanent in the dial tone. Specifically, the cache node 1 creates a dial tone (communication packet) shown in FIG. 8 and transmits it to the storage node 4 via the heartbeat line 6.
  • the cache node 2 transmits a dial tone to the storage node 4 at the same timing as the dial tone transmission of the cache node 1.
  • Cache node 2 sets the ID and latest version number of cache data to be made permanent in the dial tone, similar to the dial tone of cache node 1. Specifically, the cache node 1 creates a dial tone (communication packet) shown in FIG. 9 and transmits it to the storage node 4 via the heartbeat line 6.
  • the storage node 4 that has received the dial tone from the cache nodes 1 and 2 checks whether or not the cache data described in the dial tone has already been made permanent (accumulated). Specifically, in the above confirmation, the storage node 4 uses a persistence table that is a list of version numbers of cache data that has already been persisted in its own node.
  • Fig. 10 shows a configuration example of the persistence table.
  • the storage node 4 does not have an update history of cache data, so the cache data (cache data ID) y that is made permanent in the storage node x is the version Expressed as number Tx_y and update data Dx_y.
  • a null display cell in the persistence table indicates that the cache data (cache data 1 in the case of FIG. 10) has not been persisted in the past.
  • the storage node 4 executes new / old judgment as to which cache data is the latest for each cache data from the busy tone received from the cache nodes 1 and 2 and the persistence table created by itself.
  • servers operating in a distributed cache data persistence system are time-synchronized by NTP (Network Time Protocol) via the heartbeat line 6, so data using version numbers New and old judgments are possible.
  • NTP Network Time Protocol
  • the cache data 2 when the version number of the cache node 1 is T1_2_2, the version number of the cache node 2 is T2_2_3, and the version number of the storage node 4 is T4_2, the cache node 2 When the version number T2_2_3 of 2 is the newest, the cache data D2_2_3 corresponding to the version number T2_2_3 existing on the memory of the cache node 2 should be reflected in the storage node 4 (FIG. 7).
  • the cache data D1_1_4 corresponding to the version number T1_1_4 existing in the memory of the cache node 1 is stored in the storage node Should be reflected in 4.
  • the storage node 4 creates a busy tone as shown in FIG. 11 and transmits it to the cache nodes 1, 2 and 3 via the heartbeat line 6.
  • the version number determined to be new or old as the latest data is described for each cache data.
  • the cache nodes 1, 2, 3 that have received the busy tone from the storage node 4 analyze the busy tone and finally determine the cache data to be perpetuated in the storage node 4.
  • the cache node 1 transmits only the update data D1_1_4 corresponding to the version number T1_1_4 specified in the cache data 1 to the storage node 4 via the data line 5. However, if it owns cache data 1 that is more up-to-date than the version number T1_1_4 in the update history, it sends the latest cache data 1 to the storage node 4 via the data line 5. The same applies to the cache data 2 and 3, and the cache data 2 and 3 that are the same as or more recent than the version number T2_2_3 of the cache data 2 described in the busy tone and the version number T4_3 of the cache data 3 are held. If it is, the latest cache data 2 and 3 that it holds are transmitted to the storage node 4 via the data line 5. Similarly to the cache node 1, the cache node 2 finally determines the cache data to be transmitted, and if there is cache data to be transmitted, the cache data is transmitted to the storage node 4 via the data line 5.
  • the cache node 3 that has not transmitted the dial tone compares the version number T3_1_1 (FIG. 7) of the cache data 1 existing in its own memory with the version number T1_1_4 of the cache data 1 described in the busy tone. If the cache data 1 possessed by the node is the latest, the cache data is transmitted to the storage node 4 via the data line 5.
  • the heartbeat line 6 for transmitting the dial tone and the busy tone and the data line 5 for transmitting the cache data as the actual data are independent networks, but a sufficient communication band is secured.
  • the same network may be used as long as it is possible.
  • the storage node 4 broadcasts the busy tone to all the cache nodes 1, 2, and 3 including the cache node 3 that has not yet transmitted the dial tone, but the busy tone is transmitted only to the cache nodes 1 and 2 that have transmitted the dial tone. You may reply.
  • cache data metadata (cache data ID, version number, etc.) is described in the dial tone and busy tone, and the actual cache data is not described. The reason is to minimize the packet size of dial tone and busy tone to reduce communication traffic on the heartbeat line. However, if the cache data that is actual data is smaller than the threshold value, the cache data may be described in advance in the dial tone and transmitted.
  • this embodiment has the offset time setting means 16 in the cache nodes 1, 2, and 3 in the second embodiment shown in FIG. 5, and the data line congestion detection means 45 in the storage node 4. The difference is that the offset time calculation means 46 is provided.
  • the data line congestion detection unit 45 monitors the data reception unit 41 and detects network congestion that occurs when the cache node makes a large amount of cache data permanent (send) to the same storage node.
  • the offset time calculation means 46 determines the priority for persisting the cache data, calculates the persistence cycle (offset time) for each cache data, and describes the offset time in the busy tone.
  • the offset time setting means 16 analyzes the offset time described in the busy tone, and sets the cache data perpetuation cycle in the data transmission means 13.
  • steps A1, A2, A3, A4, A5, A6, A7, and B1, B2, B3, B4, and B5 in FIG. 13 are the same as those in the second embodiment, and thus the description thereof is omitted.
  • each cache node transmits cache data to the storage node through the data line for persistence at the same timing, that is, when a busy tone is received.
  • the storage node 4 checks the congestion state of the data line 5 (step B6), and if congestion occurs, cache data An offset time is calculated every time (step B7), and a busy tone describing the offset time is generated (step B2).
  • the cache nodes 1, 2, and 3 analyze the busy tone received in step A5, extract the offset time for each cache data (step A8), and correspond to the offset time in a cycle corresponding to the offset time.
  • Cache data is transmitted (steps A6 and A7). That is, the cache data is transmitted at the timing when the offset time has elapsed from the timing when the busy tone is received.
  • the cache data transmission cycle by setting the cache data transmission cycle to the offset time, it is possible to avoid congestion of the data line due to concentration of cache data transmission traffic from the cache node to the storage node in a short time. For this reason, the number of times the cache data is retransmitted due to packet loss due to congestion is reduced, and deterioration of cache data perpetuation performance can be prevented.
  • This example has the same configuration as the example of the second embodiment, but is different from the example of the second embodiment in that the cache nodes 1, 2, and 3 also function as the offset time setting unit 16. Different. Furthermore, the point that the storage node 4 also functions as the data line congestion detection unit 45 and the offset time calculation unit 46 is different from the example of the second embodiment.
  • the storage node 4 monitors its own network interface, measures network parameters (packet loss rate, delay time, etc.), and determines that network congestion has occurred when the measured value exceeds a predefined network parameter threshold. To do.
  • a detection method other than the detection method based on the network parameter value shown in the present embodiment may be used.
  • the storage node 4 calculates an offset time for each cache data described in the received dial tone.
  • the busy tone returned to the cache node is as shown in FIG.
  • the version numbers T1_1_4, T2_2_3, and T4_3 of each of the cache data 1, 2, and 3 identify the cache data with the oldest version number (the oldest update time), and compare it with other cache data. Then, “small value offset time (cache data transmission frequency is high)” is set in the cache data.
  • the offset time calculation method for calculating the offset time by referring only to the dial tone (FIGS. 8 and 9) and the version number described in the persistence table (FIG. 10) is shown. By describing the size of the cache data in the tone, a calculation method or the like that sets “a large value offset time (cache data transmission frequency is low)” for large-sized cache data may be used.
  • the storage node 4 returns a busy tone in which the offset times OFFSET1, OFFSET2, and OFFSET3 calculated for the cache data 1, 2, and 3 are set to the cache node.
  • the offset time setting unit 16 of the cache nodes 1, 2, and 3 analyzes the busy tone received from the storage node 4, and if there is cache data to be transmitted by itself, the offset time setting unit 16 performs the offset time period corresponding to the cache data.
  • the cache data is made permanent (transmitted) to the storage node 4.
  • the present invention has been described above with some embodiments and examples. However, the present invention is not limited to the above examples, and various other additions and modifications are possible.
  • the busy time may be set by calculating the offset time for each cache data described in the received dial tone regardless of the presence or absence of congestion in the data line.
  • the present invention can be applied to uses such as a distributed database system and a program for realizing the distributed database system on a computer.

Abstract

第2のコンピュータは、キャッシュ上で更新したコピーデータの識別情報とバージョン番号とを有する確認データを第1のコンピュータへ送信する。第1のコンピュータは、第2のコンピュータから受信した確認データと永続記憶装置の記憶情報とに基づいて、確認データから、永続記憶装置に書き込む必要のあるコピーデータに係る識別情報とバージョン番号とを抽出し、抽出した識別情報とバージョン番号とを有する応答データを第2のコンピュータへ送信する。第2のコンピュータは、第1のコンピュータから受信した応答データとキャッシュの記憶情報とに基づいて、永続記憶装置へ書き込むために第1のコンピュータへ送信するキャッシュ上のコピーデータを決定する。

Description

永続記憶装置へのデータ書込制御方法
 本発明は、永続記憶装置へのデータ書込制御方法、コンピュータシステム、ストレージコンピュータ、キャッシュコンピュータ、およびプログラムに関する。
 近年、携帯やインターネットが普及するにつれて、扱うデータ量が増え、大量データの処理の高速化が求められている。その中で、大量データを保管するためのシステムとして、キーバリューストア(KVS)の需要が高まっている。キーバリューストアでは、データ(値:value)に対して、対応する一意の標識(key)を設定し、それらをペアで保存する。キーとバリューとをペアにしたデータを、以下、KVデータと呼ぶ。特に、複数のサーバに分散してKVデータを保存できる機能を持ったものは、分散KVSと呼ばれる。分散KVSは、分散データベースの一種であり、スケーラビリティとスループット性を重視するが、データの一貫性(Consistency)は強く要求されないシステムに主に利用されている。
 分散KVSのような分散処理システムにおいて、データの処理性能を向上させるための技術として、キャッシュの利用が知られている。キャッシュの利用とは、使用頻度の高いデータを高速な記憶装置に蓄えておくことにより、いちいち低速な永続記憶装置から読み出す無駄を省いて高速化する技術である(例えば特許文献1参照)。
特開2006-235736号公報
 図15は、キャッシュを利用する、本発明に関連する分散処理システム1000の概念図である。分散処理システム1000は、コンピュータ1200と、コンピュータ1200にネットワーク1100を通じて接続された複数のコンピュータ1300とを有する。
 コンピュータ1200は、データ1210を永続的に記憶する永続記憶装置1220を有する。永続記憶装置1220は、例えばHDD(Hard Disk Drive)で構成される。永続記録装置1220上のデータ1210は、データ本体1211と識別情報1212とバージョン番号1213とを有する。データ本体1211は、数値や文字列などである。識別情報1212は、データ1210を一意に識別する識別子である。バージョン番号1213は、データ1210が更新された最新の時刻を表す。
 複数のコンピュータ1300のそれぞれは、コンピュータ1200の永続記憶装置1220から取得したデータ1210のコピーデータ1310を記憶するキャッシュ1320を有する。キャッシュ1320は、例えばRAM(Random Access Memory)で構成される。データ1310は、オリジナルのデータ1210のデータ本体1211、識別情報1212、バージョン番号1213に対応する、データ本体1311、識別情報1312、バージョン番号1213を有する。
 次に、本発明に関連する分散処理システム1000の動作を説明する。
 各々のコンピュータ1300は、予めコンピュータ1200の永続記憶装置1220からデータ1210を取得してキャッシュ1320にデータ1310としてコピーする。次に各々のコンピュータ1300は、キャッシュ1320上にコピーしたデータ1310を利用して処理を実行する。このとき各々のコンピュータ1300は、データ1310のデータ本体1311を更新したとき、その更新時刻に基づいてバージョン番号1313を書き換える。
 図15では、一方のコンピュータ1300-1が、キャッシュ1320-1上のデータ1310-1のデータ本体1311-1を「D1」から「D2」に書き換え、バージョン番号1313-1を「T1」から「T2」に書き換えている。また、他方のコンピュータ1300-2は、コンピュータ1300-1がデータ1310-1を更新した後の時刻において、キャッシュ1320-2上のデータ1310-2のデータ本体1311-2を「D1」から「D3」に書き換え、バージョン番号1313-2を「T1」から「T3」に書き換えている。
 各々のコンピュータ1300は、自コンピュータ1300の障害発生に伴うキャッシュデータの消失に備えて、キャッシュ1320上で更新したデータ1310をコンピュータ1200の永続記憶装置1210に反映する。具体的には、各々のコンピュータ1300は、永続記憶装置1210に未だ反映していない更新後のデータ1310をキャッシュ1320から読み出してコンピュータ1200へ送信する動作を、例えば定期的に実行する。図15に示す例では、コンピュータ1300-1が更新後のデータ1310-1をコンピュータ1200へ送信し、コンピュータ1300-2が更新後のデータ1310-2をコンピュータ1200へ送信することになる。
 コンピュータ1200は、コンピュータ1300から受信した更新後のデータ1310に基づいて、永続記憶装置1220上のオリジナルのデータ1210を更新する。具体的には、コンピュータ1200は、コンピュータ1300から受信した更新後のデータ1310に含まれるデータ識別子1312と同じデータ識別子1212を有するデータ1210を永続記憶装置1220から読み出し、データ1210のバージョン番号1213と上記データ1310のバージョン番号1313とを比較する。若し、バージョン番号1213が示す更新時刻よりもバージョン番号1313が示す更新時刻の方がより最新であれば、コンピュータ1200は、永続記憶装置1220上のデータ1210のデータ本体1211とバージョン番号1213とを、コンピュータ1300から受信したデータ1310のデータ本体1311とバージョン番号1313とで上書きする。一方、バージョン番号1213が示す更新時刻よりもバージョン番号1313が示す更新時刻の方がより最新でなければ、上述したような上書きは実施しない。このような動作によって、永続記憶装置1220上のデータをより更新時刻の新しい更新後データによって更新して永続化する。
 しかしながら、上記の本発明に関連する分散処理システム1000では、永続記憶装置に反映されないデータがコンピュータ間で無駄に送受信される。例えば、図15に示した例では、コンピュータ1300-1がデータ1310-1を更新した後の時刻に、コンピュータ1300-2がデータ1310-2を更新している。しかし、各コンピュータ1300の反映タイミングにずれがあると、コンピュータ1300-2が更新後データ1310-2をコンピュータ1200に送信した後、コンピュータ1300-1が更新後データ1310-1をコンピュータ1200に送信する事象が発生する。その場合、コンピュータ1200は、コンピュータ1300-2から更新後データ1310-2を受信したときは、受信した更新後データ1310-2で永続記憶装置1220のデータ1210を更新する。しかし、コンピュータ1300-1から更新後データ1310-1を受信したときは、永続記憶装置1220のデータが既に更新後データ1310-2によって更新されているので、更新後データ1310-2より更新時刻の古い更新後データ1310-1による更新は実行されない。この結果、コンピュータ1300-1とコンピュータ1200間で実施された更新後データ1310-1の送受信は無駄になる。
 本発明の目的は、上述した課題、すなわち、永続記憶装置に反映する必要のないデータがコンピュータ間で無駄に送受信される、という課題を解決する永続記憶装置へのデータ書込制御方法を提供することにある。
 本発明の第1の観点に係る永続記憶装置へのデータ書込制御方法は、
 第1のコンピュータと複数の第2のコンピュータとを有し、前記第1のコンピュータは、データと前記データの識別情報と前記データのバージョン番号との組を記憶する永続記憶装置を有し、それぞれの前記第2のコンピュータは、前記永続記憶装置から取得した前記データのコピーデータを保持するキャッシュを有する、コンピュータシステムにおける前記永続記憶装置への前記キャッシュ上のデータの書込みを制御する方法であって、
 前記第2のコンピュータが、自コンピュータの前記キャッシュ上で更新した前記コピーデータの前記識別情報と前記バージョン番号とを有する確認データを前記第1のコンピュータへ送信し、
 前記第1のコンピュータが、前記第2のコンピュータから受信した前記確認データと前記永続記憶装置の記憶情報とに基づいて、前記第2のコンピュータから受信した前記確認データから、前記永続記憶装置に書き込む必要のある前記コピーデータに係る前記識別情報と前記バージョン番号とを抽出し、該抽出した前記識別情報と前記バージョン番号とを有する応答データを前記第2のコンピュータへ送信し、
 前記第2のコンピュータが、前記第1のコンピュータから受信した前記応答データと前記キャッシュの記憶情報とに基づいて、前記永続記憶装置へ書き込むために前記第1のコンピュータへ送信する前記キャッシュ上の前記コピーデータを決定する。
 本発明の第2の観点に係るコンピュータシステムは、
 第1のコンピュータと、
 複数の第2のコンピュータとを有し、
 前記第1のコンピュータは、
 データと前記データの識別情報と前記データのバージョン番号との組を記憶する永続記憶装置と、
 第1の制御部と
を有し、
 それぞれの前記第2のコンピュータは、
 前記永続記憶装置から取得した前記データのコピーデータを保持するキャッシュと、
 第2の制御部と
を有し、
 前記第2のコンピュータの前記第2の制御部は、自コンピュータの前記キャッシュ上で更新した前記コピーデータの前記識別情報と前記バージョン番号とを有する確認データを前記第1のコンピュータへ送信し、
 前記第1のコンピュータの前記第1の制御部は、前記第2のコンピュータから受信した前記確認データと前記永続記憶装置の記憶情報とに基づいて、前記第2のコンピュータから受信した前記確認データから、前記永続記憶装置に書き込む必要のある前記コピーデータに係る前記識別情報と前記バージョン番号とを抽出し、該抽出した前記識別情報と前記バージョン番号とを有する応答データを前記第2のコンピュータへ送信し、
 前記第2のコンピュータの前記第2の制御部は、前記第1のコンピュータから受信した前記応答データと前記キャッシュの記憶情報とに基づいて、前記永続記憶装置へ書き込むために前記第1のコンピュータへ送信する前記キャッシュ上の前記コピーデータを決定する。
 本発明の第3の観点に係るストレージコンピュータは、
 それぞれがキャッシュを有する複数のキャッシュコンピュータにネットワークを通じて接続されたストレージコンピュータであって、
 データと前記データの識別情報と前記データのバージョン番号との組を記憶する永続記憶装置と、
 制御部と
を有し、
 前記制御部は、
 前記永続記憶装置上の前記データのコピーデータを前記キャッシュに保持する前記キャッシュコンピュータから前記キャッシュ上で更新した前記コピーデータの前記識別情報と前記バージョン番号とを有する確認データを受信し、
 前記受信した前記確認データと前記永続記憶装置の記憶情報とに基づいて、前記キャッシュコンピュータから受信した前記確認データから、前記永続記憶装置に書き込む必要のある前記コピーデータに係る前記識別情報と前記バージョン番号とを抽出し、
 前記抽出した前記識別情報と前記バージョン番号とを有する応答データを前記キャッシュコンピュータへ送信する。
 本発明の第4の観点に係るキャッシュコンピュータは、
 データと前記データの識別情報と前記データのバージョン番号との組を記憶する永続記憶装置を有するストレージコンピュータにネットワークを通じて接続されたキャッシュコンピュータであって、
 前記永続記憶装置から取得した前記データのコピーデータを保持するキャッシュと、
 制御部と
を有し、
 前記制御部は、
 前記キャッシュ上で更新した前記コピーデータの前記識別情報と前記バージョン番号とを有する確認データを前記ストレージコンピュータへ送信し、
 前記ストレージコンピュータから、前記永続記憶装置に書き込む必要のある前記コピーデータに係る前記識別情報と前記バージョン番号とを有する応答データを受信し、
 前記受信した前記応答データと前記キャッシュの記憶情報とに基づいて、前記永続記憶装置へ書き込むために前記ストレージコンピュータへ送信する前記キャッシュ上の前記コピーデータを決定する。
 本発明の第5の観点に係るプログラムは、
 それぞれがキャッシュを有する複数のキャッシュコンピュータにネットワークを通じて接続されたストレージコンピュータを、
 データと上記データの識別情報と上記データのバージョン番号との組を記憶する永続記憶装置と、
 制御部と
して機能させ、
 上記制御部は、
 上記永続記憶装置上の上記データのコピーデータを上記キャッシュに保持する上記キャッシュコンピュータから上記キャッシュ上で更新した上記コピーデータの上記識別情報と上記バージョン番号とを有する確認データを受信し、
 上記受信した上記確認データと上記永続記憶装置の記憶情報とに基づいて、上記キャッシュコンピュータから受信した上記確認データから、上記永続記憶装置に書き込む必要のある上記コピーデータに係る上記識別情報と上記バージョン番号とを抽出し、
 上記抽出した上記識別情報と上記バージョン番号とを有する応答データを上記キャッシュコンピュータへ送信する。
 本発明の第6の観点に係るプログラムは、
 データと上記データの識別情報と上記データのバージョン番号との組を記憶する永続記憶装置を有するストレージコンピュータにネットワークを通じて接続されたキャッシュコンピュータを、
 上記永続記憶装置から取得した上記データのコピーデータを保持するキャッシュと、
 制御部と
して機能させ、
 上記制御部は、
 上記キャッシュ上で更新した上記コピーデータの上記識別情報と上記バージョン番号とを有する確認データを上記ストレージコンピュータへ送信し、
 上記ストレージコンピュータから、上記永続記憶装置に書き込む必要のある上記コピーデータに係る上記識別情報と上記バージョン番号とを有する応答データを受信し、
 上記受信した上記応答データと上記キャッシュの記憶情報とに基づいて、上記永続記憶装置へ書き込むために上記ストレージコンピュータへ送信する上記キャッシュ上の上記コピーデータを決定する。
 本発明は上述した構成を有するため、永続記憶装置に反映する必要のないデータがコンピュータ間で無駄に送受信されるのを防止することができる。
本発明の第1の実施形態に係る分散処理システムのブロック図である。 本発明の第1の実施形態に係る分散処理システムの動作の一例を示すシーケンスチャートである。 本発明の第2の実施形態の前提となる分散キャッシュデータ永続化システムを説明するための図である。 本発明の第2の実施形態の前提となる分散キャッシュデータ永続化システムのキャッシュデータの構成を説明するための図である。 本発明の第2の実施形態のブロック図である。 本発明の第2の実施形態の動作を示す流れ図である。 本発明の第2の実施形態におけるキャッシュデータの構成を説明するための図である。 本発明の第2の実施形態におけるキャッシュノードが送信するダイヤルトーンの一例を説明するための図である。 本発明の第2の実施形態におけるキャッシュノードが送信するダイヤルトーンの他の例を説明するための図である。 本発明の第2の実施形態におけるストレージノードが有する永続化テーブルを説明するための図である。 本発明の第2の実施形態におけるストレージノードが送信するビジートーンを説明するための図である。 本発明の第3の実施形態のブロック図である。 本発明の第3の実施形態の動作を示す流れ図である。 本発明の第3の実施形態におけるストレージノードが送信するビジートーンを説明するための図である。 本発明に関連する分散処理システムの概念図である。
 次に本発明の実施の形態について図面を参照して詳細に説明する。
[第1の実施形態]
 図1を参照すると、本発明の第1の実施形態に係る分散処理システム100は、コンピュータ120と、このコンピュータ120にネットワーク110を通じて接続された複数のコンピュータ130とを有する。
 コンピュータ120は、データを永続的に記憶するストレージサーバ(ストレージノードとも称す)などのコンピュータである。コンピュータ120は、例えば、CPU(CentralProcessingUnit)、ROM(Read Only Memory)やRAM等のメモリ、各種の情報を格納する外部記憶装置、入出力インターフェース、通信インターフェース、およびこれらを相互に接続するバスを備える専用または汎用のコンピュータであってよい。またコンピュータ120は、複数存在してよい。
 コンピュータ120は、主な機能部として、永続記憶装置121と制御部122とを有する。
 永続記憶装置121は、例えばハードディスクで構成される。永続記録装置121はデータ1210を永続的に記憶する。データ1210は、データ本体1211とデータ識別情報1212とバージョン番号1213とを有する。データ本体1211は、数値や文字列などである。データ識別情報1212は、データ1210を一意に識別する識別子である。バージョン番号1213は、データ1210が更新された最新の時刻を表す。ここでは、バージョン番号は更新時刻としたが、本発明におけるバージョン番号は複数のイベント間で順序が決まるものであれば更新時刻以外のものであってよい。例えば、カサンドラ(Cassandra)と呼ばれる分散キーバリューストア(KVS)におけるベクタークロック(Vector Clock)をバージョン番号としてもよい。
 制御部122は、コンピュータ120の主たる制御を司る。制御部122は、コンピュータ120を構成するCPUとROM等に記憶されたプログラムとで実現することができる。
 複数のコンピュータ130のそれぞれは、コンピュータ120の永続記憶装置121に記憶されたデータ1210のコピーを保持し、図示しないクライアント装置から受信した処理要求に従って、データ1210のコピーを参照、更新する処理を実施し、処理結果をクライアント装置へ応答するサーバなどのコンピュータである。各コンピュータ130は、例えば、CPU、ROMやRAM等のメモリ、各種の情報を格納する外部記憶装置、入出力インターフェース、通信インターフェース、およびこれらを相互に接続するバスを備える専用または汎用のコンピュータであってよい。またコンピュータ120は、図1では2台であるが、3台以上存在してもよい。
 各々のコンピュータ130は、キャッシュ131と制御部132とを有する。
 キャッシュ131は、コンピュータ120から取得したデータ1210のコピーデータ1310を保持する機能を有する。キャッシュ131は、RAM等の書込み読み出し可能なメモリで構成される。キャッシュ131上のコピーデータ1310は、オリジナルのデータ1210が有するデータ本体1211、識別情報1212、バージョン番号1213に対応する、データ本体1311、識別情報1312、バージョン番号1313を有する。
 制御部132は、コンピュータ130の主たる制御を司る。制御部132は、コンピュータ130を構成するCPUとROM等に記憶されたプログラムとで実現することができる。
 ネットワーク110は、コンピュータ120とコンピュータ130との間の通信路である。
 図2は、本実施形態における動作の一例を示すシーケンスチャートである。以下、図1および図2を参照して、本実施形態の動作を説明する。
 各々のコンピュータ130の制御部132は、コンピュータ120の制御部122と通信することにより、利用頻度の高いデータ1210をコンピュータ120の永続記憶装置121から取得してキャッシュ131にコピーする(図2のステップS101、S102)。ここでは、データ本体1211が「D1」、識別情報が「N1」、バージョン番号が「T1」のデータ1210が各々のコンピュータ130のキャッシュ131にコピーされたものとする。
 その後、各々のコンピュータ130の制御部132は、キャッシュ131上のコピーデータ1310を利用して、処理要求に係る処理を実行する。このとき制御部132は、コピーデータ1310のデータ本体1311を更新したとき、その更新時刻に基づいてバージョン番号1313を書き換える。
 図2に示す例では、一方のコンピュータ130-1が、処理要求S103に従って、キャッシュ131-1上のデータ1310-1のデータ本体1311-1を「D1」から「D2」に書き換え、バージョン番号1313-1を「T1」から「T2」に書き換えている(S104)。また、他方のコンピュータ130-2が、コンピュータ130-1がデータ1310-1を更新した後の時刻において、処理要求S105に従って、キャッシュ131-2のデータ1310-2のデータ本体1311-2を「D1」から「D3」に書き換え、バージョン番号1313-2を「T1」から「T3」に書き換えている(ステップS106)。
 各々のコンピュータ130の制御部132は、自コンピュータ130の障害発生に伴うキャッシュデータの消失に備えて、キャッシュ131上で更新したデータ1310をコンピュータ120の永続記憶装置121に反映する。その際、制御部132は、更新したデータ本体1311を含むコピーデータ1310をいきなりコンピュータ120に送信しない。その代わりに、制御部132は、コピーデータ1310中の識別情報1312とバージョン番号1313とを有する確認データをコンピュータ120に送信する。各々のコンピュータ130の制御部132が確認データをコンピュータ120に送信するタイミングは任意である。例えば、各々のコンピュータ130は、確認データをコンピュータ120に未だ送信していない更新後のデータ1310をキャッシュ131から読み出し、その確認データをコンピュータ120へ送信する動作を、自コンピュータ130で定められた期間毎に周期的に繰り返してよい。
 図2に示す例では、コンピュータ130-1、130-2の内、最初にコンピュータ130-2が、更新後のデータ1310-2の識別情報「N1」とバージョン番号「T3」を有する確認データを作成してコンピュータ120へ送信している(ステップS107)。
 コンピュータ120の制御部122は、コンピュータ130-2から上記確認データを受信すると、応答データを作成して送信する(ステップS108)。この応答データの作成では、まず制御部122は、受信した確認データと永続記憶装置121の記憶情報とに基づいて、受信した確認データから、永続記憶装置121に書き込む必要のあるコピーデータに係る識別情報とバージョン番号とを抽出する。今の例では、確認データ中の識別情報「N1」と組を成すバージョン番号「T3」は、永続記憶装置121上の同じ識別情報「N1」を有するデータ1210のバージョン番号「T1」より最新であるため、識別情報「N1」とバージョン番号「T3」とが確認データから抽出される。次に制御部122は、上記抽出した識別情報「N1」とバージョン番号「T3」とを有する応答データをコンピュータ130-2へ送信する。なお、確認データから永続記憶装置121に書き込む必要のあるコピーデータに係る識別情報が1つも抽出されなかった場合、制御部122は、確認データ中の識別情報と、その識別情報に対応して永続記憶装置121に記憶されているデータ1210のバージョン番号との組を有する応答データを作成してコンピュータ130-2に送信する。
 コンピュータ130-2の制御部132は、コンピュータ120から上記応答データを受信すると、受信した応答データとキャッシュ131-2の記憶情報とに基づいて、永続化するためにコンピュータ120へ送信するキャッシュ131-2上のコピーデータを決定し、送信する(ステップS109)。具体的には、制御部132は、応答データに含まれる識別情報毎に、その識別情報と同じ識別情報を有するコピーデータ1310のバージョン番号1313をキャッシュ131から抽出し、応答データ中の当該識別情報と組みを成すバージョン番号と比較する。そして、制御部132は、キャッシュ131から抽出したバージョン番号が応答データ中のバージョン番号よりも古くないコピーデータ1310を、永続化するためにコンピュータ120へ送信するデータとして決定し、送信する。今の例では、キャッシュ131-2上の識別情報「N1」を有するコピーデータ1310-2のバージョン番号「T3」は、応答データ中の識別情報「N1」と組を成すバージョン番号「T3」よりも古くないため、コピーデータ1310-2が永続化のためにコンピュータ120へ送信するデータとして決定される。そして、制御部132は、上記決定したコピーデータ1310-2をキャッシュ131-2から読み出して、コンピュータ120へ送信する。
 コンピュータ120の制御部122は、コンピュータ130-2から上記コピーデータ1310-2を受信すると、受信したコピーデータと永続記憶装置121の記憶情報とに基づいて、受信したコピーデータを永続記憶装置121へ書き込むか否かを決定し、書き込むと決定した場合にその書き込みを行う(ステップS110)。具体的には、制御部122は、受信したコピーデータ毎に、その識別情報と同じ識別情報を有するデータ1210のバージョン番号1213を永続記憶装置121から抽出し、コピーデータ中のバージョン番号と比較する。そして、制御部122は、永続記憶装置121中のバージョン番号よりも最新のバージョン番号を有するコピーデータは、書き込むべきコピーデータと決定し、永続記憶装置121に書き込む。今の例では、コンピュータ130-2から受信したコピーデータ1310-2のバージョン番号「T3」は、永続記憶装置121上のデータ1210のバージョン番号「T1」より最新なので、永続記憶装置121上のデータ1210をコピーデータ1310-2で上書きする。
 その後、図2に示す例では、コンピュータ130-1が、更新後のデータ1310-1の識別情報「N1」とバージョン番号「T2」を有する確認データをコンピュータ120へ送信している(ステップS111)。
 コンピュータ120の制御部122は、コンピュータ130-1から上記確認データを受信すると、応答データを作成して送信する(ステップS112)。今の例では、確認データ中の識別情報「N1」で特定されるデータ1310-1のバージョン番号「T2」は、永続記憶装置121上の同じ識別情報「N1」を有するデータ1210のバージョン番号「T3」より最新でない。そのため制御部122は、確認データ中の識別情報「N1」と、その識別情報に対応して永続記憶装置121に記憶されているデータ1210のバージョン番号「T3」との組を有する応答データを作成してコンピュータ130-1に送信する。
 コンピュータ130-1の制御部132は、コンピュータ120から上記応答データを受信すると、受信した応答データとキャッシュ131-1の記憶情報とに基づいて、永続化するためにコンピュータ120へ送信するキャッシュ131-1上のコピーデータを決定する(ステップS113)。今の例では、キャッシュ131-1上の識別情報「N1」を有するコピーデータ1310-1のバージョン番号「T2」は、応答データ中の識別情報「N1」と組を成すバージョン番号「T3」より最新でない。そのため制御部132は、コピーデータ1310-1はコンピュータ120へは送信しないと決定する。この場合、制御部132は、コンピュータ120の制御部122と通信して、識別情報「N1」の最新のデータ1210を取得してキャッシュ131-1にコピーしてよい。
 このように本実施形態によれば、永続記憶装置に反映する必要のないデータがコンピュータ間で無駄に送受信されるのを防止することができる。その理由は、各々のコンピュータ130は、キャッシュ上で更新したデータをいきなりコンピュータ120に送信せずに、コンピュータ120との間で確認データと応答データとを交換して、コンピュータ120に対して送信すべきデータを決定するためである。
 また本実施形態によれば、コンピュータ120とコンピュータ130間のネットワークの輻輳を防止でき、それによってキャッシュデータを永続化するスループットやレスポンスタイムの低下を防止することができる。その理由は、データの識別情報とバージョン番号のサイズはデータ本体に比べて相対的に小さいため、確認データと応答データとの交換によって増加する送受信量よりも、データ本体を含む無駄なデータの送受信が削減されることによって低減する送受信量の方が多くなるためである。
[第2の実施形態]
 次に、本発明の第2の実施形態について説明する。本実施形態は、キャッシュデータをオンメモリで保持する複数のサーバコンピュータ(以下、キャッシュノードと記す)が通信ネットワークを介して遠隔地のハードディスクを具備するサーバコンピュータ(以下、ストレージノードと記す)にキャッシュデータを永続化するシステム(以下、キャッシュ永続化システムと記す)に関する。以下では、本実施形態の前提となる分散キャッシュ永続化システムとその課題、本実施形態の概要、本実施形態の効果、本実施形態の構成、本実施形態の動作、実施例の順に説明する。
<本実施形態の前提となる分散キャッシュ永続化システムとその課題>
 キャッシュデータ永続化機能は、データベースサーバ、アプリケーションサーバ、ウェブサーバ等の必須機能である。上記サーバは、アプリケーションから受信するデータリクエスト(データの参照・更新・追加・削除等)に対して、適切なデータ(レスポンスデータ)をアプリケーションに返却する。
 アプリケーションに返却するレスポンスデータを作成する際に、ストレージ(サーバの内蔵ハードディスク等)に蓄積したデータに逐次アクセスすると、ディスクIOが多発するためレスポンス速度が低速となる問題がある。上記問題を解決することを目的としてキャッシュメモリを使用する。キャッシュメモリは、ストレージと比較して高速にデータアクセスが可能であるため、アクセス頻度の高いデータをキャッシュメモリに一時保存し、アプリケーションが要求するデータをストレージではなくてキャッシュメモリから取得することで、ディスクIO回数を削減してレスポンス速度を高速化する。
 キャッシュデータ永続化機能とは、キャッシュメモリ上のキャッシュデータを定期的にストレージに反映する機能である。本機能が存在する理由を説明する。一般に揮発性メモリで構成するキャッシュメモリが動作するサーバマシンがダウンした場合、キャッシュメモリに一時保存したキャッシュデータは消滅する。この結果、アプリケーションがキャッシュデータに適用したデータ更新履歴が消滅することになる。よって、キャッシュメモリのキャッシュデータは定期的にストレージに反映(永続化)する必要があり、本機能を提供するのがキャッシュデータ永続化システムである。
 近年データベースに蓄積するデータ量の大規模化が進み、多数(数百~数千台)のサーバをクラスタ化して構築するデータベース(分散データベース)が注目されている。分散データベースでは、負荷分散(サーバ1台当たりの蓄積するデータ量、処理するデータ処理要求数等)を目的として各サーバに異なる機能を付与し、それらサーバが協調動作することで分散データベースでない通常のデータベースと同様の機能をアプリケーションに提供する。
 分散データベースで使用されるキャッシュデータ永続化システムを分散キャッシュデータ永続化システムと呼ぶ。分散キャッシュデータ永続化システムでは、図3に示すように、複数のキャッシュノード1、2、3、複数のストレージノード1、2、3、4、5、6が存在する。物理サーバ1台に対してキャッシュノードおよびストレージノードを同居することも可能であるが、一般に負荷分散の観点で別の物理サーバに構築する。
 キャッシュノードは、アプリケーションからのデータリクエストの統計情報(例えば、データベースのテーブルレベルでのアクセス頻度測定値等)を用いて、アクセス頻度の高いデータをキャッシュデータとしてストレージノードから予め取得して、自身のメモリ上にキャッシュする。アプリケーションは任意のキャッシュノードに接続できるので、ストレージノード4が蓄積するキャッシュデータ1がキャッシュノード1およびキャッシュノード2にキャッシュされるケースもある。キャッシュノード1およびキャッシュノード2がキャッシュするキャッシュデータ1は、定期的にストレージノード4に送信される。
 ストレージノード4は、受信したキャッシュデータ1に記載されている更新履歴を参照して、自身が蓄積するキャッシュデータ1に該当するデータを適切に更新する。具体的には、図4に示すように、キャッシュノード1がキャッシュするキャッシュデータ1には、キャッシュノード1上で更新した履歴がバージョン番号と共に記載されている。同様にキャッシュノード2がキャッシュするキャッシュデータ1にも、キャッシュノード2上で更新した履歴がバージョン番号と共に記載されている。ストレージノード4は、キャッシュノード1のキャッシュデータ1(更新履歴)とキャッシュノード2のキャッシュデータ1(更新履歴)を突き合わせて、キャッシュノード2のキャッシュデータ1に記載されている最も新しいバージョン番号5の更新データ5で自身が蓄積するデータ1を更新して永続化する。
 上記分散キャッシュデータ永続化システムには、同一のキャッシュデータを保存するキャッシュノード数が増大した場合に、ネットワーク輻輳が発生して、キャッシュデータ永続化性能(スループット、レスポンスタイム等)が低下する、という課題がある。その理由は、同一のキャッシュデータを保存するキャッシュノードはお互いの所有するキャッシュデータの更新履歴に関する情報を把握していないため、キャッシュノードは全てキャッシュデータの更新履歴をストレージノードに送信するからである。
 そこで本実施形態では、ネットワーク輻輳によるキャッシュデータ永続化性能の劣化を防止できる分散キャッシュデータ永続化システムを提供する。
<本実施形態の概要>
 図5に示すように、本実施形態の分散キャッシュデータ永続化システムのキャッシュノード1は、キャッシュデータの送信要求をストレージノード4に通知するための確認信号(以下、ダイヤルトーンと記す)を生成するダイヤルトーン生成手段14を有する。ストレージノード4は、キャッシュデータの送信許可をキャッシュノード1に通知するための応答信号(以下、ビジートーンと記す)を生成するビジートーン生成手段44を有する。キャッシュノード1およびストレージノード4は、キャッシュデータの送信で使用するデータ回線5とは独立した別回線であるデータ回線(以下、ハートビート回線と記す)6を使ってダイヤルトーンおよびビジートーンを交換するトーン送受信手段15およびトーン送受信手段43を有する。キャッシュノード1は、ストレージノード4から受信したビジートーンを解析してストレージノード4に送信するキャッシュデータを取捨選別するキャッシュデータ制御手段12を有する。本実施形態の分散キャッシュデータ永続化システムには、キャッシュノード1およびストレージノード4と同一の手段を有する異なるキャッシュノードおよびストレージノードが存在してもよい。
<本実施形態の効果>
 このような構成を採用し、キャッシュデータの送信に先立ってキャッシュノードとストレージノード間で送信するキャッシュデータを事前調整することで、実際に送信するキャッシュデータの全体量を圧縮できるため、上記課題を解決することができる。
 また、データ回線とは独立したハートビート回線を利用して複数のキャッシュノードと複数のストレージノード間で送信するキャッシュデータを事前調整するためのダイヤルトーンおよびビジートーンを事前に交換するだけで、キャッシュデータを送信するデータ回線のネットワーク輻輳によるキャッシュデータ永続化性能の劣化を防止してキャッシュデータを永続化することができる。
 その理由は、複数のキャッシュノードが冗長にキャッシュデータを永続化することを防止して、必要最低限のキャッシュデータだけをキャッシュノードからストレージノードに送信するからである。
<本実施形態の構成>
 図5を参照すると、本実施形態は、プログラム制御によるデータ処理機能、データ通信機能、データ記憶機能等を具備するコンピュータ、ワークステーション等で実現できるキャッシュノード1、2、3、およびストレージノード4を含む。図5では、キャッシュノードが3台、ストレージノードが1台だけの構成を示しているが、同一手段を有するキャッシュノードおよびストレージノードがさらに多く存在しても良い。
 キャッシュノード1、2、3とストレージノード4は、データ回線5とハートビート回線6を使用して相互に通信可能である。データ回線5とハートビート回線6は独立したネットワークであり、データ回線5が断線した場合でもハートビート回線6を使ってキャッシュノードとストレージノードは通信可能である。キャッシュノード1、2、3は、データ回線5を使ってキャッシュデータをストレージノード4に送信する。キャッシュノード1、2、3とストレージノード4は、ハートビート回線6を使って、送信するキャッシュデータを事前調整するためのトーン(ダイヤルトーン、ビジートーン)を送信する。
 キャッシュノード1、2、3は、メモリキャッシュ手段11と、キャッシュデータ制御手段12と、データ送信手段13と、ダイヤルトーン生成手段14と、トーン送受信手段15とを備える。
 ストレージノード4は、データ受信手段41と、ディスク42と、トーン送受信手段43と、ビジートーン生成手段44とを備える。
 キャッシュノード1、2、3のメモリキャッシュ手段11は、アクセス頻度の高いデータをキャッシュメモリに一時保存する。キャッシュデータ制御手段12は、メモリキャッシュ手段11からキャッシュデータを定期的に取得して、データ送信手段13からデータ回線5を使用してストレージノード4のデータ受信手段41に送信する。データ受信手段41は、受信したキャッシュデータをディスク42に記録して永続化する。
 キャッシュノード1、2、3のダイヤルトーン生成手段14は、キャッシュデータ送信に先立ってキャッシュデータの送信要求を示すダイヤルトーンを生成する。トーン送受信手段15は、生成したダイヤルトーンを、ハートビート回線6を使用してストレージノード4のトーン送受信手段43に送信する。ダイヤルトーンにはキャッシュノードが送信しようとしているキャッシュデータに関する履歴情報が記載されている。
 ストレージノード4のビジートーン生成手段44は、トーン送受信手段43でキャッシュノード1、2、3から受信したダイヤルトーンに応じてビジートーンを生成する。トーン送受信手段43は、生成したビジートーンをキャッシュノード1、2、3のトーン送受信手段15に送信する。具体的には、ストレージノード4は、キャッシュノードから受信したダイヤルトーンを分析して、重複したキャッシュデータを送信しようとしているキャッシュノードが複数存在する場合は、当該キャッシュデータを送信するキャッシュノードを指定したビジートーンをキャッシュノードに送信する。
 キャッシュノード1、2、3のキャッシュデータ制御手段12は、トーン送受信手段15が受信したビジートーンに応じて、ストレージノード4に送信するキャッシュデータを取捨選択する。具体的には、キャッシュデータ制御手段12は、ビジートーンに記載されている当該キャッシュデータのバージョン番号と同じか或いはそれよりも新しいバージョン番号の更新データを保持している場合だけデータ送信手段13でストレージノード4に送信する。
<本実施形態の動作>
 次に、図5および図6を参照して本実施形態の動作について詳細に説明する。
 キャッシュノード1、2、3は、キャッシュノードそれぞれのタイミングに従ってメモリ上に一時保存するキャッシュデータを上記メモリから定期的に抽出して、キャッシュデータの送信準備を開始する(ステップA1)。キャッシュデータを実際に送信する前に、送信するべきキャッシュデータを決定するために、抽出したキャッシュデータの更新履歴からダイヤルトーンを生成する(ステップA2)。生成したダイヤルトーンを、ステップA1で抽出したキャッシュデータを永続化する対象ストレージノードに対して、ハートビート回線6を介して送信する(ステップA3)。
 ストレージノード4は、一定期間に渡ってキャッシュノード1、2、3からのダイヤルトーンの受信を待機する(ステップB1)。次に、一定期間中に受信したキャッシュノード1、2、3からのビジートーンを参照して、キャッシュデータ毎に最新の更新データを特定する。次に、キャッシュデータ毎に最新の更新データを保持するキャッシュノードを記載したビジートーンを生成する(ステップB2)。そして、生成したビジートーンをキャッシュノード1、2、3に送信する(ステップB3)。
 キャッシュノード1、2、3は、ストレージノード4から受信したビジートーンを参照して、自身が送信するべきキャッシュデータを特定する(ステップA4、A5)。そして、自身が送信するべきと特定したキャッシュデータだけをストレージノード4に送信する(ステップA6、A7)。
 ストレージノード4は、受信したキャッシュデータを自身のディスク42に書き込む(ステップB4、B5)。
 このように本実施形態では、データ回線とは独立したハートビート回線を利用して、複数のキャッシュノードと複数のストレージノード間でダイヤルトーンおよびビジートーンを交換して永続化するキャッシュデータを事前調整する。このためデータ回線を使用して必要最低限のキャッシュデータだけを送信できてデータ回線のネットワーク輻輳によるキャッシュデータ永続化性能の劣化を防止できる。
<実施例>
 次に、第2の実施形態の実施例を、図面を参照して説明する。
 本実施形態を実現するシステムの物理構成を説明する。分散データキャッシュノード1、2、3、およびストレージノード4は、CPU等のデータ処理部、イーサネット、無線LAN、専用通信ネットワーク等に対応したデータ通信部、RAM、ROM、HDD等のデータ記憶部等を備えるコンピュータ、ワークステーション、データベース等により実現される。
 ある時刻でキャッシュノード1、2、3がメモリ上に所持するキャッシュデータの一覧の例を図7に示す。図7に示すように、キャッシュデータにはユニークな識別子(キャッシュデータID)を付与する。例えば、リレーショナルデータベースにおけるキャッシュデータ永続化システムでは、キャッシュデータIDは、レコードのプライマリキー等のテーブル毎のレコードにユニークな識別子が使用される。また分散キーバリューストアでは、キャッシュデータIDは、キー値を使用してよい。
 また、キャッシュデータには、データのバージョン番号および更新データが更新毎に履歴データとして追記される。具体的には、キャッシュノードxのキャッシュデータ(キャッシュデータID)yのk回目の更新時には、バージョン番号Tx_y_kおよび更新データDx_y_kが追記される。
 図7に記載のキャッシュデータ1、2、3は、ストレージノード4に永続化されるキャッシュデータであるケースを想定する。
 キャッシュノード1が、ストレージノード4にキャッシュデータを永続化するケースを想定する。
 キャッシュノード1は、ストレージノード4に送信するキャッシュデータを決定する。例えば、更新履歴の追記回数(更新履歴長)が一定の閾値を超えるキャッシュデータを、送信するキャッシュデータと決定する方法がある。本例では、図7に記載のキャッシュデータ1、2、3の全てを送信するケースを想定する。
 キャッシュノード1は、実際にキャッシュデータ1、2、3の最新の更新データ(キャッシュデータ1の場合はD1_1_4)をストレージノード4に送信する前に、ダイヤルトーンを作成して、ストレージノード4に送信する。
 キャッシュノード1は、ダイヤルトーンに永続化するキャッシュデータのIDおよび最新バージョン番号を設定する。具体的には、キャッシュノード1は、図8に示すダイヤルトーン(通信パケット)を作成して、ハートビート回線6を介してストレージノード4に送信する。
 キャッシュノード1のダイヤルトーン送信と同タイミングで、キャッシュノード2がダイヤルトーンをストレージノード4に送信するケースを想定する。
 キャッシュノード2は、キャッシュノード1のダイヤルトーンと同様に、ダイヤルトーンに永続化するキャッシュデータのIDおよび最新バージョン番号を設定する。具体的には、キャッシュノード1は、図9に示すダイヤルトーン(通信パケット)を作成して、ハートビート回線6を介してストレージノード4に送信する。
 キャッシュノード1、2からのダイヤルトーンを受信したストレージノード4は、ダイヤルトーンに記載されているキャッシュデータが自身に既に永続化(蓄積)されているかを確認する。具体的には、上記確認では、ストレージノード4は、自ノードに既に永続化したキャッシュデータのバージョン番号の一覧である永続化テーブルを使用する。
 図10は永続化テーブルの構成例である。一般的には、ストレージノード4は、キャッシュノード1、2、3とは異なり、キャッシュデータの更新履歴は保有しないため、ストレージノードxに永続化されたキャッシュデータ(キャッシュデータID)yは、バージョン番号Tx_yおよび更新データDx_yと表現する。永続化テーブル中のNULL表示のセルは、当該キャッシュデータ(図10の場合はキャッシュデータ1)が過去に永続化されていないこと示す。
 ストレージノード4は、キャッシュノード1、2から受信したビジートーンおよび自身が作成した永続化テーブルから、キャッシュデータ毎にいずれのキャッシュデータが最新であるかの新旧判断を実行する。
 一般的に、分散キャッシュデータ永続化システムで動作するサーバ(キャッシュノード、ストレージノード等)はハートビート回線6を介してNTP(Network Time Protocol)で時刻同期しているため、バージョン番号を用いたデータの新旧判断が可能である。
 キャッシュデータ2については、キャッシュノード1のバージョン番号がT1_2_2であり、キャッシュノード2のバージョン番号がT2_2_3であり、ストレージノード4のバージョン番号がT4_2である場合に、これらを新旧比較した結果、キャッシュノード2のバージョン番号T2_2_3が最も新しい場合は、キャッシュノード2のメモリ上に存在するバージョン番号T2_2_3に対応するキャッシュデータD2_2_3がストレージノード4に反映されるべきである(図7)。
 キャッシュデータ1に関しては、キャッシュノード2のダイヤルトーンおよびストレージノード4の永続化テーブルにキャッシュデータ1が存在しないため、キャッシュノード1のメモリ上に存在するバージョン番号T1_1_4に対応するキャッシュデータD1_1_4がストレージノード4に反映されるべきである。
 キャッシュデータ3に関しては、ストレージノード4の永続化テーブルに記載のバージョン番号T4_3に対応するデータD4_3が最新であったケースを想定する。本ケースは、キャッシュノード1、2以外の別キャッシュノードが、キャッシュノード1、2のメモリ上に存在するキャッシュデータ3と比較して更新時刻が最新であるキャッシュデータ3を既に永続化したことを示している。
 このような状況の下では、ストレージノード4は、図11に示すようなビジートーンを作成して、ハートビート回線6を介してキャッシュノード1、2、3に送信する。
 ビジートーンには、図11に示すように、キャッシュデータ毎に最新データであると新旧判断したバージョン番号を記載する。
 ストレージノード4からビジートーンを受信したキャッシュノード1,2、3は、ビジートーンを分析して、自身がストレージノード4に永続化するキャッシュデータを最終決定する。
 キャッシュノード1は、キャッシュデータ1に指定されたバージョン番号T1_1_4に該当する更新データD1_1_4だけを、データ回線5を介してストレージノード4に送信する。但し、自身が更新履歴にバージョン番号T1_1_4と比較して、さらに最新であるキャッシュデータ1を保有している場合は当該最新のキャッシュデータ1を、データ回線5を介してストレージノード4に送信する。キャッシュデータ2、3についても同様であり、ビジートーン記載のキャッシュデータ2のバージョン番号T2_2_3、キャッシュデータ3のバージョン番号T4_3と比較して、同じか或いはさらに最新であるキャッシュデータ2、3を保有している場合は、保有しているより最新のキャッシュデータ2、3を、データ回線5を介してストレージノード4に送信する。キャッシュノード2もキャッシュノード1と同様に送信するべきキャッシュデータを最終決定して、送信するべきキャッシュデータが存在すれば当該キャッシュデータを、データ回線5を介してストレージノード4に送信する。
 一方、ダイヤルトーンを送信していないキャッシュノード3は、自身のメモリ上に存在するキャッシュデータ1のバージョン番号T3_1_1(図7)を、ビジートーン記載のキャッシュデータ1のバージョン番号T1_1_4と比較して、自身が所持するキャッシュデータ1が最新であれば当該キャッシュデータを、データ回線5を介してストレージノード4に送信する。
 ビジートーンを送信した後にキャッシュノードから返信されるキャッシュデータ(当該キャッシュデータのバージョン番号を含む)を受信したストレージノード4は、自身が既に永続化している当該キャッシュデータのバージョン番号よりも最新である場合のみ受信したキャッシュデータ(当該キャッシュデータのバージョン番号を含む)で上書き更新する。そして、永続化テーブルを更新する。
 以上の実施例では、ダイヤルトーンおよびビジートーンを送信するためのハートビート回線6と、実データであるキャッシュデータを送信するためのデータ回線5とを独立したネットワークとしたが、十分な通信帯域を確保できるネットワークであれば同一のネットワークを使用してもよい。
 さらに、ストレージノード4は、ビジートーンを、ダイヤルトーンを未送信であるキャッシュノード3を含めて全キャッシュノード1、2、3にブロードキャストしたが、ビジートーンはダイヤルトーンを送信したキャッシュノード1、2だけに返信してもよい。
 さらに、ダイヤルトーンおよびビジートーンにはキャッシュデータのメタデータ(キャッシュデータID、バージョン番号等)を記載するだけで、実データであるキャッシュデータは記載しなかった。その理由は、ダイヤルトーンおよびビジートーンのパケットサイズを最小化して、ハートビート回線の通信トラヒックを軽減するためである。しかし、実データであるキャッシュデータが閾値より小さい場合は、ダイヤルトーンに予めキャッシュデータを記載して送信してもよい。
[第3の実施形態]
 次に、本発明の第3の実施形態について図面を参照して詳細に説明する。
 図12を参照すると、本実施形態は、図5に示された第2の実施形態におけるキャッシュノード1、2、3にオフセット時間設定手段16を有し、ストレージノード4にデータ回線輻輳検知手段45、オフセット時間計算手段46を有する点で異なる。
 データ回線輻輳検出手段45は、データ受信手段41を監視して、キャッシュノードが大量キャッシュデータを同一ストレージノードに永続化(送信)することで発生するネットワーク輻輳を検出する。
 オフセット時間計算手段46は、キャッシュデータを永続化する優先度を決定して、キャッシュデータ毎の永続化周期(オフセット時間)を計算して、ビジートーンにオフセット時間を記載する。
 オフセット時間設定手段16は、ビジートーンに記載されたオフセット時間を分析して、キャッシュデータの永続化周期をデータ送信手段13に設定する。
 次に図12および図13を参照して、本実施形態の動作について詳細に説明する。なお、図13のステップA1,A2、A3、A4、A5、A6、A7、およびB1、B2、B3、B4、B5については、第2の実施形態の動作と同一のため説明は省略する。
 第2の実施形態では、各々のキャッシュノードは、キャッシュデータを同一のタイミング、すなわちビジートーンを受信したタイミングで、データ回線を通じてストレージノードへ永続化のために送信していた。これに対して本実施の形態では、ストレージノード4は、ステップB1でダイヤルトーンを受信した後に、データ回線5の輻輳状態を確認して(ステップB6)、輻輳が発生している場合はキャッシュデータ毎にオフセット時間を計算して(ステップB7)、オフセット時間を記載したビジートーンを生成する(ステップB2)。一方、キャッシュノード1、2、3は、ステップA5で受信したビジートーンを分析して、キャッシュデータ毎のオフセット時間を抽出し(ステップA8)、オフセット時間に相当する周期で、当該オフセット時間に相当するキャッシュデータを送信する(ステップA6、A7)。すなわち、ビジートーンを受信したタイミングからオフセット時間だけ経過したタイミングで、キャッシュデータを送信する。
 次に、本実施の形態の効果について説明する。
 本実施の形態では、キャッシュデータ送信周期をオフセット時間に設定することで、キャッシュノードからストレージノードへのキャッシュデータ送信トラヒックが短時間に集中することによるデータ回線の輻輳を回避できる。このため輻輳によるパケットロスでキャッシュデータを再送する回数が減少するので、キャッシュデータ永続化性能の劣化を防止できる。
 以下、第3の実施形態の実施例を説明する。
 本実施例は、第2の実施形態の実施例と構成を同じとするが、キャッシュノード1、2、3が、オフセット時間設定手段16としても機能する点で第2の実施形態の実施例と異なる。さらに、ストレージノード4が、データ回線輻輳検出手段45、オフセット時間計算手段46としても機能する点が、第2の実施形態の実施例と異なる。
 ストレージノード4のデータ回線輻輳検出手段45、オフセット時間計算手段46がキャッシュデータ毎にキャッシュデータの送信周期であるオフセット時間を計算する方法を説明する。
 ストレージノード4は、自身のネットワークインターフェースを監視して、ネットワークパラメータ(パケットロス率、遅延時間等)を測定し、測定値が予め規定したネットワークパラメータ閾値を超えた時点でネットワーク輻輳が発生したと判断する。ネットワーク輻輳状態の検出方法は、本実施例で示したネットワークパラメータ値に基づく検出方法以外の検出方法を使用してもよい。
 ストレージノード4は、データ回線における輻輳を検出した場合、受信したダイヤルトーンに記載されているキャッシュデータ毎のオフセット時間を計算する。
 本実施例では、キャッシュノードに返信するビジートーンが図11のようになるケースを想定する。この場合、キャッシュデータ1、2、3それぞれのバージョン番号T1_1_4、T2_2_3、T4_3を参照して、最もバージョン番号が古い(更新された時刻が古い)キャッシュデータを特定して、他キャッシュデータと比較して「小さな値のオフセット時間(キャッシュデータ送信頻度が高い)」を当該キャッシュデータに設定する。本実施例では、ダイヤルトーン(図8、図9)および永続化テーブル(図10)に記載のバージョン番号だけを参照して、オフセット時間を計算するオフセット時間計算方法を示したが、例えば、ダイヤルトーンにキャッシュデータのサイズを記載することで、サイズの大きいキャッシュデータに「大きな値のオフセット時間(キャッシュデータ送信頻度が低い)」を設定する計算方法等を使用してもよい。
 ストレージノード4は、図14に示すように、キャッシュデータ1、2、3それぞれに対して計算したオフセット時間OFFSET1、OFFSET2、OFFSET3を設定したビジートーンをキャッシュノードに返信する。
 キャッシュノード1、2、3のオフセット時間設定手段16は、ストレージノード4から受信したビジートーンを分析して、自身が送信するキャッシュデータが存在する場合は当該キャッシュデータに該当するオフセット時間の周期で当該キャッシュデータをストレージノード4に永続化(送信)する。
 以上、本発明を幾つかの実施形態および実施例を挙げて説明したが、本発明は以上の例に限定されず、その他各種の付加変更が可能である。例えば、第3の実施形態では、データ回線における輻輳を検出した場合に、受信したダイヤルトーンに記載されているキャッシュデータ毎のオフセット時間を計算してビジートーンに設定するようにした。しかし、本発明の他の実施形態として、データ回線における輻輳の有無にかかわらず、受信したダイヤルトーンに記載されているキャッシュデータ毎のオフセット時間を計算してビジートーンに設定してもよい。
 なお、本発明は、日本国にて2013年6月12日に特許出願された特願2013-123717の特許出願に基づく優先権主張の利益を享受するものであり、当該特許出願に記載された内容は、全て本明細書に含まれるものとする。
 本発明によれば、分散データベースシステムや、分散データベースシステムをコンピュータで実現するためのプログラムといった用途に適用できる。
1…第1のキャッシュノード
11…メモリキャッシュ手段
12…キャッシュデータ制御手段
13…データ送信手段
14…ダイヤルトーン生成手段
15…トーン送受信手段
16…オフセット時間設定手段
2…第2のキャッシュノード
3…第3のキャッシュノード
4…ストレージノード
41…データ受信手段
42…ディスク
43…トーン送受信手段
44…ビジートーン生成手段
45…データ回線輻輳検出手段
46…オフセット時間計算手段
100…分散処理システム
110…ネットワーク
120…コンピュータ
121…永続記憶装置
122…制御部
130…コンピュータ
131…キャッシュ
132…制御部

Claims (18)

  1.  第1のコンピュータと複数の第2のコンピュータとを有し、前記第1のコンピュータは、データと前記データの識別情報と前記データのバージョン番号との組を記憶する永続記憶装置を有し、それぞれの前記第2のコンピュータは、前記永続記憶装置から取得した前記データのコピーデータを保持するキャッシュを有する、コンピュータシステムにおける前記永続記憶装置への前記キャッシュ上のデータの書込みを制御する方法であって、
     前記第2のコンピュータが、自コンピュータの前記キャッシュ上で更新した前記コピーデータの前記識別情報と前記バージョン番号とを有する確認データを前記第1のコンピュータへ送信し、
     前記第1のコンピュータが、前記第2のコンピュータから受信した前記確認データと前記永続記憶装置の記憶情報とに基づいて、前記第2のコンピュータから受信した前記確認データから、前記永続記憶装置に書き込む必要のある前記コピーデータに係る前記識別情報と前記バージョン番号とを抽出し、該抽出した前記識別情報と前記バージョン番号とを有する応答データを前記第2のコンピュータへ送信し、
     前記第2のコンピュータが、前記第1のコンピュータから受信した前記応答データと前記キャッシュの記憶情報とに基づいて、前記永続記憶装置へ書き込むために前記第1のコンピュータへ送信する前記キャッシュ上の前記コピーデータを決定する
    永続記憶装置へのデータ書込制御方法。
  2.  前記第2のコンピュータは、前記コピーデータの決定では、前記応答データ中の識別情報を有する前記キャッシュ上のコピーデータであって前記バージョン番号が前記応答データ中の前記バージョン番号より古くないコピーデータを、前記第1のコンピュータへ送信する前記コピーデータとして決定する
    請求項1に記載の永続記憶装置へのデータ書込制御方法。
  3.  前記第1のコンピュータは、前記応答データの送信では、前記確認データに対する応答データを、前記確認データを送信した前記第2のコンピュータと前記確認データを送信していない前記第2のコンピュータとの双方に送信する
    請求項1または2に記載の永続記憶装置へのデータ書込制御方法。
  4.  前記第1のコンピュータは、前記応答データの送信では、複数の前記第2のコンピュータから相前後して受信した前記確認データと前記永続記憶装置の記憶情報とに基づいて、複数の前記第2のコンピュータから受信した前記確認データから、前記永続記憶装置に書き込む必要のある前記コピーデータに係る前記識別情報と前記バージョン番号とを抽出し、該抽出した前記識別情報と前記バージョン番号とを有する応答データを前記第2のコンピュータへ送信する
    請求項1乃至3の何れかに記載の永続記憶装置へのデータ書込制御方法。
  5.  前記第1のコンピュータは、前記応答データの送信では、前記応答データに含まれる前記識別情報と前記バージョン番号との或る組に対して他の組とは値の相違するオフセット時間を記載した前記応答データを前記第2のコンピュータへ送信し、
     前記第2のコンピュータは、前記第1のコンピュータから受信した前記応答データに記載された前記オフセット時間に基づいて、前記決定した前記コピーデータの送信タイミングを制御する
    請求項1乃至4の何れかに記載の永続記憶装置へのデータ書込制御方法。
  6.  前記第1のコンピュータは、前記応答データの送信では、前記第2のコンピュータと前記コピーデータの送受信を行うネットワークの混雑状況を検出し、一定以上の混雑状況の場合には、前記応答データに含まれる前記識別情報と前記バージョン番号との或る組に対して他の組とは値の相違するオフセット時間を記載した前記応答データを前記第2のコンピュータへ送信し、
     前記第2のコンピュータは、前記第1のコンピュータから受信した前記応答データに記載された前記オフセット時間に基づいて、前記決定した前記コピーデータの送信タイミングを制御する
    請求項1乃至4の何れかに記載の永続記憶装置へのデータ書込制御方法。
  7.  前記第1のコンピュータと前記第2のコンピュータとは、前記確認データおよび前記応答データを第1のネットワークを通じて送受信し、前記コピーデータを第2のネットワークを通じて送受信する
    請求項1乃至6の何れかに記載の永続記憶装置へのデータ書込制御方法。
  8.  第1のコンピュータと、
     複数の第2のコンピュータとを有し、
     前記第1のコンピュータは、
     データと前記データの識別情報と前記データのバージョン番号との組を記憶する永続記憶装置と、
     第1の制御部と
    を有し、
     それぞれの前記第2のコンピュータは、
     前記永続記憶装置から取得した前記データのコピーデータを保持するキャッシュと、
     第2の制御部と
    を有し、
     前記第2のコンピュータの前記第2の制御部は、自コンピュータの前記キャッシュ上で更新した前記コピーデータの前記識別情報と前記バージョン番号とを有する確認データを前記第1のコンピュータへ送信し、
     前記第1のコンピュータの前記第1の制御部は、前記第2のコンピュータから受信した前記確認データと前記永続記憶装置の記憶情報とに基づいて、前記第2のコンピュータから受信した前記確認データから、前記永続記憶装置に書き込む必要のある前記コピーデータに係る前記識別情報と前記バージョン番号とを抽出し、該抽出した前記識別情報と前記バージョン番号とを有する応答データを前記第2のコンピュータへ送信し、
     前記第2のコンピュータの前記第2の制御部は、前記第1のコンピュータから受信した前記応答データと前記キャッシュの記憶情報とに基づいて、前記永続記憶装置へ書き込むために前記第1のコンピュータへ送信する前記キャッシュ上の前記コピーデータを決定する
    コンピュータシステム。
  9.  前記第2の制御部は、前記コピーデータの決定では、前記応答データ中の識別情報を有する前記キャッシュ上のコピーデータであって前記バージョン番号が前記応答データ中の前記バージョン番号より古くないコピーデータを、前記第1のコンピュータへ送信する前記コピーデータとして決定する
    請求項8に記載のコンピュータシステム。
  10.  前記第1の制御部は、前記応答データの送信では、前記確認データに対する応答データを、前記確認データを送信した前記第2のコンピュータと前記確認データを送信していない前記第2のコンピュータとの双方に送信する
    請求項8または9に記載のコンピュータシステム。
  11.  前記第1の制御部は、前記応答データの送信では、複数の前記第2のコンピュータから相前後して受信した前記確認データと前記永続記憶装置の記憶情報とに基づいて、複数の前記第2のコンピュータから受信した前記確認データから、前記永続記憶装置に書き込む必要のある前記コピーデータに係る前記識別情報と前記バージョン番号とを抽出し、該抽出した前記識別情報と前記バージョン番号とを有する応答データを前記第2のコンピュータへ送信する
    請求項8乃至10の何れかに記載のコンピュータシステム。
  12.  前記第1の制御部は、前記応答データの送信では、前記応答データに含まれる前記識別情報と前記バージョン番号との或る組に対して他の組とは値の相違するオフセット時間を記載した前記応答データを前記第2のコンピュータへ送信し、
     前記第2の制御は、前記第1のコンピュータから受信した前記応答データに記載された前記オフセット時間に基づいて、前記決定した前記コピーデータの送信タイミングを制御する
    請求項8乃至11の何れかに記載のコンピュータシステム。
  13.  前記第1の制御部は、前記応答データの送信では、前記第2のコンピュータと前記コピーデータの送受信を行うネットワークの混雑状況を検出し、一定以上の混雑状況の場合には、前記応答データに含まれる前記識別情報と前記バージョン番号との或る組に対して他の組とは値の相違するオフセット時間を記載した前記応答データを前記第2のコンピュータへ送信し、
     前記第2の制御部は、前記第1のコンピュータから受信した前記応答データに記載された前記オフセット時間に基づいて、前記決定した前記コピーデータの送信タイミングを制御する
    請求項8乃至11の何れかに記載のコンピュータシステム。
  14.  前記第1の制御部と前記第2の制御部とは、前記確認データおよび前記応答データを第1のネットワークを通じて送受信し、前記コピーデータを第2のネットワークを通じて送受信する
    請求項8乃至13の何れかに記載のコンピュータシステム。
  15.  それぞれがキャッシュを有する複数のキャッシュコンピュータにネットワークを通じて接続されたストレージコンピュータであって、
     データと前記データの識別情報と前記データのバージョン番号との組を記憶する永続記憶装置と、
     制御部と
    を有し、
     前記制御部は、
     前記永続記憶装置上の前記データのコピーデータを前記キャッシュに保持する前記キャッシュコンピュータから前記キャッシュ上で更新した前記コピーデータの前記識別情報と前記バージョン番号とを有する確認データを受信し、
     前記受信した前記確認データと前記永続記憶装置の記憶情報とに基づいて、前記キャッシュコンピュータから受信した前記確認データから、前記永続記憶装置に書き込む必要のある前記コピーデータに係る前記識別情報と前記バージョン番号とを抽出し、
     前記抽出した前記識別情報と前記バージョン番号とを有する応答データを前記キャッシュコンピュータへ送信する
    ストレージコンピュータ。
  16.  データと前記データの識別情報と前記データのバージョン番号との組を記憶する永続記憶装置を有するストレージコンピュータにネットワークを通じて接続されたキャッシュコンピュータであって、
     前記永続記憶装置から取得した前記データのコピーデータを保持するキャッシュと、
     制御部と
    を有し、
     前記制御部は、
     前記キャッシュ上で更新した前記コピーデータの前記識別情報と前記バージョン番号とを有する確認データを前記ストレージコンピュータへ送信し、
     前記ストレージコンピュータから、前記永続記憶装置に書き込む必要のある前記コピーデータに係る前記識別情報と前記バージョン番号とを有する応答データを受信し、
     前記受信した前記応答データと前記キャッシュの記憶情報とに基づいて、前記永続記憶装置へ書き込むために前記ストレージコンピュータへ送信する前記キャッシュ上の前記コピーデータを決定する
    キャッシュコンピュータ。
  17.  それぞれがキャッシュを有する複数のキャッシュコンピュータにネットワークを通じて接続されたストレージコンピュータを、
     データと前記データの識別情報と前記データのバージョン番号との組を記憶する永続記憶装置と、
     制御部と
    して機能させ、
     前記制御部は、
     前記永続記憶装置上の前記データのコピーデータを前記キャッシュに保持する前記キャッシュコンピュータから前記キャッシュ上で更新した前記コピーデータの前記識別情報と前記バージョン番号とを有する確認データを受信し、
     前記受信した前記確認データと前記永続記憶装置の記憶情報とに基づいて、前記キャッシュコンピュータから受信した前記確認データから、前記永続記憶装置に書き込む必要のある前記コピーデータに係る前記識別情報と前記バージョン番号とを抽出し、
     前記抽出した前記識別情報と前記バージョン番号とを有する応答データを前記キャッシュコンピュータへ送信する
    プログラム。
  18.  データと前記データの識別情報と前記データのバージョン番号との組を記憶する永続記憶装置を有するストレージコンピュータにネットワークを通じて接続されたキャッシュコンピュータを、
     前記永続記憶装置から取得した前記データのコピーデータを保持するキャッシュと、
     制御部と
    して機能させ、
     前記制御部は、
     前記キャッシュ上で更新した前記コピーデータの前記識別情報と前記バージョン番号とを有する確認データを前記ストレージコンピュータへ送信し、
     前記ストレージコンピュータから、前記永続記憶装置に書き込む必要のある前記コピーデータに係る前記識別情報と前記バージョン番号とを有する応答データを受信し、
     前記受信した前記応答データと前記キャッシュの記憶情報とに基づいて、前記永続記憶装置へ書き込むために前記ストレージコンピュータへ送信する前記キャッシュ上の前記コピーデータを決定する
    プログラム。
PCT/JP2014/002620 2013-06-12 2014-05-19 永続記憶装置へのデータ書込制御方法 WO2014199568A1 (ja)

Priority Applications (3)

Application Number Priority Date Filing Date Title
US14/893,998 US9767023B2 (en) 2013-06-12 2014-05-19 Method of controlling data writing to persistent storage device
JP2015522498A JPWO2014199568A1 (ja) 2013-06-12 2014-05-19 永続記憶装置へのデータ書込制御方法
CN201480033917.XA CN105339906B (zh) 2013-06-12 2014-05-19 控制对永久存储设备的数据写入的方法

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2013-123717 2013-06-12
JP2013123717 2013-06-12

Publications (1)

Publication Number Publication Date
WO2014199568A1 true WO2014199568A1 (ja) 2014-12-18

Family

ID=52021890

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP2014/002620 WO2014199568A1 (ja) 2013-06-12 2014-05-19 永続記憶装置へのデータ書込制御方法

Country Status (4)

Country Link
US (1) US9767023B2 (ja)
JP (1) JPWO2014199568A1 (ja)
CN (1) CN105339906B (ja)
WO (1) WO2014199568A1 (ja)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016143095A1 (ja) * 2015-03-11 2016-09-15 株式会社日立製作所 計算機システム及びトランザクション処理の管理方法
CN111182014A (zh) * 2018-11-09 2020-05-19 北京华为数字技术有限公司 一种数据同步方法和装置

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113448971A (zh) * 2020-03-24 2021-09-28 北京字节跳动网络技术有限公司 基于分布式系统的数据更新方法、计算节点和存储介质
CN111651464B (zh) * 2020-04-15 2024-02-23 北京皮尔布莱尼软件有限公司 数据处理方法、系统及计算设备

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000089996A (ja) * 1998-09-16 2000-03-31 Nec Corp 情報処理装置およびデータベースシステム
JP2000339211A (ja) * 1999-05-25 2000-12-08 Casio Comput Co Ltd ファイル処理装置、ファイル処理システム、及び記憶媒体
JP2005216167A (ja) * 2004-01-30 2005-08-11 Toshiba Corp データベース管理システム、データベース管理方法、データベース登録要求プログラムおよびデータベース管理プログラム

Family Cites Families (16)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2507235B2 (ja) * 1994-06-24 1996-06-12 インターナショナル・ビジネス・マシーンズ・コーポレイション クライアント・サ―バ・コンピュ―タ・システム、及びそのクライアント・コンピュ―タ、サ―バ・コンピュ―タ、並びにオブジェクト更新方法
WO2006012418A2 (en) * 2004-07-21 2006-02-02 Beach Unlimited Llc Distributed storage architecture based on block map caching and vfs stackable file system modules
JP2006235736A (ja) 2005-02-22 2006-09-07 Ricoh Co Ltd クラスタシステムのキャッシュ同期制御方法
TWI320534B (en) 2006-06-23 2010-02-11 Qisda Corp State synchronization systems and methods
JP5223191B2 (ja) * 2006-12-18 2013-06-26 東レ株式会社 射出成形用加飾シート
US20100198789A1 (en) 2007-06-06 2010-08-05 Kunio Kamimura Database contradiction solution method
US8214700B2 (en) * 2009-10-28 2012-07-03 Sandisk Technologies Inc. Non-volatile memory and method with post-write read and adaptive re-write to manage errors
US8930686B2 (en) * 2009-12-23 2015-01-06 International Business Machines Corporation Deduplication of encrypted data
JP5984355B2 (ja) 2010-10-22 2016-09-06 株式会社インテック 分散型データベースシステムおよび分散型データ処理システム
US8849825B1 (en) * 2010-12-23 2014-09-30 Amazon Technologies, Inc. System and method for clustering distributed hash table entries
US8868500B2 (en) 2011-01-14 2014-10-21 Apple Inc. Data synchronization
US8499121B2 (en) * 2011-08-31 2013-07-30 Hewlett-Packard Development Company, L.P. Methods and apparatus to access data in non-volatile memory
US8700683B2 (en) * 2011-10-24 2014-04-15 Nokia Corporation Method and apparatus for providing a key-value based storage interface
US9075710B2 (en) * 2012-04-17 2015-07-07 SanDisk Technologies, Inc. Non-volatile key-value store
US9332083B2 (en) * 2012-11-21 2016-05-03 International Business Machines Corporation High performance, distributed, shared, data grid for distributed Java virtual machine runtime artifacts
US9262323B1 (en) * 2012-11-26 2016-02-16 Amazon Technologies, Inc. Replication in distributed caching cluster

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000089996A (ja) * 1998-09-16 2000-03-31 Nec Corp 情報処理装置およびデータベースシステム
JP2000339211A (ja) * 1999-05-25 2000-12-08 Casio Comput Co Ltd ファイル処理装置、ファイル処理システム、及び記憶媒体
JP2005216167A (ja) * 2004-01-30 2005-08-11 Toshiba Corp データベース管理システム、データベース管理方法、データベース登録要求プログラムおよびデータベース管理プログラム

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
TAKAMICHI TATEOKA ET AL.: "PFS: A Dynamically Adaptive File System for Networking Environments", COMPUTER SOFTWARE, vol. 15, no. 2, 16 March 1998 (1998-03-16), pages 62 - 81 *
TAKUYA ARAKI ET AL.: "A masterless DB synchronization system and its application to a seamless video watching system", IPSJ SIG NOTES, vol. 2006, no. 14, 17 February 2006 (2006-02-17), pages 299 - 304 *
TOSHIO TONOUCHI ET AL.: "Persistent caching algorithm on distributed environment", IEICE TECHNICAL REPORT, vol. 90, no. 144, 20 July 1990 (1990-07-20), pages 1 - 6 *

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016143095A1 (ja) * 2015-03-11 2016-09-15 株式会社日立製作所 計算機システム及びトランザクション処理の管理方法
US10747777B2 (en) 2015-03-11 2020-08-18 Hitachi, Ltd. Computer system and transaction processing management method
CN111182014A (zh) * 2018-11-09 2020-05-19 北京华为数字技术有限公司 一种数据同步方法和装置
CN111182014B (zh) * 2018-11-09 2022-04-26 北京华为数字技术有限公司 一种数据同步方法和装置

Also Published As

Publication number Publication date
JPWO2014199568A1 (ja) 2017-02-23
CN105339906B (zh) 2018-07-20
US20160110285A1 (en) 2016-04-21
US9767023B2 (en) 2017-09-19
CN105339906A (zh) 2016-02-17

Similar Documents

Publication Publication Date Title
JP5548829B2 (ja) 計算機システム、データ管理方法及びデータ管理プログラム
JP5952960B2 (ja) 計算機システム、計算機システム管理方法及びプログラム
US8290899B2 (en) Group stamping style asynchronous replication utilizing a loosely-accurate global clock
US9026679B1 (en) Methods and apparatus for persisting management information changes
EP3612954B1 (en) Replication lag-constrained deletion of data in a large-scale distributed data storage system
CN110377570B (zh) 节点切换方法、装置、计算机设备及存储介质
US9330108B2 (en) Multi-site heat map management
US8671151B2 (en) Maintaining item-to-node mapping information in a distributed system
CN107644030B (zh) 分布式数据库数据同步方法、相关装置及系统
US20080243950A1 (en) Advanced clock synchronization technique
US10114848B2 (en) Ensuring the same completion status for transactions after recovery in a synchronous replication environment
US10726042B2 (en) Replication control using eventually consistent meta-data
WO2012045245A1 (zh) 一种保持数据一致性的方法及系统
JP5686034B2 (ja) クラスタシステム、同期制御方法、サーバ装置および同期制御プログラム
WO2014199568A1 (ja) 永続記憶装置へのデータ書込制御方法
CN112084258A (zh) 一种数据同步方法和装置
CN101237415A (zh) 一种实现arp协议ip核的方法
CN103501319A (zh) 一种低延迟的面向小文件的分布式存储系统
CN112307119A (zh) 数据同步方法、装置、设备及存储介质
CN107436904B (zh) 数据获取方法、数据获取设备和计算机可读存储介质
CN113703917B (zh) 一种多集群资源数据处理系统与方法、非暂态存储介质
CN113190620B (zh) Redis集群之间数据的同步方法、装置、设备及存储介质
Deftu et al. A scalable conflict-free replicated set data type
WO2012046585A1 (ja) 分散ストレージシステム、その制御方法、およびプログラム
WO2022085000A1 (en) Systems, methods, and media for implementing conflict-free replicated data types in in-memory data structures

Legal Events

Date Code Title Description
WWE Wipo information: entry into national phase

Ref document number: 201480033917.X

Country of ref document: CN

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 14811511

Country of ref document: EP

Kind code of ref document: A1

ENP Entry into the national phase

Ref document number: 2015522498

Country of ref document: JP

Kind code of ref document: A

WWE Wipo information: entry into national phase

Ref document number: 14893998

Country of ref document: US

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 14811511

Country of ref document: EP

Kind code of ref document: A1