Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [xcopy]

The tag has no usage guidance.

0
votes
0answers
11 views

Dos Xcopy - Empty parent directory in Root will not copy to another empty directory in root

What I am trying to do is copy an empty directory located in the root of a drive to another empty directory located in the root of the same drive as the source. Eg. xcopy C:\example2 C:\example /E /...
0
votes
2answers
55 views

Copy all files from all folders Windows CMD

I have this structure in Windows Server: PARENT DIRECTORY ├───DIRECTORY1 │ ├───FILEA │ └───FILEB ├───DIRECTORY2 │ ├───FILEC │ └───FILED └───DEST_DIRECTORY I want to copy only ...
0
votes
1answer
42 views

copying from subdirectories to one directory windows bat [closed]

I'd like to copy all files from subdirectories to one destination, using Windows bat. Example: Files to copy: C:\src\a\1.bmp C:\src\a\2.bmp C:\src\a\b\3.bmp Copied files: C:\dst\1.bmp C:\dst\2.bmp C:...
1
vote
1answer
46 views

Copied empty folder on top of C:\ using xcopy - what happened?

I was testing xcopy on Windows 10 for use in scripts and, in haste, I run: xcopy /s /e /y /x "%~dp0/aaaaaaaaaa" "C:/" where aaaaaaaaaa is an empty folder. /s /e /y /x does the copy recursively, ...
1
vote
1answer
51 views

Share a folder with user 'Everyone' without asking to login?

I shared a folder on a WinServer2012 with username 'Everyone' for read/write. From XP it doesn't ask for login, while from Win7 login box pops up. How to accomplish to not being asked from Win7 too? ...
0
votes
0answers
10 views

Can't recover my files after xcopy was interupted [duplicate]

I was running xcopy when my computer turned off from a power shortage when turning on again the chdisk ran, now my 1Tb hard drive formatted as NTFS is reported only as a 32mb drive as Raw. Is there a ...
1
vote
1answer
218 views

Copy subfolders and their content up one level?

Right now I have the following structure Folder 1\ -Apr2007\folder 1 \folder 2 \folder 3 -May 2007\folder 23 \folder 24 \folder 25 ...
0
votes
0answers
164 views

Using xcopy to extract&copy files from certain subfolders

I have some data that is systematically organised into multiple-level subfolders, and I would like to copy all files that reside under certain subfolders, which I would like to specify using regexp-...
0
votes
1answer
121 views

XCOPY Command options

xcopy command used with option /d only compares the dates of the source and destination files. So if the dates are same it overlooks the time stamp of the files to determine which is newer. This ...
1
vote
1answer
59 views

Copy several files and send each to a specific subfolder

I have a folder containing CD covers in .jpg and another folder containing subfolders, each with the corresponding CD. I want to send each CD cover to its corresponding subfolder. They are already ...
0
votes
0answers
51 views

Taking out one level out of a directory tree

I've been trying for a while now to find an efficient way to compact the large directory trees of more than 10 external hard disks. I'll describe the problem in some detail so as to avoid ...
0
votes
2answers
245 views

Win 10 XCOPY partial extension match

There is a file named README.cppclean in a directory hierarchy. I want to copy all *.cpp files from the directory tree but not the *.cppclean file. All of the commands below do copy the .cppclean ...
0
votes
1answer
26 views

How is this a cyclyc copy?

In the following directory structure: root/ web/ index.html etc... release_package/ web/ app.dll I performed this command: xcopy "./web/*.*" "./...
3
votes
2answers
8k views

How do I track the progress of XCopy command while It's running?

OPSYS: Win10Pro 64 bit RAM: 10GB I created a batch file which I then saved to the desktop of the local Administrator account. The batch file command line is this: xcopy "F:\movies" "L:\movies" ...
0
votes
0answers
323 views

Copying “System Volume Information” Folder Contents (Win 7 Pro 64 Bit)

I've tried the information in other answers, particularly Permissions: System Volume Information folder, Windows 7, I also tried changing ownership with TAKEOWN in a command window, and XCOPY, but to ...
0
votes
0answers
57 views

xcopy - copying a file to multiple users

Using xcopy, I've been looking for a way to copy over a file (or multiple, but haven't seen many cases for single files) to the source destination. After reading xcopy syntax online, I would presume ...
3
votes
3answers
6k views

How to copy one directory to another with window command prompt?

