JP2002123412A - File access control system - Google Patents

File access control system

Info

Publication number
JP2002123412A
JP2002123412A JP2000315456A JP2000315456A JP2002123412A JP 2002123412 A JP2002123412 A JP 2002123412A JP 2000315456 A JP2000315456 A JP 2000315456A JP 2000315456 A JP2000315456 A JP 2000315456A JP 2002123412 A JP2002123412 A JP 2002123412A
Authority
JP
Japan
Prior art keywords
file
server
client
access
file access
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.)
Pending
Application number
JP2000315456A
Other languages
Japanese (ja)
Inventor
Hiromasa Nakagawa
裕雅 中川
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.)
Toshiba Corp
Original Assignee
Toshiba Corp
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 Toshiba Corp filed Critical Toshiba Corp
Priority to JP2000315456A priority Critical patent/JP2002123412A/en
Publication of JP2002123412A publication Critical patent/JP2002123412A/en
Pending legal-status Critical Current

Links

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

PROBLEM TO BE SOLVED: To access a file on the side of server from the side of client even without using the NFS of UNIX(R). SOLUTION: When the request of file access to a target file 23 is received from a client device 1, in a server device 2, a slave process 22 corresponding to this file request is prepared, the prepared slave process 22 accesses the target file 23 and the access result is transmitted to the client device 1 of an access source.

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】本発明は、UNIXを使用し
たサーバ/クライアントシステムにおいてNFSを使用
することなくサーバ側のファイルをアクセスするように
したファイルアクセス制御システムに関する。
[0001] 1. Field of the Invention [0002] The present invention relates to a file access control system for accessing a file on a server side without using NFS in a server / client system using UNIX.

【0002】[0002]

【従来の技術】基本ソフトウェアとしてUNIXを使用
したサーバ/クライアントシステムにおいて、従来、ク
ライアント側からサーバ側のファイルをアクセスするに
は、UNIXのネットワーク・ファイル・システム(N
etwork File System、以下「NF
S」という)を使用している。
2. Description of the Related Art Conventionally, in a server / client system using UNIX as basic software, to access a file on a server from a client, a UNIX network file system (N
network File System, "NF
S ”).

【0003】このNFSによるファイルアクセスでは、
オートマウント機能を使用してあたかも自マシンのファ
イルにアクセスする如くサーバ側のファイルアクセスが
可能となる。
[0003] In this file access by NFS,
By using the automount function, file access on the server side becomes possible as if accessing a file on the own machine.

【0004】[0004]

【発明が解決しようとする課題】しかしながら、UNI
XのNFSを使用してクライアント側からサーバ側のフ
ァイルをアクセスする従来システムでは、クライアント
からサーバのファイルにアクセス中にサーバがダウンす
るとクライアントがロック状態となり、サーバが復旧し
て立ち上がるまでの間、クライアント側の操作が不能に
なってしまうという問題があった。
SUMMARY OF THE INVENTION However, UNI
In the conventional system in which the client accesses the server file using the NFS of X, if the server goes down while the client is accessing the file on the server, the client is locked, and the server is recovered and started until the server is restored. There was a problem that operation on the client side became impossible.

【0005】本発明は上記事情に鑑み、UNIXのNF
Sを使用しなくともクライアント側からサーバ側のファ
イルをアクセスすることができ、従来の問題を解決でき
るファイルアクセス制御システムを提供することを目的
としている。
[0005] In view of the above circumstances, the present invention is based on UNIX NF.
It is an object of the present invention to provide a file access control system which can access a file on a server side from a client side without using S and can solve the conventional problem.

【0006】[0006]

【課題を解決するための手段】上記の目的を達成するた
めに、請求項1の発明では、サーバ側のファイルをクラ
イアント側からアクセスするファイルアクセス制御シス
テムにおいて、サーバ側ではファイルアクセス要求を受
けた際に、このファイル要求に対応する子プロセスを作
成する手段と、作成された子プロセス単位で目的のファ
イルをアクセスすると共に、そのアクセス結果をアクセ
ス元のクライアントに送信する手段とを備えたことを特
徴としている。
In order to achieve the above object, according to the present invention, in a file access control system for accessing a file on a server from a client, a file access request is received on the server. At this time, it is provided that there are means for creating a child process corresponding to the file request, and means for accessing a target file in a unit of the created child process and transmitting an access result to a client of the access source. Features.

