Robocopy’ing Basics

So, you have a large batch of files and want to move or copy them reliably from one location to another.  (this works for nearly all scenarios:  local->local, local->network, ext hd->local, ext ht->network)

Microsoft TechNet reference for Robocopy

Helpful TechNet Magazine article on Robocopy   and another

Download it here if you don’t already have it

All you have to know is this simple command:

robocopy [destination] –z –e

/Z :: copy files in restartable mode.  This means if the command stops because the network is no longer available or some other reason… all you have to do is re-run the command and it’ll pickup where it left off.

/E :: copy subdirectories, including Empty ones.  This will recreate the exact directory tree… so if you’re copying an entire tree (files and sub-directories) it will exactly recreate it even if there are no files inside of a folder.

image

This command also takes advantage of a few defaults:

/COPY: DAT :: what to COPY for files.   This means the files that are copied, will also transfer over the data, attributes, as well as the timestamps like last modified, etc…

/R:n :: number of Retries on failed copies: default 1 million.  This means if the command fails it will sit and retry up to a million times before failing.  I rely on this since I usually run my command overnight.  If the network goes down, it is probably do to a simple power issue.  The hub will go down but the computers won’t due to my UPS’s.  When power is restored and the hubs come backup, the copy will continue.

/W:n :: Wait time between retries: default is 30 seconds.   If it fails as described previously, this is the timer which runs before retrying.  Every 30 seconds upon a failure. 

 

Robocopy is an essential command that everyone who uses computers should be aware of.  Put this one in your pocket and pull it out when needed. 

Port Scanning?!? oh and Microsoft Threat Management Gateway (TMG)

I am working on learning network security… so I went and picked up the NMAP Network Scanning book (ISBN: 978-0-9799587-1-7) from Gordon Lyon and Insecure.org.
During my reading he talks alot about an Intrusion Detection System (IDS). Apparently IDS’s are used to detect attacks on their networks including something benign as a port scan. This got me thinking… doesn’t my MS Action Pack include something like that… indeed it does… two in fact. The ISA 2006 and it’s newer replacement Threat Management Gateway (TMG 2010).
Any respectable hacker would jump at the chance to set it up and “hack” yourself to see what happens right? OF COURSE!!!

I’ve setup the new system and placed it on the “edge” of my network. This puts it in exactly the right spot to have the largest exposure… right…