Solved

xcopy help

Posted on 2011-03-17
9
494 Views
Last Modified: 2012-05-11
Hi,

I have an XCOPY command:

xcopy "E:\apps\Hyperion\common\import_export\planadmin@Native Directory\Planning_TS_EMBUD_All\*.*" "\\lynx\HyperionDev_Backups\Essbase_Backup\DEV_BKUPS\DEV_Weekly\03172011_Thu\LCM_BKUPS\Planning_TS_EMBUD_All\*.*" /Y /S /E /i >> LCM_Backup.log

It runs and starts copying then it just quits and stops and is not copying all the subfolders and folders.  Am i doing something wrong?  Is there a better command to copy an entire directory?
0
Comment
Question by:elwayisgod
  • 4
  • 3
  • 2
9 Comments
 
LVL 13

Expert Comment

by:AustinComputerLabs
ID: 35159894
I use the /s/h/e/r/c/k/y switches with XCOPY to copy everything and continue on errors.
0
 

Author Comment

by:elwayisgod
ID: 35159992
Nope.. Still stops... It's only happening from a certain server too.  What on gods earth could possibly be happening on a specific server all of a sudden.  This XCOPY was working flawlessly uptil a few days ago....
0
 
LVL 11

Expert Comment

by:yelbaglf
ID: 35160020
Here's the technet article that shows you all the syntax options.
http://technet.microsoft.com/en-us/library/bb491035.aspx

If you're not opposed to using robocopy, have a look at my solution here.
http://www.experts-exchange.com/Networking/Misc/Q_26865402.html?sfQueryTermInfo=1+10+30+robocopi+yelbaglf#a35040865
0
Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

 

Author Comment

by:elwayisgod
ID: 35160034
Client will not allow Robocopy to be installed :(
0
 
LVL 13

Expert Comment

by:AustinComputerLabs
ID: 35160114
Can you try a mapped drive instead of UNC for the destination?
0
 
LVL 11

Accepted Solution

by:
yelbaglf earned 250 total points
ID: 35160341
Technically it doesn't have to be installed.  It's just an .exe in the Win Svr support tools.
http://www.microsoft.com/downloads/en/details.aspx?FamilyID=9d467a69-57ff-4ae7-96ee-b18c4790cffd&displaylang=en

But, if xcopy is the preferred method, then try something like this.
xcopy [SOURCE] [DEST] /E /C /I /F /H /R /K /X /Y >> \\Dest\log.txt
0
 
LVL 11

Expert Comment

by:yelbaglf
ID: 35160351
Another note is that you might consider shortening and simplifying your folder/directory naming structure beforehand.  This might be causing an issue as well.
0
 

Author Comment

by:elwayisgod
ID: 35161257
It's a folder length issue... When I actually watch the cmd window an error pops up about 'out of memory'.  It's not a actual RAM issue or anything.  Further investigation shows it's limited to 255 total characters.  Thus my source and destination combined sometimes was over that.  So I shortened it for now as best I could and it's working but it's hard as the software determines the path where these xml files are stored.....
0
 
LVL 11

Expert Comment

by:yelbaglf
ID: 35161377
I know how you feel.  I've dealt with this in the past, and it's no fun!  I'm glad to hear we have some functionality finally.
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

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

Suggested Solutions

This script will sweep a range of IP addresses (class c only, 255.255.255.0) and report to a log the version of office installed. What it does: 1.)      Creates log file in the directory the script is run from (if it doesn't already exist) 2.)      Sweep…
Over the years I have built up my own little library of code snippets that I refer to when programming or writing a script.  Many of these have come from the web or adaptations from snippets I find on the Web.  Periodically I add to them when I come…
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/28997919/Pagination-in-Adobe-Acrobat.html) here at Experts Exchange, a member asked how to add page numbers to a PDF file using Adobe Acrobat XI Pro. This short video Micro Tutorial sh…

816 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

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now