I read alot of guides about to copy directories. On SO also read the posts Commmand line command to copy entire directory (including directory folder) to another directory copying all contents of ...
2
votes
2answers
483 views

copy array in a batch file

I have several files located across several directories/subfolders that I need to copy to several destinations. I currently do this using xcopy but I do it line by line, so there are several lines of ...
1
vote
1answer
322 views

How to maintain relative symbolic links during copy?

I have a directory structure with a bunch of relative symbolic links. Example: e:\test e:\test\foo\a --> "..\bar" e:\test\bar\b --> "..\foo" Is there a way to copy the entirety of the directory from ...
1
vote
1answer
6k views

XCopy encounters a sharing violation, how to handle

I'm using xcopy for copying large bundles of files. One thing I particularly like about xcopy is the /F switch which shows all source and destination files, paths included, something like: xcopy /E /...
0
votes
0answers
958 views

Why doesn't XCOPY copy my symbolic link?

I have a folder contain a directory symbolic link, with its structure as following: my-folder - sub-directory - symbolic link (link to d:\some-folder) - file The xcopy command I used is xcopy /e ...
0
votes
1answer
1k views

Xcopy error: invalid number of parameters

I want to copy an entire directory to another directory. I tried this: xcopy SourceDir= C:libraries\documents TargetDir=C:\S:\V (E) Backup I know people don't usually use specifics, but those are ...
1
vote
0answers
111 views

Migrating Domain Users to another Domain

I have a kiosk user on which many workstations are logged in currently. I am working on a project to move everyone from Kiosk to their own domain user so instead of using kiosk user called USER I want ...
0
votes
0answers
72 views

Copying one random image file from multiple folders

So iv'e been trying to find an answer for this issue for a while now, note i am not at all computer savvy (at least not when it comes to code etc.) here goes my issue: I am a photographer with ...
4
votes
2answers
873 views

Is it possible to get an `errorlevel 1` from `xcopy` in Windows 10?

Microsoft documentation states that the xcopy exit codes are Exit code Description 0 Files were copied without error. 1 No files were found to copy. 2 The user ...
0
votes
2answers
663 views

xcopy changed file content on windows 10

