Discussion:
Do not create destination folder using ROBOCOPY
(too old to reply)
sarat123
2009-01-20 20:03:07 UTC
Permalink
Dear All

I need to transfer files from one location to another location acros
WAN. I am using Robocopy to do that.

I am using the following syntax to do that
C:\robocopy.exe "C:\RoboTest\Source
"\\192.168.252.222\C$\RoboTest\Dest" "*.txt" /NP /IS /IPG:1 /R:2 /W:
/MOV

The above syntax creates the destination folder if it does not exist.
do not want to create the destination folder.

Is there any option in ROBOCOPY to not to create the destinatio
folder.


Thanks in advance
urs Frnd :

--
sarat12
-----------------------------------------------------------------------
sarat123's Profile: http://forums.techarena.in/members/sarat123.ht
View this thread: http://forums.techarena.in/windows-server-help/1106442.ht

http://forums.techarena.i
Pegasus (MVP)
2009-01-20 21:56:16 UTC
Permalink
Post by sarat123
Dear All
I need to transfer files from one location to another location across
WAN. I am using Robocopy to do that.
I am using the following syntax to do that
C:\robocopy.exe "C:\RoboTest\Source"
"\\192.168.252.222\C$\RoboTest\Dest" "*.txt" /NP /IS /IPG:1 /R:2 /W:5
/MOV
The above syntax creates the destination folder if it does not exist. I
do not want to create the destination folder.
Is there any option in ROBOCOPY to not to create the destination
folder.
Thanks in advance
urs Frnd :)
What do you want robocopy to do when the destination folder does not exist?
Lanwench [MVP - Exchange]
2009-01-20 22:46:22 UTC
Permalink
Post by Pegasus (MVP)
Post by sarat123
Dear All
I need to transfer files from one location to another location across
WAN. I am using Robocopy to do that.
I am using the following syntax to do that
C:\robocopy.exe "C:\RoboTest\Source"
"\\192.168.252.222\C$\RoboTest\Dest" "*.txt" /NP /IS /IPG:1 /R:2 /W:5
/MOV
The above syntax creates the destination folder if it does not
exist. I do not want to create the destination folder.
Is there any option in ROBOCOPY to not to create the destination
folder.
Thanks in advance
urs Frnd :)
What do you want robocopy to do when the destination folder does not exist?
Make a cappuccino!
Pegasus (MVP)
2009-01-20 23:38:39 UTC
Permalink
"Lanwench [MVP - Exchange]"
Post by Lanwench [MVP - Exchange]
Post by Pegasus (MVP)
Post by sarat123
Dear All
I need to transfer files from one location to another location across
WAN. I am using Robocopy to do that.
I am using the following syntax to do that
C:\robocopy.exe "C:\RoboTest\Source"
"\\192.168.252.222\C$\RoboTest\Dest" "*.txt" /NP /IS /IPG:1 /R:2 /W:5
/MOV
The above syntax creates the destination folder if it does not
exist. I do not want to create the destination folder.
Is there any option in ROBOCOPY to not to create the destination
folder.
Thanks in advance
urs Frnd :)
What do you want robocopy to do when the destination folder does not exist?
Make a cappuccino!
I prefer an espresso!
Seriously: The OP needs to put his server admin hat on and think through
this scenario properly. I can think of several scenarios:
- Abandon the job and send an alert.
- Copy the files to the root of the drive.
- Copy them to an alternative folder.
- If the /s switch is specified, only deal with the folders that exist in
the target.
You can probably dream up a few more ways to skin this particular rabbit!
sarat123
2009-01-21 16:19:24 UTC
Permalink
My requirement is, If there is a network failure the robocopy has t
wait for specified time and retry to transfer files

I am using VBSCript to call the Robocopy which waits for cetrain tim
if there is a failure in transferring the files. The failure could b
failure in network connection or something else.

When network connection exists, and if there is no destination folde
in the destination machine, robocopy has to return some retrun cod
saying destination folder does not exist. (My requirement is robocop
should not create the folder in the destination machine if it does no
exist, if destination folder exists, it has to copy the files fro
source to destination

--
sarat12
-----------------------------------------------------------------------
sarat123's Profile: http://forums.techarena.in/members/sarat123.ht
View this thread: http://forums.techarena.in/windows-server-help/1106442.ht

http://forums.techarena.i
Pegasus (MVP)
2009-01-21 17:04:39 UTC
Permalink
My requirement is, If there is a network failure the robocopy has to
wait for specified time and retry to transfer files
I am using VBSCript to call the Robocopy which waits for cetrain time
if there is a failure in transferring the files. The failure could be
failure in network connection or something else.
When network connection exists, and if there is no destination folder
in the destination machine, robocopy has to return some retrun code
saying destination folder does not exist. (My requirement is robocopy
should not create the folder in the destination machine if it does not
exist, if destination folder exists, it has to copy the files from
source to destination)
--
sarat123
You should check for the existence of the target folder before invoking
robocopy, e.g. like so:
@echo off
if exist \\Server\Backup\Folder robocopy /.. /.. /..

You probably don't need a VB Script file to invoke robocopy - a batch file
would be much simpler.
sarat123
2009-01-21 17:40:42 UTC
Permalink
Thank you very much for the response.
Is there any way to set the Robocopy not to create the targer folder.


And do you know any option to stop executing the robocopy if it take
more than 30 minutes to transfer the files


Thank Yo

--
sarat12
-----------------------------------------------------------------------
sarat123's Profile: http://forums.techarena.in/members/sarat123.ht
View this thread: http://forums.techarena.in/windows-server-help/1106442.ht

http://forums.techarena.i
Pegasus (MVP)
2009-01-21 19:15:25 UTC
Permalink
*** See below.
Post by sarat123
Thank you very much for the response.
Is there any way to set the Robocopy not to create the targer folder.
*** Yes - see my reply to your first post on this subject.
Post by sarat123
And do you know any option to stop executing the robocopy if it takes
more than 30 minutes to transfer the files
*** Yes - I just gave you an answer - please read my reply.
Post by sarat123
Thank You
--
sarat123
------------------------------------------------------------------------
sarat123's Profile: http://forums.techarena.in/members/sarat123.htm
http://forums.techarena.in/windows-server-help/1106442.htm
http://forums.techarena.in
sarat123
2009-01-21 21:47:49 UTC
Permalink
hello

you replied with the following message to my fist post
"What do you want robocopy to do when the destination folder does no
exist?"

The end user will assign a flag wether to create a destination folde
or not. Based on his option my VBScript has to call Robocopy


Can you please tell,
Is there any way to set the Robocopy not to create the targer folder.

can you give the syntax to do that

--
sarat12
-----------------------------------------------------------------------
sarat123's Profile: http://forums.techarena.in/members/sarat123.ht
View this thread: http://forums.techarena.in/windows-server-help/1106442.ht

http://forums.techarena.i
Pegasus (MVP)
2009-01-21 22:33:58 UTC
Permalink
Post by sarat123
hello
you replied with the following message to my fist post
"What do you want robocopy to do when the destination folder does not
exist?"
The end user will assign a flag wether to create a destination folder
or not. Based on his option my VBScript has to call Robocopy
Can you please tell,
Is there any way to set the Robocopy not to create the targer folder.
can you give the syntax to do that.
--
sarat123
It seems your newsreader is defective. Check here to see ***every*** post
that exists in this thread:
http://forums.techarena.in/windows-server-help/1106442.htm

Loading...