The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My work

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 1,822 other followers

Archive for March 1st, 2016

rsync as diff – compare files in two directory on remote server using unix – Stack Overflow

Posted by jpluimers on 2016/03/01

Too bad the accepted answer forgets about deleted files.

Use one of these to compare (but not sync) two directory trees.

For size-only comparision:

rsync -n -avr --size-only --delete /abc/home/sample1/ server2:/abc/home/sample2/

If you want to compare both contents and size:

rsync -n -avrc --delete /abc/home/sample1/ server2:/abc/home/sample2/

–jeroen

via: diff – compare files in two directory on remote server using unix – Stack Overflow.

Posted in *nix, bash, Development, Power User, rsync, Scripting, Software Development | Leave a Comment »

 
%d bloggers like this: