1 |
Mick <michaelkintzios@×××××.com> [14-05-17 09:48]: |
2 |
> On Saturday 17 May 2014 04:33:57 meino.cramer@×××.de wrote: |
3 |
> > Hi, |
4 |
> > |
5 |
> > is there any tool in the Gentoo portage which may speed up (make it |
6 |
> > mopre efficient) the following task: |
7 |
> > |
8 |
> > On my HD there are data I want to copy to two identical external HDs. |
9 |
> > These HDs are of the same type/model and each is separately |
10 |
> > connectable via USB to my PC (...these two of the typical mobile external |
11 |
> > USB-HDs). |
12 |
> > |
13 |
> > Instead of copying the data twice from my PC to eah of the HDs I want |
14 |
> > to do it once...like I would be able to give the cp-command two |
15 |
> > instead of one target where to copy two. |
16 |
> > |
17 |
> > The result should be two identically populated external HDs, each of |
18 |
> > them useable/readable without the need to the other one. |
19 |
> > |
20 |
> > What tool of the portage tree I able to accomplish this task? |
21 |
> > |
22 |
> > Best regards, |
23 |
> > mcc |
24 |
> |
25 |
> |
26 |
> 1. You could set up the two ext drives as a mirrored RAID and use your |
27 |
> copying/tar-ing/dd tool of choice. |
28 |
> |
29 |
> |
30 |
> 2. Or you could use pipe and tee to split the feed into any devices you want, |
31 |
> e.g.: |
32 |
> |
33 |
> pv /dev/sda1 | tee >(dd of=/dev/sdb1) >(dd of=/dev/sdc1) |
34 |
> |
35 |
> |
36 |
> 3. Or you could use a sequential copy: |
37 |
> |
38 |
> cp -a /home /dev/sdb1/ && cp -a /home /dev/sdc1 |
39 |
> |
40 |
> |
41 |
> NOTES: |
42 |
> |
43 |
> a) Unlike other commands, pv will give you a progress bar so that you know how |
44 |
> long your back up is taking. |
45 |
> |
46 |
> b) The 3rd example above will copy sequentially, but depending on the size of |
47 |
> the file(s) the second copy may be read from cache. |
48 |
> |
49 |
> c) If you're doing this over the network then you can use nc in listening mode |
50 |
> at the receiving end, or ssh if the network is untrusted. |
51 |
> |
52 |
> |
53 |
> I'm interested to see what other ways will be suggested for this task. |
54 |
> |
55 |
> -- |
56 |
> Regards, |
57 |
> Mick |
58 |
|
59 |
Hi Mick, |
60 |
|
61 |
thank your reply! :) |
62 |
|
63 |
From your numbering of the possibilities... |
64 |
1.) ...I am no RAID guru and would try this later with data, which |
65 |
are not valuable... |
66 |
2.) That looks interesting! Unfortunately it seems to copy device |
67 |
contents on low level instead of files. The source are directory |
68 |
structure -- not whole devices... |
69 |
Or did I overlook an option mentioned in the manpage...? |
70 |
3.) The files I want to copy are in the size of some GB each. So the |
71 |
cache isnt big enough to hold ALL files for the second part. |
72 |
|
73 |
|
74 |
Best regards, |
75 |
mcc |