dikkiedirk Posted October 2, 2014 Share Posted October 2, 2014 I have an empty XFS formatted disk in my array. I like to transfer all contents from another disk to this disk then format it to XFS and repeat this until all disks in the array are changed to XFS. What ist the best and safest and fastest way? Should I do it in a screen session in Putty? Or in the IPMI console? Should I copy or move or use rsync? Is there a command that will copy all files and folders at once? Can this be done in Midnight Commander? Is this Set and Forget? Will the copying continue when I close Putty or the IPMI console? 1 Quote Link to comment
jphipps Posted October 2, 2014 Share Posted October 2, 2014 I have migrated all the disks in my 2 servers to XFS using the following command from a putty/shell: rsync -av --progress --remove-source-files /mnt/diskX/ /mnt/diskY/ This will migrate the data, and remove the source files once each is successfully copied. I like this method, because if it gets killed, you can easily restart and it picks up where it left off. After the first run completes, I run it a few more time to catch any files that were created during the copy. The target file is a hidden ".file" during the copy so from the share point of view there is only a single copy of the file existing during the copy. After the copy, the source file is deleted and the target is renamed so the switch is barely noticeable to the user. You can skip the remove option if you don't the overhead of the delete, but then you also have dups on the share until you are completed. 1 Quote Link to comment
dikkiedirk Posted October 2, 2014 Author Share Posted October 2, 2014 Thanks. You don't use screen or nohup so the command will keep on running whem putty is closed? Or is that a bad idea? Quote Link to comment
eroz Posted October 2, 2014 Share Posted October 2, 2014 Thanks. You don't use screen or nohup so the command will keep on running whem putty is closed? Or is that a bad idea? I did the same thing this past week. I was transferring overnight with screen. Then the next day stop the array, reformat the drive and run rsync on screen overnight again. Quote Link to comment
jphipps Posted October 2, 2014 Share Posted October 2, 2014 I do use screen sometimes. I am on my workstation so much of the time, i just use an ssh sessions normally. Probably with screen, is you can't easily scroll back, so unless you are logging to a file, it is hard to see the history. Plus since you can restart with rsync so easily, it is not a big deal if it drops... Quote Link to comment
krazijoe Posted December 1, 2014 Share Posted December 1, 2014 Is there a way to move select folders, like all folders A through J? Quote Link to comment
dstroot Posted March 22, 2015 Share Posted March 22, 2015 To improve the copy speed, add -W (--whole-file), to avoid calculating deltas/diffs of the files. This is the default when both the source and destination are specified as local paths, since the real benefit of rsync's delta-transfer algorithm is reducing network usage. 1 Quote Link to comment
guruleenyc Posted April 11, 2017 Share Posted April 11, 2017 On 10/2/2014 at 7:26 AM, jphipps said: I have migrated all the disks in my 2 servers to XFS using the following command from a putty/shell: rsync -av --progress --remove-source-files /mnt/diskX/ /mnt/diskY/ This will migrate the data, and remove the source files once each is successfully copied. I like this method, because if it gets killed, you can easily restart and it picks up where it left off. After the first run completes, I run it a few more time to catch any files that were created during the copy. The target file is a hidden ".file" during the copy so from the share point of view there is only a single copy of the file existing during the copy. After the copy, the source file is deleted and the target is renamed so the switch is barely noticeable to the user. You can skip the remove option if you don't the overhead of the delete, but then you also have dups on the share until you are completed. Thank you very much! Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.