LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
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, 09: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, 10:06 AM   #2
millgates
Member
 
Registered: Feb 2009
Location: 192.168.x.x
Distribution: Slackware
Posts: 852

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

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
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, 07:30 PM   #4
273
LQ Addict
 
Registered: Dec 2011
Location: UK
Distribution: Debian Sid AMD64, Raspbian Wheezy, various VMs
Posts: 7,680

Rep: Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373Reputation: 2373
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, 06:23 PM   #5
byau
Member
 
Registered: Sep 2009
Location: Los Angeles, CA
Posts: 33

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, 02:45 PM   #6
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,980

Rep: Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624Reputation: 3624
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, 02: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



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
HP laserjet 6p stalls with large amount of data simjii Mandriva 2 04-10-2020 08:52 PM
Best interprocess communication method for transferring large amount of data? mntgoat Linux - Software 1 05-07-2009 06:58 AM
howto copy & backup LARGE amount of data edenCC Linux - Server 5 12-16-2007 09:02 AM
generate large amount of traffic data Mr_C Linux - Networking 3 03-09-2006 11:38 PM
moving hard drive with existing data to FC3 supra92 Linux - General 6 12-28-2004 03:09 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:04 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
Open Source Consulting | Domain Registration