0

I work at a small company without an IT person, and have been tasked with migrating our existing network folders to a new NAS while at the same time restructuring the folders to make more sense. I am therefore looking for suggestions on how best to approach this and not miss anything.

Folder structure will all change but I want to make sure the files all find a new home. I will do this as a manual drag-copy on a file by file basis, re-categorizing the files as they copy, then at the end of all the copying I want to be able to run something that will look for all the files on the old volume and then look on the new volume to make sure that file exists there regardless of path. I was thinking of file-duplicate finding software like CloneSpy for this task as I believe that app can ignore path to find dupes of files, and in theory it should find a duplicate of every file.

One big caveat to all this though is that I have to do this while people are still working on the network files, and it is going to take me a few weeks to go through and copy everything to a new location, so somehow I need to synchronize the version from the network onto the new location on the NAS, but most syncronization software is not file specific but path specific. Any thoughts on how to accomplish detecting any changed file since the file-moving process started, and then copy it to the new NAS in the new location?

I have considered an approach where the new folders are made on the NAS but the files are not copied, instead they are scripted to copy to the new location, then people keep working on the files and after I have mapped where each file needs to move to in the script, I click "go" and that evening everything copies over to the new NAS and the next day everyone starts working off the NAS versions and not the network versions. However, I am not aware of a user-friendly file management tool that will let me set up this file-move-mapping over time and then do the move in bulk when ready, any suggestions there are welcome. With that approach I could then do the duplicate file check the day after the move to catch any files that do not have duplicates, as they might have been created without me knowing while I was doing the file-move-mapping. Don't know if this is all possible though.

1

Your script solution is the same route I would probably go. You should probably have a small time frame when you have exclusive control over both NASes, but with some clever tricks you can keep that downtime very short.

  • rsync (linux) / robocopy (windows) everything to your new NAS
    • Check the flags for these programs; they both have options to only copy changed files.
  • Write a script that moves all your folders around how you like. By only using move, you can be sure you haven't skipped copying any files. Move is also an almost instantaneous operation which should limit the time you need to have exclusive control of the NAS.
  • Test the script, make sure it does what you want
  • Delete everything on new NAS / clean your state.
  • Run rsync once to copy over most of the files.
  • Make the NAS inaccessible to users / take it offline
  • Run rsync again to copy any changes made while you were rsycing the first time (should be very fast)
  • Run your script to reorganize the files
  • Make the new NAS accessible. Decommission the old NAS or make it read only.

You should be keep your downtime under 15 min if you are nimble and have all your ducks in a row.

  • Any suggestions on a user-friendly (ie. non-programmer) scripting tool to define all the file moves from folder to folder after the copy? I have used TotalCommander before but not sure if you can set it up like that and then hit "go". The tricky bit is that the files at Source will be in a different place on the Destination, and Source has to stay the same for legacy/safety issues of current workflows, so I can't shuffle files around on Source before the copy to the new NAS, and if I copy them and then move them around it is hard to sync the files as they will not match directories. – user25644 Sep 13 at 23:17
  • The easiest way is to use a shell script. Open notepad, save a text file as something.cmd. On each line put move d:/path/to/folder d:/new/path/to/folder. I don't see how a gui tool can make this easier. You're just enumerating a list of old-new path pairs. Wrt preserving the source, perhaps I was unclear but I meant you should run the script on the new NAS after copying all the files over. You never need to move or delete anything on the source. – Andy Sep 13 at 23:40
  • I'll have thousands of lines in the notepad doc then, and after they're all defined how does the script run from notepad? I was hoping for a GUI interface where I could navigate the existing folders and create placeholder destinations and drag files from one to the other without actually doing the move at that time. It's going to be a very long and case-by-case process for each file/folder as the source has not been maintained for years so it's a dog's breakfast of disorganization. – user25644 Sep 13 at 23:59
  • Its a .cmd script. You just double click it and it automatically launches in command prompt. I do not know of a tool that records file movement to replay it later. You can follow along in notepad. Every time you drag a file or folder, add the command so it will be done automatically when you run the script. If its really critical that you have as little downtime as possible, then you have to record your move commands. Otherwise you can just make the NAS read only for one or two days while you move things around. – Andy Sep 14 at 0:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.