l i n u x - u s e r s - g r o u p - o f - d a v i s
L U G O D
 
Next Meeting:
October 20: Web Application Hacking: How to Make and Break Security on the Web
Next Installfest:
TBD
Latest News:
Oct. 10: LUGOD Installfests coming again soon
Page last updated:
2003 Jun 19 21:27

The following is an archive of a post made to our 'vox-tech mailing list' by one of its subscribers.

Report this post as spam:

(Enter your email address)
Re: [vox-tech] Suggestions....?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [vox-tech] Suggestions....?





--On Thursday, June 19, 2003 15:22:47 -0700 Richard Crawford <rscrawford@mossroot.com> wrote:

What I need to do is replace the contents of each directory of the form
2a or 2b on Server II with the contents of the corresponding 2a
subdirectories on Server I.  The trick is that none of the contents of
the other directories can be replaced... otherwise, I'd just tar up the
contents of DIRECTORY B on Server I and untar it on SERVER II.

If it was just two or three subfolders of the form 2a and 2b on my
server, it wouldn't be an issue.  But I've got hundreds of the little
buggers, and I don't want to spend all day doing this.
You could look into rsync. You ought to be able to construct an rsync exclusion file defining the files to be ignored, though it can get tricky at times.

But really, it may be as simple as the following:

cd /path/to/dir-a
for dir in subdir-2/*/
do
echo doing $dir
tar cf - $dir | ssh server-ii 'cd /path/to/dir-a && tar xvf -'
done

then repeat for directory B.


--
Kenneth Herron Kherron@newsguy.com 916-366-7338
_______________________________________________
vox-tech mailing list
vox-tech@lists.lugod.org
http://lists.lugod.org/mailman/listinfo/vox-tech



LinkedIn
LUGOD Group on LinkedIn
Sign up for LUGOD event announcements
Your email address:
facebook
LUGOD Group on Facebook
'Like' LUGOD on Facebook:

Hosting provided by:
Sunset Systems
Sunset Systems offers preconfigured Linux systems, remote system administration and custom software development.

LUGOD: Linux Users' Group of Davis
PO Box 2082, Davis, CA 95617
Contact Us

LUGOD is a 501(c)7 non-profit organization
based in Davis, California
and serving the Sacramento area.
"Linux" is a trademark of Linus Torvalds.

Sponsored in part by:
Appahost Applications
For a significant contribution towards our projector, and a generous donation to allow us to continue meeting at the Davis Library.