JPS63129428A - Lock management control system - Google Patents

Lock management control system

Info

Publication number
JPS63129428A
JPS63129428A JP27574386A JP27574386A JPS63129428A JP S63129428 A JPS63129428 A JP S63129428A JP 27574386 A JP27574386 A JP 27574386A JP 27574386 A JP27574386 A JP 27574386A JP S63129428 A JPS63129428 A JP S63129428A
Authority
JP
Japan
Prior art keywords
resource
management
lock
processes
managing
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
JP27574386A
Other languages
Japanese (ja)
Other versions
JPH0769840B2 (en
Inventor
Riichiro Take
理一郎 武
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Fujitsu Ltd
Original Assignee
Fujitsu Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Fujitsu Ltd filed Critical Fujitsu Ltd
Priority to JP61275743A priority Critical patent/JPH0769840B2/en
Publication of JPS63129428A publication Critical patent/JPS63129428A/en
Publication of JPH0769840B2 publication Critical patent/JPH0769840B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/52Program synchronisation; Mutual exclusion, e.g. by means of semaphores

Abstract

PURPOSE:To perform the processing of lock management at high speed, by distributing and allotting the lock management of plural common resources to plural managing processes, and deciding the managing process with takes in charge of the resource based on a value obtained by a hash function from the identification name of the resource. CONSTITUTION:The process 1 that is a lock request origin finds a function value by a prescribed hash function evaluating part 3 from the identification name 2 of a required resource 6 at the time of requesting lock. The process indexes the hash table 4 of a system based on the function value, and obtains the identifier of a required managing process 5, and calls the managing process 5 by the identifier, and requests the lock management by the identification name 2. The managing process 5 processes the lock management of a designated resource as usual by the identification name of the resource designated by the request. In such way, it is possible to distribute the resource 6 to the plural managing processes 5 and allot management, and to call a required managing process classified by every resource after identifying the managing process easily, and to improve processing efficiency.

Description

【発明の詳細な説明】 〔概 要〕 計算機における、複数のプロセスで共用する資源の排他
制御のためのロック管理の改良した制御方式である。
[Detailed Description of the Invention] [Summary] This is an improved control method for lock management for exclusive control of resources shared by multiple processes in a computer.

複数の共用資源のロック管理を複数の管理プロセスに分
配して分担させるようにし、資源の識別名からハツシュ
関数によって求める値によってその資源を受は持つ管理
プロセスを決定するように構成する。
Lock management of a plurality of shared resources is distributed among a plurality of management processes, and the management process that owns the resource is determined based on a value obtained from the resource's identification name using a hash function.

この方式により、複数の管理プロセスでロック管理を分
担して、ロック管理の処理を高速化するシステムの構成
が容易になる。
This method makes it easy to configure a system that speeds up lock management processing by sharing lock management among multiple management processes.

〔産業上の利用分野〕[Industrial application field]

本発明は、計算機における、複数のプロセスで共用する
資源の排他制御のためのロック管理の制御方式に関する
The present invention relates to a lock management control method for exclusive control of resources shared by multiple processes in a computer.

〔従来の技術〕[Conventional technology]

複数のプロセスの共存可能な計算機においては、それら
のプロセスで共用される計算機資源(以下において単に
資源という)が有る場合には、例えばデータベースの所
定のデータ単位のような資源の場合に、公知のようにそ
の資源を1プロセスが使用している間、他のプロセスに
よるその資源の使用を禁止するための、いわゆる排他制
御が必要になる。
In a computer where multiple processes can coexist, if there are computer resources (hereinafter simply referred to as resources) shared by those processes, for example, in the case of a resource such as a predetermined data unit of a database, publicly known Thus, while one process is using that resource, so-called exclusive control is required to prohibit other processes from using that resource.

公知のように、ロックは排他制御の手段として広(使用
される。その場合、排他制御の必要な資源を使用するプ
ロセスは使用に先立って、管理プロセスにその資源の識
別名を示して、ロックを要求する。
As is well known, locks are widely used as a means of exclusive control. In this case, a process that uses a resource that requires exclusive control indicates the resource's identification name to the management process and locks it before using it. request.

管理プロセスは、例えば指定の識別名の資源ごとに設け
た、公知のいわゆる待ち行列ポートに、要求元プロセス
を接続し、そのボートの行列の先頭になったとき、その
プロセスのみに当該資源の使用を許すように制御する。
For example, the management process connects the requesting process to a well-known so-called queuing port established for each resource with a specified identification name, and when it becomes the head of the queue for that boat, only that process can use the resource. control to allow.

〔発明が解決しようとする問題点〕[Problem that the invention seeks to solve]

従来このような制御を行う管理プロセスは、同一資源に
対する制御の競合を考慮して、実質的には同時に1管理
プロセスのみが処理を実行するように制御しているので
、その結果多数のプロセスの各種資源に対するロック要
求が集中した場合に、ロック処理待ち時間の増大による
システムの処理効率低下が問題になる。
Conventionally, management processes that perform this kind of control have controlled so that only one management process is executing processing at the same time, taking into account contention for control over the same resource. When lock requests for various resources are concentrated, a decrease in system processing efficiency due to an increase in lock processing waiting time becomes a problem.

その対策として、各資源についてそのロック管理を行う
1管理プロセスを定めるようにして、複数の管理プロセ
スに担当資源を分配することが考えらる。
As a countermeasure to this problem, it is conceivable to define one management process that performs lock management for each resource, and distribute the resources in charge to a plurality of management processes.

そのようにすれば、複数プロセッサを有する計算機の環
境においては、それらの管理プロセスによって互いに異
なる資源に対するロック要求を並行に処理することが可
能となり、処理待ち時間の減少を期待できる。
By doing so, in an environment of a computer having multiple processors, it becomes possible to process lock requests for different resources in parallel by those management processes, and a reduction in processing waiting time can be expected.

しかしその場合には、ロック要求において複数の管理プ
ロセスと分担資源との対応を識別して、所要の管理プロ
セスに要求を出さなければならないが、従来そのための
効率のよい制御方式が提供されていない。
However, in that case, it is necessary to identify the correspondence between multiple management processes and shared resources in the lock request and issue a request to the required management process, but no efficient control method has been provided to date. .

〔問題点を解決するための手段〕[Means for solving problems]

図は本発明の構成を示すブロック図である。 The figure is a block diagram showing the configuration of the present invention.

図において、1はロック要求元のプロセスであり、3は
資源6の識別名2から所定のハツシュ関数値を出力する
ハツシュ関数評価部、4はハツシュ関数値で索引して管
理プロセス識別子を与えるハツシュテーブル、5はその
識別子によって呼び出される管理プロセスである。
In the figure, 1 is a lock request source process, 3 is a hash function evaluation unit that outputs a predetermined hash function value from the identifier 2 of resource 6, and 4 is a hash function evaluation unit that indexes with the hash function value and provides a management process identifier. Stable, 5 is the management process called by that identifier.

〔作 用〕[For production]

ロック要求元のプロセス1はロック要求に際し、所要の
資源6の識別名2から、所定のハツシュ関数評価部3に
よって関数値を求める。
When making a lock request, the lock requesting process 1 uses a predetermined hash function evaluation unit 3 to obtain a function value from the identification name 2 of the required resource 6.

その関数値により、システムのハツシュテーブル4を索
引して必要な管理プロセス5の識別子を得、該識別子に
よって管理プロセス5を呼び、識別名2によりロック処
理を要求する。
Using the function value, the hash table 4 of the system is indexed to obtain the necessary identifier of the management process 5, the management process 5 is called using the identifier, and lock processing is requested using the identifier 2.

管理プロセス5は、要求で指定される資源の識別名によ
り、通常のように指定の資源のロック管理を処理する。
The management process 5 handles lock management for the specified resource in the usual manner, depending on the resource identification name specified in the request.

この方式により、複数の管理プロセス5に資源6を振り
分けて管理を分担させ、資源別に必要な管理プロセスを
容易に識別して呼び出すことができるので、複数プロセ
ッサの並行処理可能な環境では、複数のロック管理を並
行に処理することが可能になり、処理効率を向上できる
With this method, the resources 6 can be distributed to multiple management processes 5 to share management tasks, and the necessary management processes for each resource can be easily identified and called. Lock management can be processed in parallel, improving processing efficiency.

〔実施例〕〔Example〕

図においてプロセス1は、各種の処理業務に対応した、
一般に異なる内容を持つプロセスであり、但し図示のよ
うにロック要求のための同一の機構を持つものとする。
In the figure, process 1 corresponds to various processing tasks.
Generally, they are processes with different content, but with the same mechanism for lock requests as shown.

他方、管理プロセス5は公知のロック管理のための通常
の制御機能を有する同一の内容のプロセスでよ(、運用
上で図示のように特定の資源6のグループのみを扱うよ
うに分配し、それに応じたハツシュテーブル4を作成す
れば、自動的に各管理プロセス5が異なる資源6を分担
するようになる。
On the other hand, the management process 5 is a process with the same contents that has a normal control function for well-known lock management. By creating a corresponding hash table 4, each management process 5 will automatically share different resources 6.

ロック要求元のプロセス1はロック要求に際し、所要の
資源6の識別名2から、所定のハツシュ関数評価部3に
よって関数値を求める。
When making a lock request, the lock requesting process 1 uses a predetermined hash function evaluation unit 3 to obtain a function value from the identification name 2 of the required resource 6.

資源の識別名は、通常比較的長い文字列で構成されるの
で、ハツシュ関数として例えば次のような関数を使用し
て、比較的短いビット列の値にできるだけ偏りなく変換
するようにハツシュ関数評価部3を構成する。
Since resource identification names are usually composed of relatively long character strings, the hash function evaluation unit uses the following function as a hash function to convert it into a relatively short bit string value as unbiased as possible. 3.

即ち、例えば12バイトの識別名を、3バイトづつの4
グループに分割し、2グループはビットの並びを反転さ
せた後、4グループのビット列の排他的論理和を求め2
4ピントのビット列を得る。
In other words, for example, a 12-byte identifier is divided into 4 3-byte identifiers.
Divide into groups, invert the bit order for 2 groups, and then calculate the exclusive OR of the bit strings of 4 groups.
Obtain a 4-focus bit string.

このピント列を破除整数として、適当な整数で除算を行
い、その剰余を関数評価結果として、ハツシュ関数評価
部3から出力する。
Using this focus sequence as a divisible integer, division is performed by an appropriate integer, and the remainder is output from the hash function evaluation unit 3 as a function evaluation result.

以上の例のようにして、例えば8ビツトの関数値出力を
得るようにした場合には、ハツシュテーブル4として、
256項からなるテーブルを設け、各項に管理プロセス
5の識別子を表示する。
If, for example, an 8-bit function value output is obtained as in the above example, the hash table 4 is
A table consisting of 256 entries is provided, and the identifier of the management process 5 is displayed in each entry.

この例の場合に管理プロセスは最大256個設けること
ができ、それより少ない場合には、1管理プロセスの識
別子が、2項以上に表示されるようにする。
In this example, a maximum of 256 management processes can be provided, and if there are fewer than that, the identifier of one management process is displayed in two or more columns.

各ロック要求プロセス1は、以上によって求めた関数値
により、システムのハツシュテーブル4を索引して必要
な管理プロセス5の識別子を得、該識別子によって管理
プロセス5を呼び、識別名2によって資源を指定して、
そのロック処理を要求する。
Each lock requesting process 1 obtains the necessary identifier of the management process 5 by indexing the hash table 4 of the system using the function value obtained above, calls the management process 5 using the identifier, and allocates the resource using the identifier 2. Specify,
Request the lock processing.

この方式により、複数の管理プロセス5に資源6を振り
分けて管理を分担させ、資源別に必要な管理プロセスを
容易に識別して呼び出すごとができる。
With this method, the resources 6 can be distributed to a plurality of management processes 5 to share management duties, and the necessary management processes can be easily identified and called for each resource.

又、運用結果等により、管理プロセス5の数、或いは管
理プロセス5に対する分担資源の分配の変更をする場合
には、ハツシュテーブル4の内容及びハツシュ関数評価
部3の関数の何れか一方又は両方を変更して対処するこ
とができ、管理プロセス5を変更する必要がない。
In addition, when changing the number of management processes 5 or the distribution of resources to the management processes 5 depending on the operation results, either or both of the contents of the hash table 4 and the function of the hash function evaluation unit 3 are changed. This can be handled by changing the management process 5, and there is no need to change the management process 5.

〔発明の効果〕〔Effect of the invention〕

以上の説明から明らかなように、本発明によれば、計算
機における共用資源に関するロック管理処理について、
実現が容易で且つ融通性の高い高速化が得られ、計算機
の処理効率を向上するという著しい工業的効果がある。
As is clear from the above description, according to the present invention, regarding lock management processing regarding shared resources in a computer,
This method is easy to implement, provides highly flexible speedup, and has a remarkable industrial effect of improving computer processing efficiency.

【図面の簡単な説明】[Brief explanation of the drawing]

図は本発明の構成を示すブロック図 である。 図において、 1はプロセス、     2は識別名、3はハツシュ関
数評価部、 4はハツシュテーブル、5は管理プロセス、6は資源 を示す。
The figure is a block diagram showing the configuration of the present invention. In the figure, 1 is a process, 2 is an identification name, 3 is a hash function evaluation unit, 4 is a hash table, 5 is a management process, and 6 is a resource.

Claims (1)

【特許請求の範囲】 計算機で実行される複数のプロセス(1)によって共用
される複数の計算機資源(6)の、該プロセス(1)に
よる使用の排他制御のためのロック管理において、 該計算機資源(6)のロック管理を重複なく分担する複
数の管理プロセス(5)を設け、 該各計算機資源(5)の識別名(2)を所定のハッシュ
関数で評価し(3)、その結果により、該計算機資源を
分担する前記管理プロセスを決定する(4)ように構成
されていることを特徴とするロック管理制御方式。
[Scope of Claims] In lock management for exclusive control of the use of a plurality of computer resources (6) shared by a plurality of processes (1) executed on a computer by the processes (1), the computer resources include: A plurality of management processes (5) are provided to share the lock management of (6) without duplication, and the identification name (2) of each computer resource (5) is evaluated using a predetermined hash function (3), and based on the result, A lock management control method, characterized in that it is configured to (4) determine the management process that shares the computer resources.
JP61275743A 1986-11-19 1986-11-19 Lock management controller Expired - Lifetime JPH0769840B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP61275743A JPH0769840B2 (en) 1986-11-19 1986-11-19 Lock management controller

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP61275743A JPH0769840B2 (en) 1986-11-19 1986-11-19 Lock management controller

Publications (2)

Publication Number Publication Date
JPS63129428A true JPS63129428A (en) 1988-06-01
JPH0769840B2 JPH0769840B2 (en) 1995-07-31

Family

ID=17559774

Family Applications (1)

Application Number Title Priority Date Filing Date
JP61275743A Expired - Lifetime JPH0769840B2 (en) 1986-11-19 1986-11-19 Lock management controller

Country Status (1)

Country Link
JP (1) JPH0769840B2 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6697901B1 (en) * 2000-10-24 2004-02-24 Oracle International Corporation Using secondary resource masters in conjunction with a primary resource master for managing resources that are accessible to a plurality of entities
US6883026B1 (en) 1998-08-31 2005-04-19 International Business Machines Corporation Method and apparatus for managing locks of objects and method and apparatus for unlocking objects

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS60254342A (en) * 1984-05-31 1985-12-16 Fujitsu Ltd Controlling method of resources in using

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS60254342A (en) * 1984-05-31 1985-12-16 Fujitsu Ltd Controlling method of resources in using

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6883026B1 (en) 1998-08-31 2005-04-19 International Business Machines Corporation Method and apparatus for managing locks of objects and method and apparatus for unlocking objects
US6697901B1 (en) * 2000-10-24 2004-02-24 Oracle International Corporation Using secondary resource masters in conjunction with a primary resource master for managing resources that are accessible to a plurality of entities

Also Published As

Publication number Publication date
JPH0769840B2 (en) 1995-07-31

Similar Documents

Publication Publication Date Title
US4954945A (en) Processor-selection system
JPS63129428A (en) Lock management control system
CN111143210A (en) Test task scheduling method and system
US20080052714A1 (en) Method, Apparatus and Software for Managing Processing For a Plurality of Processors
JP2004038226A (en) Pc cluster and its intermediate software
CN109344161A (en) A kind of mass data storage means based on mongodb
JPH02245864A (en) Multiprocessor system
JPH02112030A (en) System for exclusive control
JPH04149762A (en) Data control system
JPS61136134A (en) Queue resource control system
JPH1049387A (en) Method and device for buffer management
JPS6331818B2 (en)
JPH03123953A (en) System for sharing peripheral equipment
JPH05158895A (en) System for improving loop calculation efficiency in parallel computer system
JPS62145441A (en) Updating processing system for key-sequenced data set
JPH10507548A (en) Data processing systems and methods and communication systems with such systems
JPH0193829A (en) System for operating queue
KR19980076869A (en) Processor creation method under OS and data exchange method using same
KR20020063365A (en) Real time memory management method of multi processor system
JPH02197947A (en) File transfer system
JPS62125438A (en) Virtual input and output device
JPH04241545A (en) Communication control system by double stage event matrix
JPH05173811A (en) Dynamic resource assigning and releasing system
JPH07334401A (en) Method for speeding up data base accessing work in network connection system
JPH02230429A (en) Data access control system