【0007】請求項2の発明では、請求項1に記載のフ
ァイルアクセス制御システムにおいて、子プロセスで
は、目的のファイルがアクセス中であるかを判定し、ア
クセス中であれば、所定時間待った後、再度アクセスす
る排他処理を実行することを特徴としている。
According to a second aspect of the present invention, in the file access control system according to the first aspect, the child process determines whether a target file is being accessed, and if so, waits for a predetermined time, It is characterized by executing an exclusive process for accessing again.

【0008】請求項3の発明では、請求項1に記載のフ
ァイルアクセス制御システムにおいて、子プロセスで
は、ファイルアクセス処理中に所定時間が経過しても所
定の処理が実行されない場合にはその旨をクライアント
側に送信する機能を有することを特徴としている。
According to a third aspect of the present invention, in the file access control system according to the first aspect, if a predetermined process is not executed even after a predetermined time elapses during a file access process, the child process is notified. It has the function of transmitting to the client side.

【0009】上記構成により、本発明では、サーバ側で
はファイルアクセス要求を受けた際に、このファイル要
求に対応する子プロセスを作成し、作成された子プロセ
ス単位で目的のファイルをアクセスすると共に、そのア
クセス結果をアクセス元のクライアントに送信する。こ
れにより、クライアントからサーバ側のファイルをアク
セスするのにUNIXのNFSを使用せずにアクセスで
き、また、子プロセス単位でアクセスし、排他処理も可
能となる。
With the above configuration, according to the present invention, when a server receives a file access request, the server creates a child process corresponding to the file request, accesses a target file in units of the created child process, and The access result is transmitted to the access source client. As a result, the client can access the server-side file without using UNIX NFS, and can also access the child process and perform exclusive processing.

【0010】さらに、ファイルアクセスの結果が子プロ
セスからアクセス元のクライアントに送信されるので、
クライアント側では、アクセス中のサーバダウンに起因
するクライアント側のロック状態を未然に回避できる。
Further, since the result of the file access is transmitted from the child process to the access source client,
On the client side, a locked state on the client side due to a server down during access can be avoided.

【0011】さらに、ファイルアクセス処理中に所定時
間が経過しても所定の処理が実行されない場合にはその
旨をクライアント側に送信する機能を有するので、サー
バがダウンしてもクライアントの処理が可能となり、ロ
ック状態の発生を未然に防止できる。
In addition, if a predetermined process is not executed even if a predetermined time elapses during the file access process, a function to transmit the fact to the client is provided, so that the client can process even if the server goes down. Thus, the occurrence of the locked state can be prevented beforehand.

【0012】[0012]

【発明の実施の形態】図1は本発明に係るファイルアク
セス制御システムの実施の形態を示す構成ブロック図で
ある。
FIG. 1 is a block diagram showing a configuration of an embodiment of a file access control system according to the present invention.

【0013】同図に示すファイルアクセス制御システム
は、複数台のクライアント装置1とサーバ装置2とが通
信回線3を介して接続されている。
In the file access control system shown in FIG. 1, a plurality of client apparatuses 1 and server apparatuses 2 are connected via a communication line 3.

【0014】クライアント装置1は、サーバ装置2のフ
ァイルの入出力処理を実行するためのプロセス(ファイ
ルアクセスプロセス:FAP)を備えた制御装置4と、
バッファメモリ5とを備えている。制御装置4は、その
機能上、API部41と、通信M/W部42とを備えて
いる。API部41は、対象となるファイルをアクセス
するための情報を解析する処理等を実行する。通信M/
W部42は、クライアント装置1とサーバ装置2との間
の通信を行う機能を有する。バッファメモリ5は、サー
バ装置2のファイルをアクセスする際に領域が確保さ
れ、アクセスしたデータを保存するのに利用される。
The client device 1 includes a control device 4 having a process (file access process: FAP) for executing a file input / output process of the server device 2;
And a buffer memory 5. The control device 4 includes an API unit 41 and a communication M / W unit 42 in terms of its functions. The API unit 41 executes processing for analyzing information for accessing a target file. Communication M /
The W unit 42 has a function of performing communication between the client device 1 and the server device 2. The buffer memory 5 secures an area when accessing a file of the server device 2 and is used to store the accessed data.

【0015】一方、サーバ装置2は、その機能上、親プ
ロセスであるファイルアクセスプロセスデーモン(FA
PD)21とこのFAPD21を親プロセスとして生成
される子プロセス22と、アクセス対象となる目的ファ
イル23とを備えている。親プロセス21には通信M/
W部24が、子プロセス22にも通信M/W部25が具
備されている。なお、図中26はファイルアクセスの際
に作成されるロックファイルである。
On the other hand, the server device 2 has a file access process daemon (FA) which is a parent process due to its function.
PD) 21, a child process 22 generated by using the FAPD 21 as a parent process, and a target file 23 to be accessed. Communication M /
The W unit 24 has a communication M / W unit 25 in the child process 22. In the figure, reference numeral 26 denotes a lock file created at the time of file access.

