![]()
[<<]Message[>>] [<<]Author Subject Thread[>>]
Number : 3472 Date : 2003-01-07 Author : Tim Smoot Subject : Re: Copy same source to multiple destinations with different parent folders... Size(KB) : 4
Kan, Thanks for the reply, and I apologize for the incomplete information. I will clarify in order to narrow down my problem. I have upgrades that are done quarterly that update a source program directory that needs to then be replicated to the remaining user directories on the file server. The upgrade updates the current user directory: example: h:\joeboo\FSA\ FSA Being the application directory that the upgrade process has updated with new files Following the upgrade, the "joeboo\FSA\" directory contents then need to be replicated to all of the remaining users in their respective "username\FSA\" folders. I am attempting to utilize XXCOPY to replicate the contents of h:\home\joeboo\FSA\ to the remaining h:\home\"username"\FSA directories. I understand the wildcard switches on the source directory, but am failing to find examples of wildcard destinations. example: xxcopy h:\home\joeboo\FSA\* h:\home\*\FSA\ Obviously this syntax does not work, but it eludes to what I am attempting to do: copy the entire contents of a specified directory "h:\home\joeboo\FSA\" (to include sub-directories and contents) to the same directory name located in different parent directories (h:\home\tomfar\FSA\, h:\home\suedoe\FSA\, h:\home\lizfry\FSA\, etc. etc.) Thanks for your assistance, I have been trying switches for hours and can't seem to get it right. Have a great day! Message: 12 Date: Mon, 06 Jan 2003 17:46:17 -0600 From: Kan Yabumoto Subject: Re: Trying to replicate source directory to multiple folders with different parents. XXCOPY uses a simple model of file transfer by having one source base directory (the root for the job) and the destination base directory. source --> destination All subdirectories in the source that is relative to the source base directory will be replicated in the destination with the same relative path and directory tree structure. The only exception to this is the /SG and /SX and their variations which flattens the multi-level directory structure in the source into a flat one-level directory in the destination. All other copy operation recreate the same directory tree in the destination. Now, with the advent of the "wild-wildsource" feature (which allows you to place as many wildcards as you want at any place in the source specifier, the source base directory may be slightly (but not much) difficult to tell. The source base directory is defined as the longest path in the full source specifier without any wildcards. If you have a source structure like: c:\folder\123\abc\ c:\folder\456\abc\ c:\folder\789\abc\ c:\folder\xxx\625\abc\ and you want to copy them into the destination c:\mydest\ then, the you could combine the source using the "wild-wildsource" feature, xxcopy c:\folder\*\abc\ c:\mydest\ This will give you the following directory structure at the destination side: c:\mydest\123\abc\ c:\mydest\456\abc\ c:\mydest\789\abc\ c:\mydest\xxx\625\abc\ Now, your question makes little sense in light of the XXCOPY's fundamental rule that even though with the wildcards in the path, still the source directory is considered to be one (the base directory is the part which remain constant among all the included subdirectories). More importantly, the destination directory is always one (one base directory and replicated subdirectories will be created as needed). If you are not familiar with how this works, just do a few experiments and check the results. That's the easiest way to understand it. (Make sure you name a new directory for the experiments so that you won't overwrite anything. Also, until you know what you are doing, if you use /CLONE, it is safer to add /Z0 to disable the Zapping function (to delete extra files and directories in the destination which are not present in the source). Also, in your question, it was not quite apparent whether the item referred to by "abc" was a directory or a file. I interpreted as directory. (To avoid confusion, I encourage everyone to add the trailing backslash for a directory name when a directory is being referenced). Anyway, just remember that XXCOPY allows you to specify just one name in the directory (no wildcard). It is always without a wildcard. Kan Yabumoto ===================================================== At 2003-01-06 16:27, you wrote: >I am attempting to replicate a source folder and all of its contents to a >group of folders with different parent folder names. > >Example: > >Source directory: > >c:\folder\abc > >Destinations: > >c:\folder\123\abc >c:\folder \456\abc >c:\folder\789\abc >c:\folder\625\abc > >I am not understanding the destination folder switches. > >Thanks for your help! > > > > >Timothy W. Smoot, LAN/WAN Administrator >MCSE, A+, CCSA, CCSE >tsmoot@t... Timothy W. Smoot, LAN/WAN Administrator MCSE, A+, CCSA, CCSE _________________________________________________________________ MSN 8: advanced junk mail protection and 2 months FREE*. http://join.msn.com/?page=features/junkmail
This message if part of XXCOPY's message Archive. The archive contains all the messages posted at Yahoo!Groups: XXCOPY.