Operating System - HP-UX
1830899 Members
2453 Online
110017 Solutions
New Discussion

Re: Script to copy files keeps getting an error

 
Simon R Wootton
Regular Advisor

Script to copy files keeps getting an error

I have a script running via cron to copy various data files sideways each day, unfortunately it keeps emailing an error as follows :

link failed: startmls: File exists

The script is just copying using 'cp -R ', nothing more clever. It looks like a symbolic link issue - any suggestions ?

Help rewarded as usual
Cheers
Simon
3 REPLIES 3
Mark Nieuwboer
Esteemed Contributor

Re: Script to copy files keeps getting an error

Hi Simon,

It looks like a symbolic link problem.
But it's very difficult to say with the information provided. What i think is dat you try to copy the directory on a symbolic link and this is not accepted.

grtz. Mark
Sivakumar TS
Honored Contributor

Re: Script to copy files keeps getting an error

Dear Simon,

Is there any symbolic links in the source directory ? Probably that is cause !

Siva.

Nothing is Impossible !
Rory R Hammond
Trusted Contributor

Re: Script to copy files keeps getting an error

Simon,

if your file has symbolic links try this instead:

cd
find . -follow -depth -print |cpio -pdmh

The above copies the data in the current directory (that contains symbolic links) to new temporary location populating it with the source files files (no links)

Rory
There are a 100 ways to do things and 97 of them are right