This is a cool idea. I'll give it a try and see if I can make it work for me. One thing missing is the switches for "replace mode" you mentioned. I'll comb through the manpage of course...<div><br></div><div>
Thanks,</div><div><br></div><div>-Clint<br><br><div class="gmail_quote">On Fri, Jul 27, 2012 at 1:16 PM, Greg Deback (rsync) <span dir="ltr"><<a href="mailto:greg.deb+rsync@gmail.com" target="_blank">greg.deb+rsync@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">If you really want to have a destination tree that looks like :<div> current -> 2012-07-22</div><div> 2012-07-22/</div>
<div> 2012-07-21/</div><div><br>with the current symlink pointing to the latest backup, you can manage to do it in two passes :</div>

<div>1. Create an empty directory '2012-07-22/' and the 'current' symlink pointing to it (relative path), and rsync it to the final destination in "replace" mode (ie. update, no deletion) with symlink on (-l). This will replace the existing 'current' symlink in the destination folder.</div>


<div>2. Rsync (-Ha or -Haz) your src folder to 'current/' or to '2012-07-22/' (leave the trailing slash)</div><span class="HOEnZb"><font color="#888888"><div>Greg</div></font></span><div class="HOEnZb"><div class="h5">
<div><br><div class="gmail_quote">On Fri, Jul 27, 2012 at 10:06 PM, Clint Olsen <span dir="ltr"><<a href="mailto:clint.olsen@gmail.com" target="_blank">clint.olsen@gmail.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Ok, that is helpful. As you can guess based on my question, it would be nice if all the automation can be done on the client side rather than having some specialized scripting on the receiving side to manage directories and symlinks etc.<div>



<br></div><div>Thanks,</div><div><br></div><div>-Clint<div><div><br><br><div class="gmail_quote">On Fri, Jul 27, 2012 at 12:55 PM, Greg Deback (rsync) <span dir="ltr"><<a href="mailto:greg.deb+rsync@gmail.com" target="_blank">greg.deb+rsync@gmail.com</a>></span> wrote:<br>



<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<div><br></div><div>As for the destination directory and the backup directory (--backup-dir), rsync will create the missing subdirectory (one level below the existing dir only), so yes for /<somedir-exists>/<newdir-with-date>, no for /<somedir-exists>/<newdir-with-year>/<newdir-with-month> on january 1st... But if you want this dir to be a symlink, you can't.</div>





<div><br></div><div>Greg<br><br><div class="gmail_quote"><div><div>On Fri, Jul 27, 2012 at 7:16 PM, Clint Olsen <span dir="ltr"><<a href="mailto:clint.olsen@gmail.com" target="_blank">clint.olsen@gmail.com</a>></span> wrote:<br>





</div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div>I've been very interested in these discussions and uses of rsync as a "clone" of Time Machine. A couple of things have been keeping me from a fully automated solution. I'd like to eliminate the need for Samba/NFS mounts of any kind, because they have proven to be unreliable for me and under some operating environments (Cygwin) it breaks --link-dest. In most of the articles I've read, a target "date" directory is created with some sort of "latest" symlink for the --link-dest parameter. I can accomplish those tasks via remote ssh commands, but I was hoping there was a better way. For example, is there any circumstance where you can coax rsync into creating a target directory that's not there already?<div>






<br></div><div>% rsync <source> user@nas::module/<somedir-exists>/<newdir-with-date></div><div><br></div><div>So, newdir-with-date doesn't exist (yet). I would like to have rsync create it for me. Is that even possible?</div>






<div><br></div><div>Thanks,</div><div><br></div><div>-Clint</div>
<br></div></div><span><font color="#888888">--<br>
Please use reply-all for most replies to avoid omitting the mailing list.<br>
To unsubscribe or change options: <a href="https://lists.samba.org/mailman/listinfo/rsync" target="_blank">https://lists.samba.org/mailman/listinfo/rsync</a><br>
Before posting, read: <a href="http://www.catb.org/~esr/faqs/smart-questions.html" target="_blank">http://www.catb.org/~esr/faqs/smart-questions.html</a><br></font></span></blockquote></div><br></div>
</blockquote></div><br></div></div></div>
</blockquote></div><br></div>
</div></div></blockquote></div><br></div>