【0016】次に、図2〜図6のフローチャートを参照
して本実施の形態のファイルアクセス制御システムの処
理手順を系統的に説明する。
Next, the processing procedure of the file access control system of the present embodiment will be systematically described with reference to the flowcharts of FIGS.

【0017】<FAPD(ファイルアクセスプロセスデ
ーモン)における処理>図2は、サーバ装置2の親プロ
セスであるファイルアクセスプロセスデーモン21にお
ける処理手順を示すフローチャートである。
<Processing in FAPD (File Access Process Daemon)> FIG. 2 is a flowchart showing a processing procedure in the file access process daemon 21 which is a parent process of the server device 2.

【0018】図2に示すように、FAPD21では、ク
ライアントの接続要求を待機しており(ステップS
1)、正常な接続要求があると(ステップS2)、その
データ(ヘッダ)を受信する(ステップS3)。ヘッダ
が正常に受信できた場合には(ステップS4YES)、子
プロセス22を作成する(ステップS5)。このよう
に、子プロセスを生成して、この子プロセス22に処理
を渡すことにより、親プロセス21はクライアントから
の要求処理に専念できるため、要求待ちの遅延時間をな
くすことができる。
As shown in FIG. 2, the FAPD 21 waits for a client connection request (step S).
1) When there is a normal connection request (step S2), the data (header) is received (step S3). If the header has been successfully received (step S4YES), a child process 22 is created (step S5). In this way, by generating a child process and passing the process to the child process 22, the parent process 21 can concentrate on the processing of the request from the client, so that the delay time for request waiting can be eliminated.

【0019】次の処理では、プロセスが親か子かが判定
され、親プロセスであれば(ステップS6YES)、次に
子プロセス生成が正常に行われたか否かが判定される。
子プロセス生成が正常でなければエラーメッセージが出
力され(ステップS7YES,S8)、ステップS3に戻
る。子プロセス22が正常に生成された場合には、子プ
ロセス22によって、図3に示すような受信電文処理が
実行される(ステップS6NO、ステップS9)。この受
信電文処理では、後述するように目的ファイル23への
IO処理が実行される。I/Oの結果はクライアント装
置1に送信される(ステップS10)。送信が正常であ
れば、正常終了処理(“exit(0)”で示す)が実行され
る(ステップS11YES)。送信が正常に行われなかっ
た場合には異常終了処理(“exit(-1)”で示す)が実行
される(ステップS11NO)。
In the next process, it is determined whether the process is a parent or a child. If the process is a parent process (step S6 YES), it is next determined whether or not a child process has been created normally.
If the child process generation is not normal, an error message is output (steps S7 YES, S8), and the process returns to step S3. When the child process 22 is normally generated, the child process 22 executes a received message process as shown in FIG. 3 (step S6NO, step S9). In the received message processing, an IO process for the target file 23 is executed as described later. The result of the I / O is transmitted to the client device 1 (Step S10). If the transmission is normal, a normal end process (indicated by “exit (0)”) is executed (step S11YES). If the transmission has not been performed normally, abnormal termination processing (indicated by "exit (-1)") is executed (step S11NO).

【0020】ステップS2の判定において、クライアン
ト装置1側からの接続要求が正常でない場合には、異常
終了処理が実行される。また、クライアント装置1から
のデータ受信が異常である場合には(ステップS4N
O)、接続を解除して再度データを受信する(ステップ
S12,ST3)。
If it is determined in step S2 that the connection request from the client device 1 is not normal, abnormal termination processing is executed. If the data reception from the client device 1 is abnormal (step S4N
O), release the connection and receive the data again (steps S12, ST3).

【0021】<受信電文処理>図3は、サーバ装置2の
子プロセス22で実行される受信電文処理を示すフロー
チャートである。
<Received Message Processing> FIG. 3 is a flowchart showing received message processing executed by the child process 22 of the server device 2.