I've copied cca 180 GB using xcopy SRC DST /C /E /Q on Windows 10. The Files are mostly video files and/or presentations (ppt/pptx/pdf). I've noticed strange behavior: some of the copied files (2133 ...
0
votes
2answers
162 views

how to backup os of server using xcopy

I have been able to backup some files with the xcopy command using the following code in my batch file. xcopy /e /s /d /i /y "C:\Users\ba\Desktop\all\a" "C:\Users\ba\Desktop\all\bb" >> "C:...
0
votes
0answers
126 views

Copy only if destination was modified on a specific date

To make a long story short, after being hacked with ransom virus on my server 2008 r2 (and paying to decrypt the files) I still have a lot of files that are not accessible. So I want to copy from a ...
1
vote
1answer
446 views

batch copy folder located by guid

In a batch file, can I copy a folder located by a constant path like \?\Volume{GUID}? When copying (copy, xcopy or robocopy) a directory and its content from a local removable drive (a usb external ...
0
votes
0answers
231 views

Copy only some subdirectories

I have a large and deep directory structure and I want to copy only some specific subfolders. Like for example, copy only (minimatch notation) ./foo/bar/baz/**/* and ./bar/foo/**/* but exclude ...
0
votes
0answers
229 views

How do i fix cyclic redundancy check error and cant read source from disk error?

I copied a a game to a partition on my external hard-drive. Then i tried to copy the game back to my PC. every file in the game folder except the ones with a ( .bin) extension were copies successfully....
6
votes
1answer
12k views

Using xCopy to create entire folder structure, including root folder name and all files

I looked at quite a few solutions to xCopy questions, and tried many difference methods. (Various wildcards, paths ending in \, various xcopy switches in various combinations.) xCopy c:\Public d:\...
0
votes
2answers
260 views

How to deal with copy/xcopy from a virtual machine

I'm working with several virtual machines, one of them being Windows 7. I'd like to copy files from that machine to my machine (which is Windows XP). Until now this is done using ...
0
votes
1answer
550 views

Xcopy doesn't copy, just 0?

By using the command below it works, but without copying anything. xcopy "F:/*.*" "G:/some Thing" /s /e /c /h /i /d /r /k /y /z PAUSE It shows: 0 Files copied It's the same with or without ...
0
votes
0answers
23 views

How to search subdirectories for files and then copy them? [duplicate]

When I use the findstr command, I can put /s and that will search all the subdirectories. With the copy command, is there such a thing as well? It only seems to copy files within a specific directory ...
1
vote
0answers
790 views

Windows: How to copy specific subfolders and keep folder structure?

I have many sub folders in root folder, they are structured in year \ month \ day way, e.g, root_folder \-A folder \--2012 <--- year \--01 <--- ...
0
votes
1answer
30 views

how can copy contents of a folder which is does not have a folder name using CMD

Due to virus when I open a pen drive it shows like this: I want to make a .bat file to copy contents of this folder to another directory. I can use open cmd and usingxcopy D:\" " /s D:\ to do that ...
0
votes
1answer
1k views

Copy Folder in Windows CMD

How can I copy folder in windows cmd. I would like to copy folder it self with files in it, not just files. When you use copy or xcopy commands they copy files but not folder name. xcopy folderOne ...
1
vote
1answer
222 views

XCOPY /exclude reference a ext file that is not in the working directory

I have tried to reference the directory of the text file after /exclusions. What is wrong with my syntax? xcopy "J:\Common\NY SERTIFIKATBANK\18 Buoyancy Reports\Nav Lights\534515" "534515" /I /...
1
vote
1answer
340 views

Windows XCOPY results from FIND command

Windows 7 CMD I can retrieve a list of files by the following command dir /b | find "TENDER_NUM 2". I'm trying to copy all the files that were returned by find into another folder. I've tried: for /...
-2
votes
1answer
32 views

how to move files from sub-folder to folder

I've got: C:/PICS/ASF/photos/files (.jpg) C:/PICS/DFS/photos/files (.jpg) C:/PICS/HGD/photos/files (.jpg) C:/PICS/FTG/photos/files (.jpg) .....etc In every "photos" directory is more than one ....
2
votes
2answers
755 views

Xcopy: why /x (System Access Control List information)

I can't get more info about the /x switch than: This option copies file audit settings and System Access Control List (SACL) information. You imply /o when you use the /x option. I am trying to ...
1
vote
0answers
965 views

Windows Batch to copy one file to multiple directories

I have a rather simple copy and paste batch job. That checks for a more recent file and overwrites it. I was trying to take a single COPY and copy it to a second directory. In simple, this Batch is ...
1
vote
1answer
572 views

Possible to copy files and directory structure but don't copy file contents (i.e. 0 byte file size)?

I'm wondering if it's possible to copy files and directory structure, but don't actually copy file contents. I want to copy over file names and extensions but have each individual file be 0 bytes in ...
4
votes
2answers
5k views

How to copy a directory on Windows, preserving timestamps of all directories being copied

I want to copy a directory tree while preserving timestamps of any file and directory descendant that is being copied. The source directory is on a data DVD (ISO-9660 filesystem). I am copying to an ...
0
votes
0answers
338 views

how to copy a folder and its contents to another folder using xcopy?

So I've been trying to copy a folder to another folder. But whatever I do, it only copies the file(s) inside the source folder. I've looked at numerous examples like: ss64 example microsoft example ...
0
votes
1answer
425 views

Trouble in using Xcopy to copy to a network path in batch file

Code: ::CopyTest.bat @ECHO echo 123>>%temp%\MBDocuments.txt xcopy "C:\Users\Foo\Documents\" pushd "X:\foo team\Team Members\foo\Documents" del /q %temp%\MBDocuments.txt pause So I have another ...
1
vote
1answer
493 views

How to back up only newer files

I wrote years ago a script using XCOPY with parameters /E /D /Y /V /R /H that allowed me to back up newer files to my dropbox having always everything updated. Since I upgraded to Windows 7 and 10 ...
1
vote
1answer
839 views

Windows cmd copy directories and content recursively if the files do not exist

The question fits in the title: I want to copy from local storage to a network storage directories and their content, but only the new or updated files with no prompt. My idea would be to use xcopy ...
0
votes
1answer
4k views

Move files of particular pattern in batch to another folder [closed]

I am trying to write a Windows batch file with commands for moving files with a pattern the file name from one folder to another folder, and others to others. For example: vision.xls should go to a ...