1 |
On 7/28/05, Sean Higgins <sean@×××××××.com> wrote: |
2 |
> > > tar cvf - * | tar xf -C ../new/ |
3 |
> > |
4 |
> > * doesn't match hidden files, so the copy will be incomplete. |
5 |
> |
6 |
> Neil, |
7 |
> |
8 |
> Interesting. I had not thought about that. I did use the above to recreate |
9 |
> my hard drive from one hard drive to another one. It worked well, I guess I |
10 |
> lucked out that I did not have any hidden files in the "old" directory. |
11 |
|
12 |
A better option is to use . (dot) a the directory. Also adding -p to |
13 |
preserve permissions is essential when backing up a whole system: |
14 |
|
15 |
tar cfp - . | (cd /target/path && tar xvfp -) |
16 |
|
17 |
Regards, |
18 |
Andreas |
19 |
|
20 |
-- |
21 |
And I hate redundancy, and having different functions for the same thing. |
22 |
- Linus Torvalds on linux-kernel |
23 |
|
24 |
-- |
25 |
gentoo-user@g.o mailing list |