Solved

Best Way To Copy New Files To Remote Server

Posted on 2011-02-28
7
361 Views
Last Modified: 2012-05-11
What is the best way to copy new files to a remote server by scripting?  I have a server in the DMZ with staff pictures. I want to schedule a script at night to copy any NEW staff pictures to a folder on the DMZ server rather than wasting resources overwriting old images too.

1. Log into the remote server folder
2. Copy new files only
0
Comment
Question by:twcadmin
  • 4
  • 2
7 Comments
 
LVL 12

Assisted Solution

by:prashanthd
prashanthd earned 400 total points
ID: 34998522
use robocopy
0
 
LVL 12

Expert Comment

by:prashanthd
ID: 34998746
You can use the following command,create a batch file and schedule every night

This willcopyonly file which are not in destination_dir, rest are skipped

robocopy source_dir_path destination_dir_path *.jpeg

http://technet.microsoft.com/en-us/library/cc733145%28WS.10%29.aspx
0
 
LVL 5

Author Comment

by:twcadmin
ID: 34999058
I was hoping there would be a built in command without having to install a new package but no biggie. What about providing credentials to the DMZ server since its not part of the domain?
0
NAS Cloud Backup Strategies

This article explains backup scenarios when using network storage. We review the so-called “3-2-1 strategy” and summarize the methods you can use to send NAS data to the cloud

 
LVL 12

Expert Comment

by:prashanthd
ID: 34999490
source and destination not in domain?
0
 
LVL 5

Author Comment

by:twcadmin
ID: 34999615
Correct. The server is in a DMZ and part of a workgroup not our internal active directory domain. When I connect to a shared folder I have to enter a different username and password.
0
 
LVL 12

Accepted Solution

by:
prashanthd earned 400 total points
ID: 35000072
You can try the following solution

Using Robocopy across domain

http://www.experts-exchange.com/Software/Server_Software/Email_Servers/Exchange/Q_26498453.html
0
 

Assisted Solution

by:Cam3ron
Cam3ron earned 100 total points
ID: 35000180
I think the set params=/e /z line here will accomplish part of your request....doublecheck but i believe it only writes new files to the destination folder....not overwirting current files. I'll have to look and see if i have anything with a user/passwrd command that would help.

here's an example of a batch file I run nightly.

echo off
set source="C:\backup\folder\files"

set destination="\\servername\backup\folder\myfiles"

set params=/e /z
C:\robocopy.exe %source% %destination% %params%
0

Featured Post

Use Case: Protecting a Hybrid Cloud Infrastructure

Microsoft Azure is rapidly becoming the norm in dynamic IT environments. This document describes the challenges that organizations face when protecting data in a hybrid cloud IT environment and presents a use case to demonstrate how Acronis Backup protects all data.

Question has a verified solution.

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

This article is the result of a quest to better understand Task Scheduler 2.0 and all the newer objects available in vbscript in this version over  the limited options we had scripting in Task Scheduler 1.0.  As I started my journey of knowledge I f…
A quick step-by-step overview of installing and configuring Carbonite Server Backup.
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…

808 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