rsync recursion question

tim.conway at tim.conway at
Wed Oct 24 22:42:04 EST 2001

Now, that's a good solution.  if it MUST be done over rsync, and it's not there, write it in yourself.  It's amazing, sometimes, the things people want added into a generic tool, and they expect Tridge or Dave to write and maintain it.  It's a tool for
non-interactively maintaining directory trees, and adding in an option to do a "rsh remotehost rm" wouldn't be a normal function.  Your situation is different.  Almost nobody writes to rsyncd, especially not huge trees.  Glad to see it's working well for

Tim Conway
tim.conway at
Philips Semiconductor - Longmont TC
1880 Industrial Circle, Suite D
Longmont, CO 80501
Available via SameTime Connect within Philips
Available as n9hmg on AIM
perl -e 'print pack(nnnnnnnnnnnn, 19061,29556,8289,28271,29800,25970,8304,25970,27680,26721,25451,25970), ".\n" '
"There are some who call me.... Tim?"

                    Justin Banks                                                                                                                  
                    <justinb at tricord.           To:  Tim Conway/LMT/SC/PHILIPS at AMEC                                                               
                    com>                        cc:  justinb at                                                                          
                    Sent by:                     rsync at                                                                            
                    rsync-admin at lists            rsync-admin at                                                                      
                            Subject:  Re: rsync recursion question                                                            
                    10/23/2001 08:08                                                                                                              
                    Please respond to                                                                                                             

>>>>> "Tim" == tim conway <tim.conway at> writes:

  Tim> That's the way it is.  If it's really a one-off change, a huge change
  Tim> in your structure, telnet ssh, rsh, and so forth, work really well for
  Tim> dropping in and deleting stuff (unless you're supplying the master, and
  Tim> other systems out of your control copy from you).  Rsync is opTimized
  Tim> for taking a filesystem in an unknown state, and making it identical to
  Tim> another filesystem in an unknown state, using network bandwidth as
  Tim> efficiently as possible.

Well, that doesn't cut it here. It seemed like all the guts were there - I
mean, the functionality already exists on the receiving side, mostly, right?
Anyway, I took a look, and I added an option (-d). This means that you can do

rsync --delete -d /some/removed/directory foo at wherever::module:/some/removed

and the remote side will remove /some/removed/directory. It will work whether
it's a file or directory. Let me know if anyone wants a patch, if this is a
feature that would help other folks. I can't imagine people are in my
particular circumstances, where the source filesystem is on the order of a
terabyte, but you never know ;)


Justin Banks Tricord, Inc. justinb at
'We have no intention of shipping another bloated operating system and
forcing that down the throats of our Windows customers'
  -- Paul Maritz, Microsoft Group Vice President

More information about the rsync mailing list