【0022】この受信電文処理では、先ず、指定された
目的ファイルがアクセス中か否かがは判定される(ステ
ップS21)。すなわち、目的ファイルのアクセスする
際には、子プロセスによってロックファイルが作成さ
れ、このロックファイルの有無によって目的ファイルが
アクセス中であるか否かが判定される。アクセス中であ
れば(ステップS21YES)、予め設定された時間(例
えば、1秒間)待って再度ファイルをアクセスする(ス
テップS22)。このように、他のクライアント装置1
から同一ファイルについてアクセス中であれば、1秒間
待つ処理を実行することにより、排他処理を正しく行う
ことができる。
In the received message processing, first, it is determined whether or not the designated target file is being accessed (step S21). That is, when accessing the target file, a lock file is created by the child process, and it is determined whether or not the target file is being accessed based on the presence or absence of the lock file. If the file is being accessed (step S21 YES), the file is accessed again after a preset time (for example, one second) (step S22). Thus, the other client device 1
If the same file is being accessed from now on, exclusive processing can be performed correctly by executing processing that waits for one second.

【0023】ファイルがアクセス中でなければ、次に、
クライアント装置1の要求内容がファイル削除か、ファ
イル削除以外の要求かが判定される(ステップS2
3)。ファイル削除要求であれば、ファイル削除が実行
され(ステップS24)、返信データが作成された後、
再びステップS21の処理に戻る(ステップS25)。
If the file is not being accessed, then
It is determined whether the request content of the client device 1 is a file deletion or a request other than the file deletion (step S2).
3). If it is a file deletion request, the file is deleted (step S24), and after the reply data is created,
The process returns to step S21 again (step S25).

【0024】一方、クライアント装置1の要求内容がフ
ァイル削除以外であれば(ステップS23YES)、次に
ファイル読み込みか否かが判定される(ステップS2
6)。
On the other hand, if the request content of the client device 1 is other than file deletion (step S23 YES), it is next determined whether or not to read a file (step S2).
6).

【0025】ファイル読み込み要求でなければ、次にフ
ァイル書き込み要求か否かが判定される(ステップS2
7)。この場合、ファイル書き込み要求でもなければ
(ステップS27NO)、ステータスとしてパラメータエ
ラーを設定して再度ステップS21に戻る(ステップS
28)。ファイル書き込み要求であれば(ステップS2
7YES)、次にライトオープンが正常か否かが判定され
(ステップS29)、異常であればステータスとしてフ
ァイルオープンエラーが設定された後、ファイル21に
戻る(ステップS30)。また、ライトオープンが正常
であるが書き込みが正常に行われなかった場合には(ス
テップS31)、ステータスとして書き込みエラーを設
定した後、ステップS21に戻る(ステップS32)。
書き込みが正常に行われた場合には返信データ(ステー
タス、サブステータス、書き込みできたサイズ等)が作
成された後、ステップS21に戻る(ステップS3
3)。
If it is not a file read request, it is next determined whether or not it is a file write request (step S2).
7). In this case, if it is not a file write request (NO in step S27), a parameter error is set as a status, and the process returns to step S21 again (step S21).
28). If it is a file write request (step S2
(7YES) Then, it is determined whether or not the write open is normal (step S29). If abnormal, a file open error is set as a status, and the process returns to the file 21 (step S30). If the write open is normal but the writing was not performed normally (step S31), a write error is set as the status, and the process returns to step S21 (step S32).
If the writing has been performed normally, return data (status, sub-status, writeable size, etc.) is created, and the process returns to step S21 (step S3).
3).

【0026】一方、ステップS26における処理におい
て、要求がファイル読み込み要求であれば、次に、リー
ドオープンが正常か否かが判定される(ステップS3
4)。リードオープンが異常であれば、ステータスとし
てファイルオープンエラーが設定された後、ファイル2
1に戻る(ステップS35)。また、リードオープンが
正常であるが読み込みが正常に行われなかった場合には
(ステップS36NO)、ステータスとして読み込みエラ
ーが設定された後、ステップS21に戻る(ステップS
32)。読み込みが正常に行われた場合には返信データ
(ステータス、サブステータス、読み込みできたサイ
ズ、ファイルの全サイズ等)が作成された後、ステップ
S21に戻る(ステップS33)。なお、シーク時のエ
ラーはリードエラーとみなす。また、図中のステータス
1は、元々ファイル書き込み不可の状態、ステータス3
は、元々ファイルが無い状態、ステータス4は、ファイ
ルは有るが読み込みや書き込みできない状態を示す。
On the other hand, in the process in step S26, if the request is a file read request, it is next determined whether or not the read open is normal (step S3).
4). If the read open is abnormal, a file open error is set as the status, and then the file 2
It returns to 1 (step S35). If the read open is normal but the read is not performed normally (NO in step S36), a read error is set as the status, and the process returns to step S21 (step S36).
32). If the reading has been performed normally, return data (status, substatus, readable size, total size of the file, etc.) is created, and the process returns to step S21 (step S33). Note that an error at the time of seeking is regarded as a read error. The status 1 in the figure is a status in which the file cannot be written originally, the status 3
Indicates that there is no file originally, and status 4 indicates that the file exists but cannot be read or written.

