It’s pretty simple actually. If your source is T:SUBDIR and destinations are 10.10.10.1VOLUME, 10.10.10.2VOLUME, 10.10.10.2VOLUME, then something like:[code]FOR %F IN (10.10.10.1VOLUME 10.10.10.2VOLUME 10.10.10.2VOLUME) DO START ROBOCOPY T:SUBDIR %FSUBDIR /MIR /COPY:ALL /R:3 /W:3[code]I would also recommend testing to make sure your command is correct by using echo: [code]FOR %F IN (10.10.10.1VOLUME 10.10.10.2VOLUME 10.10.10.2VOLUME) DO ECHO START ROBOCOPY T:SUBDIR %FSUBDIR /MIR /COPY:ALL /R:3 /W:3[code]
It might also be worth mentioning a few tricks for copying and comparison.
For copying from one source to multiple destinations, using the ‘start’ command in a ‘for’ loop can start the copies simultaneously and allow the 100% cache hit to effectively double the copy speed since the original is basically only being read once and written twice. I’ve used this for up to 4 destinations simultaneously and it works best with similar destinations. Even when the destinations are not similar and the individual robocopy sessions become ‘off sync’ from each other, the latency of hitting the disk usually brings them back into alignment because one of the sessions has a cache hit while the other is still going to disk.
For comparison, MS’s own windiff is a pretty good way to compare entire tree branches. However, if one needs to compare a single source to multiple destinations, winmerge does a better job since it has the ability to actually compare a single source to 2x destinations. And being a portable program that runs on the various windows platforms (just like windiff), it’s another handy tool that can check the work of a robocopy session for bit by bit accuracy.
Shouldn’t the addition of + [employee]::DomainName throw an error since it’s hidden? I’m trying to understand the hidden attribute and how it differs from common public/private method declarations in other languages.
So, to get this straight, even though a property is hidden, it can still be used/queried from outside of the class?
While robocopy is one of the most powerful ways to sync drives, it does fail spectacularly in certain events–dst changes, file systems other than ntfs, and just missing files. It is important to check on it periodically to make sure the results are what you want them to be. Another great alternative to robocopy is its non-ms twin, xxcopy.
This is the problem with subscriptions, the power is now in Microsoft’s hands. I’m sure they employ many capable hands, which have their customers interest at heart. Unfortunately, I’m also sure they this particular groups is vastly outnumbered inside the Microsoft ranks.
The rest of them is in this game for the money. Not a bad thing in and off itself, don’t get me wrong. But a subscription model? Currently they are showing their good side, with reasonable prices for reasonable service.
But that won’t last, and then Microsoft has more control over your data and content than you do yourself. Call me old-fashioned all you want, but moving everything to the cloud is a tactical mistake. Well, a tactical mistake for anyone but Microsoft.
Besides, “computing” in general only began to take flight after most tech companies let go of their “main-frame mindset” and the vendor lock-in that comes with that. And yet, nowadays so many systems/companies swallowed the tech companies BS reasons hook, line and sinker.
As if this whole to the cloud movement isn’t anything else than the “main-frame mindset” and customers are back again on the “receiving end” of the vendor lock-in. If you have ever had the unfortunate experience of dealing with Oracle’s sales department, you would already have known what to brace for when you give companies with money-lust so much control over your data. Oracle never lost their “main-frame mindset”.
And Microsoft has an unfettered lust for money. These days they were smarter by hiring better PR than they did in their early days. But their lust for money has never wavered one inch. Seems like a lot of people/companies need to learn that lesson again…the hard way. Unfortunately.