Home » Infrastructure » Linux » Problem : file being written is being transfered in Incomplete state
Problem : file being written is being transfered in Incomplete state [message #249702] Thu, 05 July 2007 10:38 Go to next message
orasaket
Messages: 70
Registered: November 2006
Member
Hi,

Oracle 9i R2 on RHEL Linux Server

We are creating some files on Linus RHEL database server and then transferring these files to another server using periodic cron job.

However while the files are partially created and are still being written the cron job copies it to another server.

I was thinking that the OS must be holding lock on the file being written which will prevent any other process from copying/ moving the file.

However, it seems there is nothing like such kind of locks.

Can we track if the file is not completed written and closed by one process (oracle pl/sql), another process i.e. cron job in our case, will not pick it for transferring to another server?

Thanks and Regards,
OraSaket
Re: Problem : file being written is being transfered in Incomplete state [message #249719 is a reply to message #249702] Thu, 05 July 2007 11:45 Go to previous messageGo to next message
BlackSwan
Messages: 26766
Registered: January 2009
Location: SoCal
Senior Member
You need to be smarter than the equipemnt your working on/with.
One approach I've used in the past is to save the length of the file BEFORE the network copy starts.
After the copy completes you compare the saved PRIOR length with the current length.
If they are the same then you know the remote file is complete.
If the lengths are different, you need to decide how best to proceed.
Re: Problem : file being written is being transfered in Incomplete state [message #249747 is a reply to message #249719] Thu, 05 July 2007 14:23 Go to previous messageGo to next message
DreamzZ
Messages: 1666
Registered: May 2007
Location: Dreamzland
Senior Member
http://www.orafaq.com/forum/t/84899/105911/
Re: Problem : file being written is being transfered in Incomplete state [message #249903 is a reply to message #249702] Fri, 06 July 2007 08:29 Go to previous message
orasaket
Messages: 70
Registered: November 2006
Member
Many Thanks
I will try MD5; also the script provided by andrew.

Regards,
OraSaket
Previous Topic: Oracle 10g on RHEL4 AS for Itanium Error
Next Topic: Help a newbie install 10g on Suse 10.1
Goto Forum:
  


Current Time: Fri Mar 29 07:48:49 CDT 2024