【0027】<クライアント装置1における読み込み処
理>図4は、クライアント装置1の制御装置41におけ
る読み込み処理を示すフローチャートである。
<Read Process in Client Device 1> FIG. 4 is a flowchart showing a read process in the control device 41 of the client device 1.

【0028】先ず、通信を行うサーバ装置の論理サーバ
名が他ホストか否かが判定され、自ホストであれば(ス
テップS41NO)、受信電文処理が実行された後(ステ
ップS42)、受信電文ステータスが正常であるか否か
が判定され、異常、正常でそれぞれのパラメータが設定
される(ステップS43,S44,S45)。
First, it is determined whether or not the logical server name of the server device performing the communication is another host. If the logical server name is the own host (step S41 NO), the received message processing is executed (step S42). Is determined as normal or not, and respective parameters are set as abnormal or normal (steps S43, S44 and S45).

【0029】また、通信を行うサーバ装置が他ホストで
あれば(ステップS41YES)、サーバ装置への接続要
求が実行される(ステップS46)。接続が正常に行わ
れない場合にはエラー処理が実行された後(ステップS
48)、ステップS41に戻る。受信が正常に行われて
いれば(ステップS47YES)、送信電文ヘッダが作成
され、送信電文が作成され、データが送信される(ステ
ップS49,S50)。
If the server device for communication is another host (step S41 YES), a connection request to the server device is executed (step S46). If the connection is not made normally, error processing is executed (step S
48), and the process returns to step S41. If reception has been performed normally (step S47 YES), a transmission message header is created, a transmission message is created, and data is transmitted (steps S49 and S50).

【0030】次いで、送信が正常に行われたか否かが判
定され、送信が正常でない場合には、エラー処理がされ
た後(ステップS51,S52)、ステップS41に戻
る。送信が正常に行われた場合には、データ受信処理が
実行され(ステップS53)、データ受信が正常でない
場合には、エラー処理がされた後(ステップS54,S
55)、ステップS41に戻る。データ受信が正常の場
合には、受信電文ステータスが正常か否かが判定され、
異常の場合には異常パラメータが設定され、正常の場合
には正常パラメータが設定された後、接続が解除される
(ステップS56〜S59)。
Next, it is determined whether or not the transmission is normally performed. If the transmission is not normal, an error process is performed (steps S51 and S52), and the process returns to step S41. If the transmission is normally performed, a data reception process is executed (step S53). If the data reception is not normal, an error process is performed (steps S54 and S54).
55), and returns to step S41. If the data reception is normal, it is determined whether the received message status is normal,
If abnormal, an abnormal parameter is set. If normal, a normal parameter is set, and then the connection is released (steps S56 to S59).

【0031】<クライアント装置1における書き込み処
理>図5は、クライアント装置1の制御装置41におけ
る書き込み処理を示すフローチャートである。
<Writing Process in Client Device 1> FIG. 5 is a flowchart showing a writing process in the control device 41 of the client device 1.

【0032】先ず、通信を行うサーバ装置の論理サーバ
名が他ホストか否かが判定され、自ホストであれば(ス
テップS61NO)、受信電文処理が実行された後(ステ
ップS62)、受信電文ステータスが正常であるか否か
が判定され、異常、正常でそれぞれのパラメータが設定
される(ステップS63,S64,S65)。
First, it is determined whether or not the logical server name of the server device performing the communication is another host. If the host is the own host (NO in step S61), the received message processing is executed (step S62). Is determined as normal or not, and parameters are set as abnormal or normal (steps S63, S64 and S65).

【0033】また、通信を行うサーバ装置が他ホストで
あれば(ステップS61YES)、サーバ装置への接続要
求が実行される(ステップS66)。接続が正常に行わ
れない場合にはエラー処理が実行された後(ステップS
68)、ステップS61に戻る。受信が正常に行われて
いれば(ステップS67YES)、送信電文ヘッダが作成
され、送信電文が作成され、データが送信される(ステ
ップS69,S70)。
If the server device that performs communication is another host (step S61 YES), a connection request to the server device is executed (step S66). If the connection is not made normally, error processing is executed (step S
68), and return to step S61. If reception has been normally performed (step S67YES), a transmission message header is created, a transmission message is created, and data is transmitted (steps S69 and S70).

