Delete directories without browsing them

Matthias Schniedermeyer ms at citd.de
Sat Apr 6 09:15:18 MDT 2013


On 06.04.2013 16:57, AZ 9901 wrote:
> 
> Is there a way to tell Rsync to directly delete backup directories at
> the top of the hierarchy without browsing them ?

No.

Deleting a directory-tree has to be done "file by file" and "directory 
by directory" there is no magic "remove that mountain of files"(*).




*:
Altough Snapshots can work like that.
Use something that supports snapshots, put a day into a snapshot and 
then you can remove the whole snapshot. Depending on the circumstances 
(what as to happend to do the work) it may or may not be faster than 
removing a directory tree "file by file" but at least the work is done
"invisibly" by whatever is doing the snapshoting.



-- 
Matthias


More information about the rsync mailing list