Hello gchen91789,
You don't have any indication if a transfer is complete - that's typical for FTP or so. There are several ways:
(unrealiable)
You can see if a file has not been written for some time: "find . -mtime +1" will find files which are older than 1 minute.
(better)
Transferred files should be marked as complete, e.g., like this:
File is tranferred as "file.incomplete" and renamed to "file.complete" after transfer. Then you only concatenate *.complete.
Be careful though: If you later do "rm -f *.complete", you might catch files which have become completed while you concatenated the rest. Better first use mv to move the files into a subdirectory, concatenate them there and then you can also delete them (or do any further processing).
Regards,
stefan73
Main Topics
Browse All Topics





by: omarfaridPosted on 2008-02-14 at 11:11:25ID: 20896171
How files are transfered?
Unix commands usually exit with status 0 if successful.
The exit status of command is set in env variable $?
You may
echo $?
$? can be used to check if files were transfered successfully