【0034】次いで、送信が正常に行われたか否かが判
定され、送信が正常でない場合には、エラー処理がされ
た後(ステップS71,S72)、ステップS61に戻
る。送信が正常に行われた場合には、データ受信処理が
実行され(ステップS73)、データ受信が正常でない
場合には、エラー処理がされた後(ステップS74,S
75)、ステップS61に戻る。データ受信が正常の場
合には、受信電文ステータスが正常か否かが判定され、
異常の場合には異常パラメータが設定され、正常の場合
には正常パラメータが設定された後、接続が解除される
(ステップS76〜S79)。
Next, it is determined whether or not the transmission is normally performed. If the transmission is not normal, an error process is performed (steps S71 and S72), and the process returns to step S61. If the transmission is normally performed, a data reception process is executed (step S73). If the data reception is not normal, an error process is performed (steps S74 and S74).
75), and returns to step S61. If the data reception is normal, it is determined whether the received message status is normal,
If abnormal, an abnormal parameter is set. If normal, a normal parameter is set, and then the connection is released (steps S76 to S79).

【0035】<クライアント装置1におけるアンリンク
処理>図6は、クライアント装置1の制御装置41にお
けるアンリンク処理を示すフローチャートである。
<Unlinking Process in Client Device 1> FIG. 6 is a flowchart showing the unlinking process in the control device 41 of the client device 1.

【0036】先ず、通信を行うサーバ装置の論理サーバ
名が他ホストか否かが判定され、自ホストであれば(ス
テップS81NO)、受信電文処理が実行された後(ステ
ップS82)、受信電文ステータスが正常であるか否か
が判定され、異常、正常でそれぞれのパラメータが設定
される(ステップS83,S84,S85)。
First, it is determined whether or not the logical server name of the server device that performs communication is another host. If it is the host (NO at step S81), the received message processing is executed (step S82). Is determined as normal or not, and parameters are set as abnormal or normal (steps S83, S84 and S85).

【0037】また、通信を行うサーバ装置が他ホストで
あれば(ステップS81YES)、サーバ装置への接続要
求が実行される(ステップS86)。接続が正常に行わ
れない場合にはエラー処理が実行された後(ステップS
88)、ステップS81に戻る。受信が正常に行われて
いれば(ステップS87YES)、送信電文ヘッダが作成
され、送信電文が作成され、データが送信される(ステ
ップS89,S90)。
If the server device that performs communication is another host (step S81 YES), a connection request to the server device is executed (step S86). If the connection is not made normally, error processing is executed (step S
88), and returns to step S81. If the reception has been performed normally (step S87 YES), a transmission message header is created, a transmission message is created, and the data is transmitted (steps S89 and S90).

【0038】次いで、送信が正常に行われたか否かが判
定され、送信が正常でない場合には、エラー処理がされ
た後(ステップS92)、ステップS81に戻る。送信
が正常に行われた場合には、データ受信処理が実行され
(ステップS93)、データ受信が正常でない場合に
は、エラー処理がされた後(ステップS94,S9
5)、ステップS81に戻る。データ受信が正常の場合
には、受信電文ステータスが正常か否かが判定され、異
常の場合には異常パラメータが設定され、正常の場合に
は正常パラメータが設定された後、接続が解除される
(ステップS96〜S99)。
Next, it is determined whether or not the transmission has been normally performed. If the transmission is not normal, an error process is performed (step S92), and the process returns to step S81. If the transmission is normally performed, a data reception process is executed (step S93). If the data reception is not normal, an error process is performed (steps S94 and S9).
5) Return to step S81. If the data reception is normal, it is determined whether the received message status is normal or not. If abnormal, an abnormal parameter is set. If normal, the normal parameter is set and the connection is released. (Steps S96 to S99).

【0039】このように、この実施の形態によれば、複
数のクライアント装置1からサーバ装置2の同一ファイ
ルに対してアクセスがあった場合にも、適切に排他処理
を行うことができる。
As described above, according to the present embodiment, even when a plurality of client apparatuses 1 access the same file of the server apparatus 2, the exclusive processing can be appropriately performed.

【0040】また、通信機能を有するので、サーバ装置
2がダウンしたときも一定時間が過ぎると応答が戻って
くるので、サーバ装置2がダウンしてもクライアント装
置1の処理が可能となり、ロック状態の発生を未然に防
止できる。また、通信機能を有することで、複数のサー
バ装置へのアクセスも可能となる。
Also, because of the communication function, even when the server device 2 goes down, a response is returned after a certain period of time. Therefore, even if the server device 2 goes down, the processing of the client device 1 becomes possible, and the locked state is obtained. Can be prevented from occurring. In addition, by having a communication function, it is possible to access a plurality of server devices.

