LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 03-02-2014, 10:44 AM   #1
Quads
Member
 
Registered: Jul 2008
Location: Indiana
Distribution: Fedora, Ubuntu, Slackware
Posts: 203

Rep: Reputation: 34
Moving large amount of data to another drive


Maybe I am overthinking this but I am curious as to the best way to move a large amount of data to another drive. I am adding a drive to a file server and need to move about 500gb worth of data. I searched around a bit and didn't find anything relevant so perhaps it is as simple as it seems.

If I were moving files on the same filesystem, obviously I would just use mv. I don't know how long it will take to move this much data between drives but I assume it would be a while and the system is at the mercy of the power grid, and I don't know if using mv would be safe in the case of power interruption. Does it copy the entire group of files and then delete them, or does it delete them as it goes? I guess the question is mv the same as a manual cp then rm? I am not cloning the entire drive, just moving some of it. What is the standard way of doing this in a professional environment where data loss is unacceptable?
 
Old 03-02-2014, 11:06 AM   #2
millgates
Member
 
Registered: Feb 2009
Location: 192.168.x.x
Distribution: Slackware
Posts: 840

Rep: Reputation: 380Reputation: 380Reputation: 380Reputation: 380
I would probably consider using rsync.
 
2 members found this post helpful.
Old 03-02-2014, 03:48 PM   #3
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 15,050

Rep: Reputation: 1915Reputation: 1915Reputation: 1915Reputation: 1915Reputation: 1915Reputation: 1915Reputation: 1915Reputation: 1915Reputation: 1915Reputation: 1915Reputation: 1915
To answer the underlying question, don't use mv. cp or rsync give you a "free" backup you can delete at your leisure.
You can never have too many backups when moving (important) stuff around ...
 
1 members found this post helpful.
Old 03-02-2014, 08:30 PM   #4
273
LQ Addict
 
Registered: Dec 2011
Location: UK
Distribution: Debian Sid AMD64, Raspbian Wheezy, various VMs
Posts: 6,313

Rep: Reputation: 1724Reputation: 1724Reputation: 1724Reputation: 1724Reputation: 1724Reputation: 1724Reputation: 1724Reputation: 1724Reputation: 1724Reputation: 1724Reputation: 1724
Regardless of the OS in use, as stated above, always copy then verify then, when you are sure the data is copied in full, delete the original.
 
1 members found this post helpful.
Old 03-03-2014, 07:23 PM   #5
byau
Member
 
Registered: Sep 2009
Location: Los Angeles, CA
Posts: 32

Rep: Reputation: 5
I would NFS mount, use tar or rsync to COPY (not move). Run an md5hash on each file and compare to make sure all copies are pristine before you delete from the original server.

tar is preferred over cp because it is better at preserving symbolic links and other file attributes. I think cp did not preserve symbolic links. I don't recall how well rsync's preservation works. Probably fine, but I remember the tar arguments better
 
1 members found this post helpful.
Old 03-04-2014, 03:45 PM   #6
jefro
Moderator
 
Registered: Mar 2008
Posts: 15,684

Rep: Reputation: 2261Reputation: 2261Reputation: 2261Reputation: 2261Reputation: 2261Reputation: 2261Reputation: 2261Reputation: 2261Reputation: 2261Reputation: 2261Reputation: 2261
byau and 273 brings up a good point about holding data until verified. Rsync or some version is a great way to consider.
If this is a live state copy then you may need to stop access to the drive and then copy it. There are only a few ways to copy live state data and keep it all concurrent.

We assume you have a local disk to disk transfer.
 
1 members found this post helpful.
Old 03-04-2014, 03:59 PM   #7
Quads
Member
 
Registered: Jul 2008
Location: Indiana
Distribution: Fedora, Ubuntu, Slackware
Posts: 203

Original Poster
Rep: Reputation: 34
Quote:
Originally Posted by jefro View Post
byau and 273 brings up a good point about holding data until verified. Rsync or some version is a great way to consider.
If this is a live state copy then you may need to stop access to the drive and then copy it. There are only a few ways to copy live state data and keep it all concurrent.

We assume you have a local disk to disk transfer.
Yes, local disk to disk transfer. rsync seems to be the best way to go. Thanks everyone.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Best interprocess communication method for transferring large amount of data? mntgoat Linux - Software 1 05-07-2009 07:58 AM
howto copy & backup LARGE amount of data edenCC Linux - Server 5 12-16-2007 10:02 AM
generate large amount of traffic data Mr_C Linux - Networking 3 03-10-2006 12:38 AM
HP laserjet 6p stalls with large amount of data simjii Mandriva 0 11-10-2005 04:32 PM
moving hard drive with existing data to FC3 supra92 Linux - General 6 12-28-2004 04:09 PM


All times are GMT -5. The time now is 10:19 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration