Solved

How to use Robocopy to Copy Files from a network Location

Posted on 2011-02-20
8
4,637 Views
Last Modified: 2012-05-11
Hi All

I have some problems.. I have an external drive 1TB.

Now, i have several network locations which have PST Files on which outlook is running. We need to take backups of the outlook POP3 Users(just in case)..

I want to use powershell robocopy to copy all the PST and put in a folder. For example

\\192.168.0.100\D$\Outlook.pst      (This is the network PC)

F:\Sales Manager\                          (This is the Backup Drive Location)

I want this to be done. Please help me guys.
Thank You
0
Comment
Question by:brandsco
8 Comments
 
LVL 8

Expert Comment

by:Toxacon
ID: 34937080
First of all, there will be problems copying a PST file which is in use. You must copy it while Outlook is not running. Secondly, you are connecting to administrative share, which requires administrative permissions.

1. Make a script that backs up the pst file to some location in local drive ("C:\Backups" for example) when Outlook is not running.
2. Create a BackupAgent user to domain
3. Create a hidden share to workstations (like "Backup$" sharing folder C:\Backups)
4. Allow only the BackupAgent user to connect to the Backup$ share.
5. Connect to that folder with the BackupAgent user instead of ordinary admin.
6. Copy data from the Backup$ share.
0
 
LVL 6

Expert Comment

by:Bxoz
ID: 34937082
In a batch file
 Robocopy \\192.168.0.100\D$\Outlook.pst  F:\Sales Manager /MIR /Z

Open in new window


/MIR : MIRror a directory tree
/Z : Copy files in restartable mode (survive network glitch)
0
 
LVL 1

Author Comment

by:brandsco
ID: 34937100
Ok. I am copying the .pst files when outlook is not running. I am having Domain admins and Enterprise Admins rights. But the command that Bxoz gave results in this manner. Please see the report below

Microsoft Windows [Version 6.1.7600]
Copyright (c) 2009 Microsoft Corporation.  All rights reserved.

C:\Users\siraj.BRANDSCO> Robocopy \\192.168.0.100\D$\Outlook.pst  F:\Sales Manager /MIR /Z

-------------------------------------------------------------------------------
   ROBOCOPY     ::     Robust File Copy for Windows

-------------------------------------------------------------------------------

  Started : Sun Feb 20 16:59:24 2011

   Source : \\192.168.0.100\D$\Outlook.pst\
     Dest : F:\Sales Manager\

    Files : *.*

  Options : *.* /S /E /COPY:DAT /PURGE /MIR /Z /R:1000000 /W:30

------------------------------------------------------------------------------

2011/02/20 16:59:24 ERROR 267 (0x0000010B) Accessing Source Directory \\192.168.
0.100\D$\Outlook.pst\
The directory name is invalid.

C:\Users\siraj.BRANDSCO>
0
Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

 
LVL 8

Expert Comment

by:Toxacon
ID: 34937192
robocopy \\192.168.0.100\d$ "F:\Sales Manager" Outlook.pst /Z

Open in new window

0
 
LVL 6

Expert Comment

by:Bxoz
ID: 34937216
Oops my mistake sorry
0
 
LVL 6

Expert Comment

by:Bxoz
ID: 34937224
The command was for the all directory not the file .pst
0
 
LVL 8

Expert Comment

by:Toxacon
ID: 34937227
Don't use the Mirror option because it will delete contents of the backup folder if you backup multiple computers to the same place.
0
 
LVL 2

Accepted Solution

by:
danny1875 earned 500 total points
ID: 34941968
This is the way i would do it if its any help..

Create a folder for the .pst to sit in, something like 'PST'

Map a network drive to that folder, say X:
Create a 'PST' folder in SalesManager folder

robocopy X:\ C:\SalesManager\PST /E /COPYALL /MIR /ZB /R:2 /W:30 /TEE

just make sure your run it from a command prompt with the correct priviledges.

hope that helps



0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Some time ago I faced the need to use a uniform folder structure that spanned across numerous sites of an enterprise to be used as a common repository for the Software packages of the Configuration Manager 2007 infrastructure. Because the procedu…
A quick step-by-step overview of installing and configuring Carbonite Server Backup.
In this video, we discuss why the need for additional vertical screen space has become more important in recent years, namely, due to the transition in the marketplace of 4x3 computer screens to 16x9 and 16x10 screens (so-called widescreen format). …
With the advent of Windows 10, Microsoft is pushing a Get Windows 10 icon into the notification area (system tray) of qualifying computers. There are many reasons for wanting to remove this icon. This two-part Experts Exchange video Micro Tutorial s…

828 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question