Powered by Invision Power Board


  Reply to this topicStart new topicStart Poll

> Inter Process File Handling, Cannot Lock a file for single process
saurabhjain
Posted: May 12 2005, 06:43 AM
Quote Post


Newbie
*

Group: Members
Posts: 1
Member No.: 991
Joined: 12-May 05



Hi All,

i am running a oracle procedure which writes a file . The same file is picked up by another script which runs in a cron after every 5 minutes.

Now the problem is that sometimes my script picks up a file while the procedure is still writing data in the file.

is there is any way i can lock my file, so that no other process process a file while one is still processin the file.

Thanx in advance

Saurabh
PMEmail Poster
Top
andyb1ack
Posted: May 12 2005, 02:35 PM
Quote Post


User Level: 4
****

Group: Members
Posts: 98
Member No.: 513
Joined: 9-September 04



Hi,
No, I don't believe you can lock a file to prevent another process trying to copy it.
You can do an fuser on the file though to see if it is still being used or written to before you pick it up though.
Andy
PMEmail Poster
Top
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:
« Next Oldest | Shells & Scripting | Next Newest »

Topic Options Reply to this topicStart new topicStart Poll

 



[ Script Execution time: 0.0559 ]   [ 12 queries used ]   [ GZIP Enabled ]




Partners: Cambridge Plus :: <Link Available> :: PIC Boot-loader Utility :: <Link Available>
Unix Man Pages / Linux Man Pages :: HiFi Forum :: SIP VoIP Phone & Provider Reviews :: UNIX/Linux Forum Archives

More info on advertising on Unix/Linux Forum