rsync cannot create directory
I am having a very strange problem with my rsync server setup. When running the rsync daemon from the command line, it works as excepted. I can transfer files without problems. However, when invoking the daemon from launch (launchctl load /Library/LaunchDaemons/org.samba.rsync.plist), no directories can be created. Evidently is a permissions problem which I cannot find where and how.
From the command line (as root) [no problems]:
/usr/local/bin/rsync --daemon --no-detach --config=/usr/local/etc/rsyncd.conf
When using launch, the following error is generated
2020/09/16 10:34:14 [54618] recv_file_list done
2020/09/16 10:34:14 [54618] generator starting pid=54618
2020/09/16 10:34:14 [54618] delta-transmission enabled
2020/09/16 10:34:14 [54618] recv_generator(Library,0)
2020/09/16 10:34:14 [54618] rsync: [generator] recv_generator: mkdir "Library" (in Backup) failed: Operation not permitted (1)
2020/09/16 10:34:14 [54618] *** Skipping any contents from this failed directory ***
My /Library/LaunchDaemons/org.samba.rsync.plist looks like this:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Disabled</key>
<false/>
<key>Label</key>
<string>org.samba.rsync</string>
<key>Program</key>
<string>/usr/local/bin/rsync</string>
<key>ProgramArguments</key>
<array>
<string>/usr/local/bin/rsync</string>
<string>--daemon</string>
<string>--no-detach</string>
<string>--verbose</string>
<string>--config=/usr/local/etc/rsyncd.conf</string>
</array>
<key>RunAtLoad</key>
<true/>
<key>KeepAlive</key>
<dict>
<key>SuccessfulExit</key>
<false/>
</dict>
</dict>
</plist>
My /usr/local/etc/rsyncd.conf:
hosts allow = 192.168.0.0/16
reverse lookup = false
list = yes
uid = nobody
gid = nobody
log file = /var/log/rsync.log
motd file = /usr/local/etc/rsyncd.motd
[Backup]
path = /Volumes/BackupVolume/BACKUPS/
comment = Backup area
read only = false
write only = false
use chroot = false
# max verbosity = 100
uid = nobody
gid = nobody