<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Admins Goodies &#187; robocopy</title>
	<atom:link href="http://adminsgoodies.com/tag/robocopy/feed/" rel="self" type="application/rss+xml" />
	<link>http://adminsgoodies.com</link>
	<description>Just another WordPress site</description>
	<lastBuildDate>Mon, 17 Jun 2013 16:33:35 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.1</generator>
		<item>
		<title>Robocopy for Microsoft Access Files MIR switch</title>
		<link>http://adminsgoodies.com/robocopy-for-microsoft-access-files-mir-switch/</link>
		<comments>http://adminsgoodies.com/robocopy-for-microsoft-access-files-mir-switch/#comments</comments>
		<pubDate>Mon, 21 Jan 2013 17:34:05 +0000</pubDate>
		<dc:creator>tom</dc:creator>
				<category><![CDATA[General Questions]]></category>
		<category><![CDATA[backup]]></category>
		<category><![CDATA[ms-access]]></category>
		<category><![CDATA[robocopy]]></category>

		<guid isPermaLink="false">http://adminsgoodies.com/robocopy-for-microsoft-access-files-mir-switch/</guid>
		<description><![CDATA[We are using robocopy with MIR switch to backup our Microsoft Access Databases, i.e., .accdb, and .mdb files. Interesting thing with Access database files is that you can open a database, add a few records into a table, close the db and the size of the database file will not change. Will robocopy know that he has to copy this file next time when he does the backup? Thanks Asked by I don&#039;t know. Changing [...]]]></description>
				<content:encoded><![CDATA[<h3 class="pq"><img src="http://adminsgoodies.com/imgs/question.png" alt="Question" /></h3>
<p>We are using robocopy with MIR switch to backup our Microsoft Access Databases, i.e., .accdb, and .mdb files. Interesting thing with Access database files is that you can open a database, add a few records into  a table, close the db and the size of the database file will not change.<br />
Will robocopy know that he has to copy this file next time when he does the backup?</p>
<p>Thanks</p>
<div class="author">Asked by <a href="http://serverfault.com/users/138169/i-dont-know" target="_blank">I don&#039;t know.</a></div>
<h3 class="pa"><img src="http://adminsgoodies.com/imgs/answer.png" alt="Answer" /></h3>
<p>Changing the file not necessarily leads to a change in the file&#8217;s size, but typically (i.e. unless a sufficiently privileged process has changed that) the following always happens:</p>
<ul>
<li>the <em>&#8220;last modified&#8221;</em> timestamp of the file is updated to the current timestamp</li>
<li>the <em>&#8220;archive&#8221;</em> bit is touched (if it was not set, it is set by the OS automatically)</li>
</ul>
<p>Robocopy would compare the &#8220;last modified&#8221; timestamp of the destination with that of the source and copy when these two differ (this behavior might be tweaked according to your requirements using the <code>/xn</code> and <code>/xo</code> switches). Robocopy would only honor (and reset) the <code>archive</code> file attribute when you use <code>/m</code> switch &#8211; see the <a href="http://technet.microsoft.com/en-us/library/cc733145%28v=ws.10%29.aspx" rel="nofollow">robocopy documentation</a> for details.</p>
<div class="author">Answered by <a href="http://serverfault.com/users/76595/syneticon-dj" target="_blank">syneticon-dj</a></div>
<p class="ref-link">Check <a href="http://serverfault.com/questions/470980/robocopy-for-microsoft-access-files-mir-switch" target="_blank">more discussion</a> of this question.</p>
]]></content:encoded>
			<wfw:commentRss>http://adminsgoodies.com/robocopy-for-microsoft-access-files-mir-switch/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>RoboCopy A File From The Web?</title>
		<link>http://adminsgoodies.com/robocopy-a-file-from-the-web/</link>
		<comments>http://adminsgoodies.com/robocopy-a-file-from-the-web/#comments</comments>
		<pubDate>Tue, 08 Jan 2013 17:33:23 +0000</pubDate>
		<dc:creator>tom</dc:creator>
				<category><![CDATA[General Questions]]></category>
		<category><![CDATA[batch]]></category>
		<category><![CDATA[batch-file]]></category>
		<category><![CDATA[robocopy]]></category>
		<category><![CDATA[windows]]></category>

		<guid isPermaLink="false">http://adminsgoodies.com/robocopy-a-file-from-the-web/</guid>
		<description><![CDATA[Is it possible to download a file from the web using RoboCopy? What would the syntax for that be? Here&#8217;s what I&#8217;m trying: RoboCopy "http://www.google.com/" "C:\some_folder\" "index.html" /L /V /E /LOG:"C:\some_folder\test_robocopy.log" /R:10 /W:30 The error log is giving me an error that seems to indicate the file is a folder, and also that it&#8217;s trying to hit http://www.google.com as a folder on my location machine. ------------------------------------------------------------------------------- ROBOCOPY :: Robust File Copy for Windows ------------------------------------------------------------------------------- Started [...]]]></description>
				<content:encoded><![CDATA[<h3 class="pq"><img src="http://adminsgoodies.com/imgs/question.png" alt="Question" /></h3>
<p>Is it possible to download a file from the web using RoboCopy? What would the syntax for that be? Here&#8217;s what I&#8217;m trying:</p>
<pre class="prettyprint"><code>RoboCopy "http://www.google.com/" "C:\some_folder\" "index.html" /L /V /E /LOG:"C:\some_folder\test_robocopy.log" /R:10 /W:30
</code></pre>
<p>The error log is giving me an error that seems to indicate the file is a folder, and also that it&#8217;s trying to hit <a href="http://www.google.com" rel="nofollow">http://www.google.com</a> as a folder on my location machine.</p>
<pre class="prettyprint"><code>-------------------------------------------------------------------------------
   ROBOCOPY     ::     Robust File Copy for Windows                              
-------------------------------------------------------------------------------  Started : Tue Jan 08 10:31:04 2013   Source : C:\some_folder\http:\www.google.com\index.html\
     Dest : C:\some_folder\index.html\    Files : *.*  Options : *.* /V /L /S /E /COPY:DAT /R:10 /W:30 ------------------------------------------------------------------------------2013/01/08 10:31:04 ERROR 123 (0x0000007B) Accessing Source Directory C:\some_folder\http:\www.google.com\index.html\
The filename, directory name, or volume label syntax is incorrect.
</code></pre>
<div class="author">Asked by <a href="http://serverfault.com/users/72194/cory-dee" target="_blank">Cory Dee</a></div>
<h3 class="pa"><img src="http://adminsgoodies.com/imgs/answer.png" alt="Answer" /></h3>
<p>The only way I can conceive of making this work is if you create a WebDAV share, such as the one at live.sysinternals.com, and then address it as a UNC (\\yoursite.com\folder) and the minidirector in the WebClient service will handle it.</p>
<p>But that requires a specific configuration on the web server.</p>
<p>Also, Invoke-WebRequest if you&#8217;re using PS 3.</p>
<p>Edit: Also make sure the WebClient service is running before trying to access WebDAV shares on the command line. Windows Explorer will start the service on demand, but cmd.exe or powershell.exe will not.</p>
<div class="author">Answered by <a href="http://serverfault.com/users/104624/ryan-ries" target="_blank">Ryan Ries</a></div>
<p class="ref-link">Check <a href="http://serverfault.com/questions/464058/robocopy-a-file-from-the-web" target="_blank">more discussion</a> of this question.</p>
]]></content:encoded>
			<wfw:commentRss>http://adminsgoodies.com/robocopy-a-file-from-the-web/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Exceptional slowdown of robocopy copying from VM to DFS array</title>
		<link>http://adminsgoodies.com/exceptional-slowdown-of-robocopy-copying-from-vm-to-dfs-array/</link>
		<comments>http://adminsgoodies.com/exceptional-slowdown-of-robocopy-copying-from-vm-to-dfs-array/#comments</comments>
		<pubDate>Tue, 18 Dec 2012 17:35:58 +0000</pubDate>
		<dc:creator>tom</dc:creator>
				<category><![CDATA[General Questions]]></category>
		<category><![CDATA[dfs]]></category>
		<category><![CDATA[robocopy]]></category>
		<category><![CDATA[vmware-vsphere]]></category>
		<category><![CDATA[windows-server-2003]]></category>

		<guid isPermaLink="false">http://adminsgoodies.com/exceptional-slowdown-of-robocopy-copying-from-vm-to-dfs-array/</guid>
		<description><![CDATA[I&#8217;ve got an old win 2003 VM (VMware) on a blade cluster of VMs that I&#8217;m moving a considerable amount of files to our new DFS array. There are two main folders with about 1.7 million and half a million smaller files (letters, memos, and other smaller files) respectively. Total size is ~420 GB and ~100 GB. We&#8217;re using the gui version of robocopy on the server to copy the files. We had initiated a [...]]]></description>
				<content:encoded><![CDATA[<h3 class="pq"><img src="http://adminsgoodies.com/imgs/question.png" alt="Question" /></h3>
<p>I&#8217;ve got an old win 2003 VM (VMware) on a blade cluster of VMs that I&#8217;m moving a considerable amount of files to our new DFS array. There are two main folders with about 1.7 million and half a million smaller files (letters, memos, and other smaller files) respectively. Total size is ~420 GB and ~100 GB.</p>
<p>We&#8217;re using the gui version of robocopy on the server to copy the files. We had initiated a file copy about a month ago to test the process and found that it was taking around 4 hours for the large file. Now that I&#8217;m in the process of actually switching the files over it has been taking 18-20 hours. Nothing has changed on the server side and nothing has changed on the settings of the copy (no logs, 1 retry with a wait of 1 second). </p>
<p>Our intent is to shut off the share and force the copy over again to get all the files that have been left out of the copy due to being locked by users. I can&#8217;t take a 20 hour outage to do that though. </p>
<p>Does anyone have any theories about what could be causing such a delay for robocopy compared to previously shorter runs?</p>
<p>Edit: I discovered last night the copy must be freezing. It stops at a certain time (seems to be variable) and doesn&#8217;t continue at all.</p>
<div class="author">Asked by <a href="http://serverfault.com/users/148415/user1588867" target="_blank">user1588867</a></div>
<h3 class="pa"><img src="http://adminsgoodies.com/imgs/answer.png" alt="Answer" /></h3>
<p>We&#8217;ve been fiddling with this one. Looks like there was something odd going on with the gui interface. When I specifically set the retry and wait to &#8220;1&#8243; it went through normally. This may have been coincidence, but it began working normally on the first try with those settings.</p>
<div class="author">Answered by <a href="http://serverfault.com/users/148415/user1588867" target="_blank">user1588867</a></div>
<p class="ref-link">Check <a href="http://serverfault.com/questions/455361/exceptional-slowdown-of-robocopy-copying-from-vm-to-dfs-array" target="_blank">more discussion</a> of this question.</p>
]]></content:encoded>
			<wfw:commentRss>http://adminsgoodies.com/exceptional-slowdown-of-robocopy-copying-from-vm-to-dfs-array/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Can Robocopy be made to skip open files?</title>
		<link>http://adminsgoodies.com/can-robocopy-be-made-to-skip-open-files/</link>
		<comments>http://adminsgoodies.com/can-robocopy-be-made-to-skip-open-files/#comments</comments>
		<pubDate>Thu, 01 Nov 2012 16:53:19 +0000</pubDate>
		<dc:creator>tom</dc:creator>
				<category><![CDATA[General Questions]]></category>
		<category><![CDATA[robocopy]]></category>
		<category><![CDATA[windows-server-2003]]></category>

		<guid isPermaLink="false">http://adminsgoodies.com/can-robocopy-be-made-to-skip-open-files/</guid>
		<description><![CDATA[We are using Robocopy to redistribute files which arrive via FTP in a drop folder. Ideally we want Robocopy to leave files alone if they are still being FTPd. Having tried various switches, Robocopy still copies the open files. It doesn&#8217;t delete them, so the FTP continues unaffected. However, we end up with truncated files being distributed to their destination. Can Robocopy be made to skip open files? Perhaps there is something more suitable than [...]]]></description>
				<content:encoded><![CDATA[<h3 class="pq"><img src="http://adminsgoodies.com/imgs/question.png" alt="Question" /></h3>
<p>We are using Robocopy to redistribute files which arrive via FTP in a drop folder. Ideally we want Robocopy to leave files alone if they are still being FTPd.</p>
<p>Having tried various switches, Robocopy still copies the open files. It doesn&#8217;t delete them, so the FTP continues unaffected. However, we end up with truncated files being distributed to their destination.</p>
<p>Can Robocopy be made to skip open files?</p>
<p>Perhaps there is something more suitable than Robocopy for this task?</p>
<div class="author">Asked by <a href="http://serverfault.com/users/37858/domspurling" target="_blank">domspurling</a></div>
<h3 class="pa"><img src="http://adminsgoodies.com/imgs/answer.png" alt="Answer" /></h3>
<p>Have you tried using the /R and /W switches?</p>
<p>Something like:</p>
<pre><code>/R:2 /W:2 
</code></pre>
<p>This means retry twice wait 2 secs to retry. If the file is still open after the two attempts, the file will be skipped. Depending on your needs you could lower it to /R:1 /W:1.</p>
<div class="author">Answered by <a href="http://serverfault.com/users/142406/bmurtagh" target="_blank">bmurtagh</a></div>
<p class="ref-link">Check <a href="http://serverfault.com/questions/444383/can-robocopy-be-made-to-skip-open-files" target="_blank">more discussion</a> of this question.</p>
]]></content:encoded>
			<wfw:commentRss>http://adminsgoodies.com/can-robocopy-be-made-to-skip-open-files/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Backup with Mercurial and Robocopy?</title>
		<link>http://adminsgoodies.com/backup-with-mercurial-and-robocopy/</link>
		<comments>http://adminsgoodies.com/backup-with-mercurial-and-robocopy/#comments</comments>
		<pubDate>Sun, 29 Jul 2012 16:33:13 +0000</pubDate>
		<dc:creator>tom</dc:creator>
				<category><![CDATA[General Questions]]></category>
		<category><![CDATA[backup]]></category>
		<category><![CDATA[batch-file]]></category>
		<category><![CDATA[mercurial]]></category>
		<category><![CDATA[robocopy]]></category>
		<category><![CDATA[windows]]></category>

		<guid isPermaLink="false">http://adminsgoodies.com/backup-with-mercurial-and-robocopy/</guid>
		<description><![CDATA[The Problem We would like to backup our critical files from several network shares to a removable hard drive. We want to automate the backup so we don&#8217;t have to remember to run it. It needs to finish overnight. Furthermore, we want to be able to preserve multiple versions of each file so we can back out of our user&#8217;s mistakes easier. Background Information I work in a large Windows-based enterprise with a centralized IT [...]]]></description>
				<content:encoded><![CDATA[<h3 class="pq"><img src="http://adminsgoodies.com/imgs/question.png" alt="Question" /></h3>
<p><strong>The Problem</strong></p>
<p>We would like to backup our critical files from several network shares to a removable hard drive.  We want to automate the backup so we don&#8217;t have to remember to run it.  It needs to finish overnight.  Furthermore, we want to be able to preserve multiple versions of each file so we can back out of our user&#8217;s mistakes easier.</p>
<p><strong>Background Information</strong></p>
<p>I work in a large Windows-based enterprise with a centralized IT section who is responsible for all backups.  Their backups are geared towards disaster recovery and not user error, and require upper-level management approval for any non-disaster recoveries.  Several times we have noticed that our backups have failed, we weren&#8217;t notified.  I do not have administrative rights to the server or my desktop.  We are trying to backup some 198,000 files spanning about 240 gigabytes.  These files rarely change.  Our backup drive is one terabyte.</p>
<p><strong>My Proposed Solution</strong></p>
<p>What I would like to do is to write a batch file using <a href="http://technet.microsoft.com/en-us/library/cc733145%28v=ws.10%29" rel="nofollow">Robocopy</a> with the /mir option along with <a href="http://mercurial.selenic.com/" rel="nofollow">Mercurial</a> SCM to store all versions of the file.  I would do an hg add followed by an hg commit before each execution of Robocopy to save the current state, and then make a mirrored copy of the file structures.   The problem is the /mir will delete every folder not present in the source, and Mercurial stores the repository in a .hg folder in the destination folder.  </p>
<p><strong>Does anybody know how I could either convince Mercurial to store the .hg folder elsewhere, or convince Robocopy not to delete it from the destination?</strong></p>
<p>I&#8217;m trying to avoid writing a custom program do to copying.  </p>
<div class="author">Asked by <a href="http://serverfault.com/users/90071/andrew-neely" target="_blank">Andrew Neely</a></div>
<h3 class="pa"><img src="http://adminsgoodies.com/imgs/answer.png" alt="Answer" /></h3>
<p>To perform a mirror while ignoring certain file exentions, try this:</p>
<pre><code>robocopy c:\temp\source c:\temp\dest /e /purge /xf *.hg
</code></pre>
<p>I tested it a bit here and it appears to leave the .hg files alone on the destination</p>
<p>I also recommend the /z flag (restartable for large files) and have had to resort to the /fft flag in the past when dealing with servers having different time granularity : <a href="http://www.readynas.com/forum/viewtopic.php?t=3573" rel="nofollow">http://www.readynas.com/forum/viewtopic.php?t=3573</a></p>
<p>edit:<br />
&#8230; my example above was assuming files named *.hg &#8230;  to do the same and ignore directories named *.hg, use this :</p>
<pre><code>robocopy c:\temp\source c:\temp\dest /e /z /purge /xd *.hg
</code></pre>
<div class="author">Answered by <a href="http://serverfault.com/users/44749/brianadkins" target="_blank">BrianAdkins</a></div>
<p class="ref-link">Check <a href="http://serverfault.com/questions/405398/backup-with-mercurial-and-robocopy" target="_blank">more discussion</a> of this question.</p>
]]></content:encoded>
			<wfw:commentRss>http://adminsgoodies.com/backup-with-mercurial-and-robocopy/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Copying files to a different domain, where no trust relationship exists</title>
		<link>http://adminsgoodies.com/copying-files-to-a-different-domain-where-no-trust-relationship-exists/</link>
		<comments>http://adminsgoodies.com/copying-files-to-a-different-domain-where-no-trust-relationship-exists/#comments</comments>
		<pubDate>Sat, 05 May 2012 16:33:10 +0000</pubDate>
		<dc:creator>tom</dc:creator>
				<category><![CDATA[General Questions]]></category>
		<category><![CDATA[authentication]]></category>
		<category><![CDATA[domain]]></category>
		<category><![CDATA[file-copy]]></category>
		<category><![CDATA[robocopy]]></category>
		<category><![CDATA[runas]]></category>

		<guid isPermaLink="false">http://adminsgoodies.com/copying-files-to-a-different-domain-where-no-trust-relationship-exists/</guid>
		<description><![CDATA[I have the the following setup. 1 x host machine situated in DOMAIN A 1 x PDC in a VM running on a host only network adapter running its own AD Forest (DOMAIN B) 1 x Server running in DOMAIN B, this is also on a host only network adapter but has a secondary adapter which is running in NAT mode Via VirtualBox (the PDC is running in the same VirtualBox instance). I need to [...]]]></description>
				<content:encoded><![CDATA[<h3 class="pq"><img src="http://adminsgoodies.com/imgs/question.png" alt="Question" /></h3>
<p>I have the the following setup.</p>
<p>1 x host machine situated in DOMAIN A<br />
1 x PDC in a VM running on a host only network adapter running its own AD Forest (DOMAIN B)<br />
1 x Server running in DOMAIN B, this is also on a host only network adapter but has a secondary adapter which is running in NAT mode Via VirtualBox (the PDC is running in the same VirtualBox instance).</p>
<p>I need to take files in DOMAIN A and copy using ROBOCOPY to DOMAIN B where no trust relationship exists, DOMAIN B is totally isolated and is never allowed to talk to DOMAIN A in any fashion at all.</p>
<p>One way of doing this would be to use PSEXEC from sysinternals and copy the files using the networkpath to the files FROM DOMAIN B this approach has been <strong>ruled out entirely</strong>, for various reasons, one of which is time and the reworking of a process that would take too long (allthough it would be possible)</p>
<p>I can copy the files with runas with the <code>/netonly</code> switch without issue manually from a cmd line giving run as the password at runtime, this all works.</p>
<p>The problem is I am running this copy from inside a rake command which invokes Robocopy using the MSBuild Extensions (just executes Robocopy.exe).</p>
<p>Is there a thirdparty of runas or equivalent tool that allows the <code>/netonly</code> behaviour of runas with the password given as a switch ?</p>
<p>the equivalent syntax for runas (if runas supported this behaviour) would be the following:</p>
<p><code>runas /user:user@domain.com /password:password /netonly "c:\system32\robocopy.exe C:\somedir \"\\TARGETSERVER\c$\somedir\" \"*.*\" /MIR /A-:R"</code></p>
<div class="author">Asked by <a href="http://serverfault.com/users/56385/krystan-honour" target="_blank">krystan honour</a></div>
<h3 class="pa"><img src="http://adminsgoodies.com/imgs/answer.png" alt="Answer" /></h3>
<p>You could simply connect to the destination share through a different security context using the <code>net use \\targetserver\c$\somedir /USER:DOMAIN\user password</code> syntax.</p>
<p>Omitting the drive letter in the <code>net use</code> call creates an authenticated SMB connection to a remote share within the given security context of <em>DOMAIN\user</em>. After the connection is established, you can use  references to \targetserver\c$\somedir in your <code>robocopy</code> call.</p>
<div class="author">Answered by <a href="http://serverfault.com/users/76595/syneticon-dj" target="_blank">syneticon-dj</a></div>
<p class="ref-link">Check <a href="http://serverfault.com/questions/383079/copying-files-to-a-different-domain-where-no-trust-relationship-exists" target="_blank">more discussion</a> of this question.</p>
]]></content:encoded>
			<wfw:commentRss>http://adminsgoodies.com/copying-files-to-a-different-domain-where-no-trust-relationship-exists/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Exchange DiskShadow/Robocopy backup does not purge log files</title>
		<link>http://adminsgoodies.com/exchange-diskshadowrobocopy-backup-does-not-purge-log-files/</link>
		<comments>http://adminsgoodies.com/exchange-diskshadowrobocopy-backup-does-not-purge-log-files/#comments</comments>
		<pubDate>Tue, 17 Apr 2012 22:33:04 +0000</pubDate>
		<dc:creator>tom</dc:creator>
				<category><![CDATA[General Questions]]></category>
		<category><![CDATA[backup]]></category>
		<category><![CDATA[exchange]]></category>
		<category><![CDATA[robocopy]]></category>
		<category><![CDATA[vss]]></category>
		<category><![CDATA[windows-server-2008]]></category>

		<guid isPermaLink="false">http://adminsgoodies.com/exchange-diskshadowrobocopy-backup-does-not-purge-log-files/</guid>
		<description><![CDATA[I have a series of scripts setup to backup my Exchange. The following command is executed to start the process: diskshadow /s C:\Backup_Scripts\exchangeserverbackupscript1.dsh This is exchangeserverbackupscript1.dsh: #DiskShadow script fileset verbose on #delete shadows all set context persistent writer verify {76fe1ac4-15f7-4bcd-987e-8e1acb462fb7} set metadata C:\Backup_Scripts\shadowmetadata.cab begin backup add volume C: alias SH1createexpose %SH1% P: exec C:\Backup_Scripts\exchangeserverbackupscript1.cmd end backup delete shadows exposed P: exit #End of script And this is exchangeserverbackupscript1.cmd: robocopy "P:\Program Files\Microsoft\Exchange Server\Mailbox\First Storage Group" "\\leahyfs\J$\E-Mail [...]]]></description>
				<content:encoded><![CDATA[<h3 class="pq"><img src="http://adminsgoodies.com/imgs/question.png" alt="Question" /></h3>
<p>I have a series of scripts setup to backup my Exchange.  The following command is executed to start the process:</p>
<pre><code>diskshadow /s C:\Backup_Scripts\exchangeserverbackupscript1.dsh
</code></pre>
<p>This is <em>exchangeserverbackupscript1.dsh</em>:</p>
<pre><code>#DiskShadow script fileset verbose on
#delete shadows all
set context persistent
writer verify {76fe1ac4-15f7-4bcd-987e-8e1acb462fb7}
set metadata C:\Backup_Scripts\shadowmetadata.cab
begin backup
add volume C: alias SH1createexpose %SH1% P:
exec C:\Backup_Scripts\exchangeserverbackupscript1.cmd
end backup
delete shadows exposed P:
exit
#End of script
</code></pre>
<p>And this is <em>exchangeserverbackupscript1.cmd</em>:</p>
<pre><code>robocopy "P:\Program Files\Microsoft\Exchange Server\Mailbox\First Storage Group" "\\leahyfs\J$\E-Mail Backups\Day 1" /MIR /R:0 /W:0 /COPY:DT /B
</code></pre>
<p>This is not causing Exchange to purge its log files.  The <em>edb</em> file is 4.7 gigabytes, but the <em>First Storage Group</em> folder itself is 50+ gigabytes due to many, many log files for each day <strong>going back to 2009</strong>.</p>
<p>Is there any way &#8212; I&#8217;ve Googled and haven&#8217;t found anything &#8212; to notify Exchange when I&#8217;ve completed a full backup, and have it purge its log files?</p>
<p>According to <a href="http://theessentialexchange.com/blogs/michael/archive/2009/01/23/exchange-2007-and-windows-2008-using-diskshadow-for-online-exchange-backup-part-5-of-7.aspx" rel="nofollow">this</a> and <a href="http://theessentialexchange.com/blogs/michael/archive/2009/01/14/volume-shadow-copy-services-vss-and-exchange-the-basics.aspx" rel="nofollow">this</a>, <em>end backup</em> should cause Exchange to &#8220;<em>flush the transaction logs for that storage group</em>&#8221; but only &#8220;<em>if a successful backup of a storage group occurred</em>&#8220;, which leaves my question as:</p>
<p><em>What constitutes a &#8220;successful backup&#8221;, and why is what I&#8217;m doing not it?</em></p>
<div class="author">Asked by <a href="http://serverfault.com/users/111509/robert-allan-hennigan-leahy" target="_blank">Robert Allan Hennigan Leahy</a></div>
<h3 class="pa"><img src="http://adminsgoodies.com/imgs/answer.png" alt="Answer" /></h3>
<p>In general, the BEGIN BACKUP / END BACKUP block would signal Exchange to truncate the logs. But in order for it to work, you should have created a snapshot of <em>all</em> volumes with Exchange-related data &#8211; so if you have separated data and transaction logs, you would need to snapshot both &#8211; the data <em>and</em> the Tlog volume.</p>
<p>Also, you should make sure that your script <code>exchangeserverbackupscript1.cmd</code> really returns with an exit code of zero &#8211; if it does not the <a href="http://technet.microsoft.com/de-de/library/cc771191%28v=ws.10%29.aspx" rel="nofollow">diskshadow script would abort</a> and the &#8220;end backup&#8221; line would never get executed. I believe robocopy would exit with the exit code of &#8220;1&#8243; upon successful file copy which might present the root of your problem as the errorlevel of robocopy would be the errorlevel of your batch if the robocopy is the last executed command. Try adding a conditional checking for robocopy&#8217;s success and an <code>exit /B 0</code> to the end of your batch file.</p>
<div class="author">Answered by <a href="http://serverfault.com/users/76595/syneticon-dj" target="_blank">syneticon-dj</a></div>
<p class="ref-link">Check <a href="http://serverfault.com/questions/380403/exchange-diskshadow-robocopy-backup-does-not-purge-log-files" target="_blank">more discussion</a> of this question.</p>
]]></content:encoded>
			<wfw:commentRss>http://adminsgoodies.com/exchange-diskshadowrobocopy-backup-does-not-purge-log-files/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Do Robocopy copy efficiently large files?</title>
		<link>http://adminsgoodies.com/do-robocopy-copy-efficiently-large-files/</link>
		<comments>http://adminsgoodies.com/do-robocopy-copy-efficiently-large-files/#comments</comments>
		<pubDate>Sun, 18 Mar 2012 12:33:38 +0000</pubDate>
		<dc:creator>tom</dc:creator>
				<category><![CDATA[General Questions]]></category>
		<category><![CDATA[robocopy]]></category>
		<category><![CDATA[rsync]]></category>

		<guid isPermaLink="false">http://adminsgoodies.com/do-robocopy-copy-efficiently-large-files/</guid>
		<description><![CDATA[in our small sized company we use Vmware. We backup the VM with Veeam. Resulting files are in order of 200-300 gigabyte per VM, for a total of 1/1.2 terabyte of data. I use robocopy to copy VM files backuped to external hard drive. I would like to know if Robocopy use something like rsync to copy only changed &#8216;blocks&#8217; of data instead the entirely file . Thanks Asked by stighy Robocopy doesn&#8217;t use any [...]]]></description>
				<content:encoded><![CDATA[<h3 class="pq"><img src="http://adminsgoodies.com/imgs/question.png" alt="Question" /></h3>
<p>in our small sized company we use Vmware. We backup the VM with Veeam.<br />
Resulting files are in order of 200-300 gigabyte per VM, for a total of 1/1.2 terabyte of data.<br />
I use robocopy to copy VM files backuped to external hard drive. I would like to know if Robocopy use something like rsync to copy only changed &#8216;blocks&#8217; of data instead the entirely file .<br />
Thanks</p>
<div class="author">Asked by <a href="http://serverfault.com/users/13809/stighy" target="_blank">stighy</a></div>
<h3 class="pa"><img src="http://adminsgoodies.com/imgs/answer.png" alt="Answer" /></h3>
<p>Robocopy doesn&#8217;t use any method to transmit only changed blocks of datas.  </p>
<p>If you have to transmit your files thru a slow network, just use rsync.<br />
If you have to transmit your files thru a &#8220;reasonable speed&#8221; network, no algorithm can speedup the process, because rsync (for example) have to read the entire file on client and on server to find duplicate contents. So if your network is Gigabit, or if you do a local copy, you just copy the files and voila. You can&#8217;t get something better, execpted if supported by the filesystem (ala ZFS, but only works on the same partition).</p>
<div class="author">Answered by <a href="http://serverfault.com/users/108339/gregory-moussat" target="_blank">Gregory MOUSSAT</a></div>
<p class="ref-link">Check <a href="http://serverfault.com/questions/370692/do-robocopy-copy-efficiently-large-files" target="_blank">more discussion</a> of this question.</p>
]]></content:encoded>
			<wfw:commentRss>http://adminsgoodies.com/do-robocopy-copy-efficiently-large-files/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Robocopy &#8211; Change Modified Date</title>
		<link>http://adminsgoodies.com/robocopy-change-modified-date/</link>
		<comments>http://adminsgoodies.com/robocopy-change-modified-date/#comments</comments>
		<pubDate>Tue, 21 Feb 2012 19:34:44 +0000</pubDate>
		<dc:creator>tom</dc:creator>
				<category><![CDATA[General Questions]]></category>
		<category><![CDATA[robocopy]]></category>

		<guid isPermaLink="false">http://adminsgoodies.com/robocopy-change-modified-date/</guid>
		<description><![CDATA[I&#8217;m copying a file over to another directory and was wondering if Robocopy can change the modified date to the date it copied the file over in the new directory. I haven&#8217;t been successful playing with the switches. Set Source="C:\Dir\ Set Dest="C:\Dir\TMProbocopy /V /IS "%Source%" "%Dest%" /NOCOPY I want test.txt (modified 01/23/12) to copy over to the TMP directory with a new date modified of time of copy. Asked by Rowell My solution was to [...]]]></description>
				<content:encoded><![CDATA[<h3 class="pq"><img src="http://adminsgoodies.com/imgs/question.png" alt="Question" /></h3>
<p>I&#8217;m copying a file over to another directory and was wondering if Robocopy can change the modified date to the date it copied the file over in the new directory. I haven&#8217;t been successful playing with the switches. </p>
<pre><code>Set Source="C:\Dir\
Set Dest="C:\Dir\TMProbocopy /V /IS "%Source%" "%Dest%" /NOCOPY
</code></pre>
<p>I want test.txt (modified 01/23/12) to copy over to the TMP directory with a new date modified of time of copy.</p>
<div class="author">Asked by <a href="http://serverfault.com/users/97523/rowell" target="_blank">Rowell</a></div>
<h3 class="pa"><img src="http://adminsgoodies.com/imgs/answer.png" alt="Answer" /></h3>
<p>My solution was to use a batch file:</p>
<pre><code>Echo %date% %time% &gt; testfile.txt
</code></pre>
<p>That will include the date and time within the text file and also update the modified date to the file.</p>
<div class="author">Answered by <a href="http://serverfault.com/users/97523/rowell" target="_blank">Rowell</a></div>
<p class="ref-link">Check <a href="http://serverfault.com/questions/353295/robocopy-change-modified-date" target="_blank">more discussion</a> of this question.</p>
]]></content:encoded>
			<wfw:commentRss>http://adminsgoodies.com/robocopy-change-modified-date/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to sync web site files cross Windows Web Server 2008 R2 servers in realtime?</title>
		<link>http://adminsgoodies.com/how-to-sync-web-site-files-cross-windows-web-server-2008-r2-servers-in-realtime/</link>
		<comments>http://adminsgoodies.com/how-to-sync-web-site-files-cross-windows-web-server-2008-r2-servers-in-realtime/#comments</comments>
		<pubDate>Tue, 27 Dec 2011 02:30:10 +0000</pubDate>
		<dc:creator>tom</dc:creator>
				<category><![CDATA[General Questions]]></category>
		<category><![CDATA[dfs]]></category>
		<category><![CDATA[robocopy]]></category>
		<category><![CDATA[windows]]></category>

		<guid isPermaLink="false">http://adminsgoodies.com/how-to-sync-web-site-files-cross-windows-web-server-2008-r2-servers-in-realtime/</guid>
		<description><![CDATA[I have a web site generating files at runtime, this web site is deployed on 2 servers Operation system, Windows Web Server 2008 R2. I am looking for a manner to sync the changed and new files from one server to another, one-way sync. DFS-R, anybody succeed in installing DFS-R on Windows Web Server 2008 R2? here is an article http://blogs.technet.com/b/filecab/archive/2008/05/14/installing-dfs-replication-on-windows-server-2008.aspx, which does not work for 2008 R2 any more. robocopy, I tried this one, [...]]]></description>
				<content:encoded><![CDATA[<h3 class="pq"><img src="http://adminsgoodies.com/imgs/question.png" alt="Question" /></h3>
<p>I have a web site generating files at runtime, this web site is deployed on 2 servers</p>
<p>Operation system, Windows Web Server 2008 R2.</p>
<p>I am looking for a manner to sync the changed and new files from one server to another, one-way sync.</p>
<p><strong>DFS-R</strong>, anybody succeed in installing DFS-R on Windows Web Server 2008 R2? here is an article <a href="http://blogs.technet.com/b/filecab/archive/2008/05/14/installing-dfs-replication-on-windows-server-2008.aspx" rel="nofollow">http://blogs.technet.com/b/filecab/archive/2008/05/14/installing-dfs-replication-on-windows-server-2008.aspx</a>,  which does not work for 2008 <strong>R2</strong> any more.</p>
<p><strong>robocopy</strong>, I tried this one,  but it does not perform very well and sometimes there is  everal minutes delay before the changed file is synced.</p>
<p>Please do you have any suggestion to me? </p>
<p>Thanks</p>
<h3 class="pa"><img src="http://adminsgoodies.com/imgs/answer.png" alt="Answer" /></h3>
<p>I use DFS-R on a bunch of Windows 2008 R2 Standard Webservers for the web content without a problem. They all need to be members of a domain, but I remember the wizard being fairly clickety-straightforward.</p>
<p>You simply install the DFS components on all the servers you want to sync, and then on one of them set up all the replicated folders and add all the clients to that replicated folder.</p>
<p><a href="http://cosonok.blogspot.com/2011/08/walkthrough-windows-server-2008-r2-dfs.html" rel="nofollow">This link</a> seems to cover the steps quite well.</p>
<p>N.B. &#8211; you say &#8216;realtime&#8217; &#8211; this means different things to different people. What sort of a lag is tolerable for you? Solutions vary (in complexity and cost) depending on whether you can tolerate 5 minutes, 5 seconds, or 5 milliseconds.</p>
<h2>Edit</h2>
<p>I missed where you said you had Server 2008 R2 Web Edition, you&#8217;re right that doesn&#8217;t come with DFS. This leaves you with two other options:</p>
<ol>
<li>
<p>Save all runtime configures to some persistent shared storage, either a network drive that all nodes can see, or to a database somehow.</p>
</li>
<li>
<p>Hack together Robocopy, rsync, or some other filesystem sync framework to handle the replication.</p>
</li>
</ol>
<p>Personally, I&#8217;ve never found (2) to be particularly reliable. It might work at first, but silent failures can cause a lot of issues. If it&#8217;s only small files, (1) might not be a bad idea. In an ideally architected world, web servers shouldn&#8217;t be storing transient but shared data on their filesystems anyway, precisely because of this synchronization issue. However, I appreciate that re-building everything just to solve this might not be the most available option. In this case, I&#8217;d probably push for resource to upgrade to Server 2008 Standard Edition &#8211; DFS really does work very well, and MS presumably removed it from Web Edition to push more advanced deployments onto Standard.</p>
<p>Alternatively, you can take a look at the IIS <a href="http://www.iis.net/download/WebFarmFramework" rel="nofollow">Web Farm Framework</a>. I&#8217;ve never played with it myself, but it looks like it might have some filesystem syncrhonization features in it. I can&#8217;t guarantee that it&#8217;ll do what you want though.</p>
<p class="ref-link">Check <a href="http://serverfault.com/questions/344162/how-to-sync-web-site-files-cross-windows-web-server-2008-r2-servers-in-realtime" target="_blank">more discussion</a> of this question.</p>
]]></content:encoded>
			<wfw:commentRss>http://adminsgoodies.com/how-to-sync-web-site-files-cross-windows-web-server-2008-r2-servers-in-realtime/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
