Hey there,
I am trying to add a little extra functionality to a script i have written which will copy a file from a local file to a location on another NT machine (on the same domain), the permissions are set to allow 'everyone' to write to the target folder(and file), but I don't get past the file test line that checks the target location exists.
Code
~~~~
use File::Copy;
$mirrorroot = "y:/wtw/experiment";
if (-d $mirrorroot) { print header; print "Mirror root found! at $mirrorroot";}
if (! -d $mirrorroot) { print header; print "No Mirror root found! at $mirrorroot";}
my $construct = "$mirrorroot/$section/$efile";
copy($maconstruct, $construct) || die ("Cant write to bacup : $! "
It doesn't see the folder on the drive mapped to y:, I have also tried using \\servername and \\IPaddress in the path but it still can't see it.
Any tips on this given it is NT ?? Or do I have to make a specific connection (socket?) to this target machine and then try my test and copy statements??
I have tried this and also tried using a 'system("copy...
but both ways to copy return the same error ('no such file or dircetory'). I know it is there but I can't seem to see it.
Any NT-centric ideas?
Thanks
Jez
I am trying to add a little extra functionality to a script i have written which will copy a file from a local file to a location on another NT machine (on the same domain), the permissions are set to allow 'everyone' to write to the target folder(and file), but I don't get past the file test line that checks the target location exists.
Code
~~~~
use File::Copy;
$mirrorroot = "y:/wtw/experiment";
if (-d $mirrorroot) { print header; print "Mirror root found! at $mirrorroot";}
if (! -d $mirrorroot) { print header; print "No Mirror root found! at $mirrorroot";}
my $construct = "$mirrorroot/$section/$efile";
copy($maconstruct, $construct) || die ("Cant write to bacup : $! "
It doesn't see the folder on the drive mapped to y:, I have also tried using \\servername and \\IPaddress in the path but it still can't see it.
Any tips on this given it is NT ?? Or do I have to make a specific connection (socket?) to this target machine and then try my test and copy statements??
I have tried this and also tried using a 'system("copy...
but both ways to copy return the same error ('no such file or dircetory'). I know it is there but I can't seem to see it.
Any NT-centric ideas?
Thanks
Jez