【0041】また、他サーバか自ホストかの判定機能を
有するので、自ホスト/他サーバのファイルのI/Oが
可能となる。
Also, since it has a function of determining whether it is another server or its own host, I / O of files on its own host / other server becomes possible.

【0042】また、サーバ装置2のファイルアクセスプ
ロセスデーモン21は、フォークを行って処理を子プロ
セス22に任せるので、クライアント装置1からの要求
を即座に受け取ることができ、要求の待ち時間を短縮す
ることができる。
The file access process daemon 21 of the server device 2 performs a fork and leaves the process to the child process 22, so that the request from the client device 1 can be immediately received and the request waiting time can be reduced. be able to.

【0043】[0043]

【発明の効果】以上説明したように本発明によれば、サ
ーバ側ではファイルアクセス要求を受けた際に、このフ
ァイル要求に対応する子プロセスを作成し、作成された
子プロセス単位で目的のファイルをアクセスすると共
に、そのアクセス結果をアクセス元に送信する。これに
より、クライアントからサーバ側のファイルをアクセス
するのにUNIXのNFSを使用せずにアクセスでき、
また、子プロセス単位でアクセスし、排他処理も可能と
なる。
As described above, according to the present invention, when a server receives a file access request, a child process corresponding to the file request is created, and a target file is created for each created child process. And sends the access result to the access source. This allows clients to access server-side files without using UNIX NFS,
Also, it is possible to access each child process and perform exclusive processing.

【0044】さらに、ファイルアクセスの結果が子プロ
セスからアクセス元のクライアントに送信されるので、
クライアント側では、アクセス中のサーバダウンに起因
するクライアント側のロック状態を未然に回避できる。
Further, since the result of the file access is transmitted from the child process to the access source client,
On the client side, a locked state on the client side due to a server down during access can be avoided.

【0045】さらに、ファイルアクセス処理中に所定時
間が経過しても所定の処理が実行されない場合にはその
旨をクライアント側に送信する機能を有するので、サー
バがダウンしてもクライアントの処理が可能となり、ロ
ック状態の発生を未然に防止できる。
Further, if a predetermined process is not executed even if a predetermined time elapses during the file access process, a function to transmit the fact to the client side is provided. Therefore, even if the server goes down, the client process can be performed. Thus, the occurrence of the locked state can be prevented beforehand.

【図面の簡単な説明】[Brief description of the drawings]

【図1】本発明によるファイルアクセス制御システムの
実施形態を示すブロック図である。
FIG. 1 is a block diagram showing an embodiment of a file access control system according to the present invention.

【図2】サーバ装置の親プロセスであるファイルアクセ
スプロセスデーモンにおける処理手順を示すフローチャ
ートである。
FIG. 2 is a flowchart showing a processing procedure in a file access process daemon which is a parent process of the server device.

【図3】サーバ装置の子プロセスで実行される受信電文
処理を示すフローチャートである。
FIG. 3 is a flowchart showing received message processing executed in a child process of the server device.

【図4】クライアント装置の制御装置における読み込み
処理を示すフローチャートである。
FIG. 4 is a flowchart illustrating a reading process in a control device of the client device.

【図5】クライアント装置の制御装置における書き込み
処理を示すフローチャートである。
FIG. 5 is a flowchart illustrating a writing process in a control device of the client device.

【図6】クライアント装置の制御装置におけるアンリン
ク処理を示すフローチャートである。
FIG. 6 is a flowchart illustrating an unlink process in the control device of the client device.

【符号の説明】[Explanation of symbols]

1 クライアント装置 2 サーバ装置 3 通信回線 4 制御装置 5 バッファメモリ 21 ファイルアクセスプロセスデーモン(親プロセ
ス) 22 ファイルアクセスプロセス(子プロセス) 23 目的ファイル 24,25,42 通信M/W部 26 ロックファイル 41 API部
Reference Signs List 1 client device 2 server device 3 communication line 4 control device 5 buffer memory 21 file access process daemon (parent process) 22 file access process (child process) 23 target file 24, 25, 42 communication M / W unit 26 lock file 41 API Department

Claims (3)

【特許請求の範囲】[Claims] 【請求項1】 サーバ側のファイルをクライアント側か
らアクセスするファイルアクセス制御システムにおい
て、 サーバ側ではファイルアクセス要求を受けた際に、この
ファイル要求に対応する子プロセスを作成する手段と、 作成された子プロセス単位で目的のファイルをアクセス
すると共に、そのアクセス結果をアクセス元のクライア
ントに送信する手段と、 を備えたことを特徴とするファイルアクセス制御システ
ム。
In a file access control system for accessing a file on a server from a client, a means for creating a child process corresponding to the file request when the server receives a file access request, Means for accessing a target file on a child process basis and transmitting the access result to an access source client; and a file access control system.
【請求項2】 請求項1に記載のファイルアクセス制御
システムにおいて、 子プロセスでは、目的のファイルがアクセス中であるか
を判定し、アクセス中であれば、所定時間待った後、再
度アクセスする排他処理を実行する、 ことを特徴とするファイルアクセス制御システム。
2. The file access control system according to claim 1, wherein the child process determines whether the target file is being accessed, and if so, waits for a predetermined time and then accesses again. A file access control system.
【請求項3】 請求項1に記載のファイルアクセス制御
システムにおいて、 子プロセスでは、ファイルアクセス処理中に所定時間が
経過しても所定の処理が実行されない場合にはその旨を
クライアント側に送信する機能を有する、 ことを特徴とするファイルアクセス制御システム。
3. The file access control system according to claim 1, wherein in the child process, if a predetermined process is not executed even after a predetermined time elapses during the file access process, the fact is transmitted to the client side. A file access control system having a function.
JP2000315456A 2000-10-16 2000-10-16 File access control system Pending JP2002123412A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2000315456A JP2002123412A (en) 2000-10-16 2000-10-16 File access control system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2000315456A JP2002123412A (en) 2000-10-16 2000-10-16 File access control system

Publications (1)

Publication Number Publication Date
JP2002123412A true JP2002123412A (en) 2002-04-26

Family

ID=18794560

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2000315456A Pending JP2002123412A (en) 2000-10-16 2000-10-16 File access control system

Country Status (1)

Country Link
JP (1) JP2002123412A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20110114699A (en) * 2009-02-06 2011-10-19 인터내셔널 비지네스 머신즈 코포레이션 An apparatus for maintaining data integrity

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20110114699A (en) * 2009-02-06 2011-10-19 인터내셔널 비지네스 머신즈 코포레이션 An apparatus for maintaining data integrity
JP2012517057A (en) * 2009-02-06 2012-07-26 インターナショナル・ビジネス・マシーンズ・コーポレーション Apparatus, method, and computer program for maintaining data integrity (apparatus for maintaining data consistency)
KR101581072B1 (en) 2009-02-06 2015-12-30 인터내셔널 비지네스 머신즈 코포레이션 An apparatus for maintaining data integrity
US10372682B2 (en) 2009-02-06 2019-08-06 International Business Machines Corporation Maintaining data integrity

Similar Documents

Publication Publication Date Title
JP4792505B2 (en) Data synchronization processing method, client, server, and data synchronization system between client and server
US8972348B2 (en) Method and system for supporting off-line mode of operation and synchronization
JP4794143B2 (en) System and method for managing cache objects using notification bonds
US10193951B2 (en) Binding CRUD-type protocols in distributed agreement protocols
US20040064517A1 (en) Synchronization message processing method
US7089311B2 (en) Methods, systems and computer program products for resuming SNA application-client communications after loss of an IP network connection
JPH09244936A (en) Management method and system for shared data file
JPH113299A (en) Information processing system, information processor and their control method
JP3967758B2 (en) Data communication adjustment by sequence number
US20060077976A1 (en) Apparatus and method for printing data using a server message block protocol
EP1608131B1 (en) Content retrieval using exchange of context information
CN113542402A (en) File transmission method, device, system, electronic equipment and storage medium
JP2000029813A (en) Server selection system
RU2348066C2 (en) Communication terminal
US6470340B1 (en) Inter-program linking system and method thereof
KR100959977B1 (en) Apparatus for establishing network using network interface, Method and a recording medium thereof
JP2002140213A (en) Information managing device and method, information managing system, and computer-readable recording medium with program to be installed in information managing device recorded thereon
JP2002123412A (en) File access control system
CN114900449B (en) Resource information management method, system and device
JPH11316727A (en) Security system
JP3559375B2 (en) File transfer method
JP2002163122A (en) Communication processing method and record medium for communication processing program
US5936944A (en) Network system
JPH09190359A (en) Application shared system and its control method and information processing method and device
JP2000194624A (en) Computer system and communication recovery system