Rsync For Mac Os X



Mac

  1. Rsync For Mac
  2. Rsync For Mac Os X

Rsync For Mac

install-rsync-macosx.sh
Wget for mac os x

Rsync For Mac Os X

I am quite unsure with all options of rsync. Here my backup configuration: I am on Mac X (10.8) and want an exact copy of my HD to an external HD. I formatted the new USB drive with Mac OS extended (Journaled, Encrypted) and made in my shell the following command and got the following errors. Mac OS X uses the HFS+ filesystem, by default. HFS+ files are often composed of a data fork, a resource fork, and Finder metadata. The data and resource forks contain what you normally think of when you think of file information: data, program code, etc. Finder metadata includes information like file type and creator, comments, modification. Requires at least Mac OS X 10.4 or suitably patched rsync. I ran a new test, moved a Interarchy bookmark to my desktop, I know for a fact these break if they are copied sans resource forks. Running without the -E versus with the -E, there is a difference of 152 bytes in xfered data.

#Compile rsync 3.0.7
#Follow these instructions in Terminal on both the client and server to download and compile rsync 3.0.7:
#Download and unarchive rsync and its patches
cd~/Desktop
curl -O http://rsync.samba.org/ftp/rsync/src/rsync-3.0.7.tar.gz
tar -xzvf rsync-3.0.7.tar.gz
rm rsync-3.0.7.tar.gz
curl -O http://rsync.samba.org/ftp/rsync/src/rsync-patches-3.0.7.tar.gz
tar -xzvf rsync-patches-3.0.7.tar.gz
rm rsync-patches-3.0.7.tar.gz
cd rsync-3.0.7
#Apply patches relevant to preserving Mac OS X metadata
patch -p1 <patches/fileflags.diff
patch -p1 <patches/crtimes.diff
patch -p1 <patches/hfs-compression.diff
#Configure, make, install
./prepare-source
./configure
make
sudo make install
#Verify your installation
/usr/local/bin/rsync --version
#By default, rsync will be installed in /usr/local/bin.
#If that isn't in your path, you will need to call your new version of rsync by its absolute path (/usr/local/bin/rsync).

commented Aug 2, 2019

when I execute make, this is the result:
gcc -I. -I. -g -O2 -DHAVE_CONFIG_H -Wall -W -I./popt -Wno-unused-parameter -c generator.c -o generator.o
generator.c:173:34: error: too many arguments to function call, expected 2, have 3
do_chmod(fbuf, mode | S_IWUSR, NO_FFLAGS);
~~~~~~~~ ^~~~~~~~~
./rsync.h:493:19: note: expanded from macro 'NO_FFLAGS'
#define NO_FFLAGS ((uint32)-1)
^~~~~~~~~~~~
./proto.h:305:1: note: 'do_chmod' declared here
int do_chmod(const char *path, mode_t mode);
^
generator.c:313:40: error: too many arguments to function call, expected 2, have 3
do_chmod(fname, fp->mode | S_IWUSR, NO_FFLAGS);
~~~~~~~~ ^~~~~~~~~
./rsync.h:493:19: note: expanded from macro 'NO_FFLAGS'
#define NO_FFLAGS ((uint32)-1)
^~~~~~~~~~~~
./proto.h:305:1: note: 'do_chmod' declared here
int do_chmod(const char *path, mode_t mode);
^
generator.c:1541:30: error: too many arguments to function call, expected 2, have 3
if (do_chmod(fname, mode, 0) < 0) {
~~~~~~~~ ^
./proto.h:305:1: note: 'do_chmod' declared here
int do_chmod(const char *path, mode_t mode);
^
generator.c:2121:32: error: too many arguments to function call, expected 2, have 3
do_chmod(fname, file->mode, 0);
~~~~~~~~ ^
./proto.h:305:1: note: 'do_chmod' declared here
int do_chmod(const char *path, mode_t mode);
^
generator.c:2126:51: error: too many arguments to function call, expected 3, have 4
set_modtime(fname, file->modtime, file->mode, 0);
~~~~~~~~~~~ ^
./proto.h:335:1: note: 'set_modtime' declared here
int set_modtime(const char *fname, time_t modtime, mode_t mode);
^
5 errors generated.
make: *** [generator.o] Error 1

commented Aug 2, 2019

commented Apr 17, 2020

Rsync for windows download

You need to use https://rsync.samba.org/ (HTTPS instead of HTTP), else curl can't download the tars, or add the option -L

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment