I've spent a long time searching the archives and
can't find a solution to my problem- apologies if I've
missed it.
I've been running rsync absolutely fine for a couple
of months on Win2K server using Win2K & WinXP clients
with a 'regular' service installation using cygrunsrv
(below). It works excellently except that all the
files transferred by rsync have the ownership set to
SYSTEM. This is the problem.
The command I use to install the service is:
cygrunsrv -I "rsync" -p
/cygdrive/c/cygwin/bin/rsync.exe -a
"--config=/cygdrive/c/cygwin/etc/rsyncd.conf --daemon
--no-detach" -f "rsync"
Like I said, this works fine apart from the
permissions issue with all files being owned by the
SYSTEM account. If I go into Services properties for
the rsync service and set the 'Log On as:' option to
'This account' and use Administrator then I get an
error on starting the service:
"Could not start the rsync service on Local Computer.
Error 1067: The process terminated unexpectedly."
I get the same problem if I use the -u and -w options
with cygrunsrv.exe to install the rsync service with
specific user rights.
While logged in as Administrator on the server, I can
run rsync from a command window using the command:
rsync --config=/cygdrive/c/cygwin/etc/rsyncd.conf
--daemon --no-detach
and this runs OK- files transferred from client have
the permissions I want- the same permissions as most
of the other files on the box (owner: administrator,
full permission: Everyone).
So I think that the Administrator account in some way
has less privileges than the SERVICE account but I
just can't work out what the crucial differences
relating to running as a service are.
How can I get the rsync service to run under a
different account from SERVICE?
Thanks a lot for any help- I have spent a lot of time
on this already.
Joel.
System Details:
---------------
win2k server sp4, file system=NTFS
latest cygwin, running rsync 2.6.3, cygrunsrv V1.0,
Apr 18 2004
(I am not running the cwrsync package)
- environment variable CYGWIN=nontsec
- Administrator has Log on as a Service privileges in
Local Security Settings
- system Path includes c:\cygwin\bin
rsyncd.conf:
------------
use chroot = false
strict modes = false
log file = rsyncd.log
pid file = rsyncd.pid
hosts allow = *
[build]
path = /cygdrive/c/estore
read only = false
transfer logging = yes
[test]
path = /cygdrive/c/temp
read only = false
transfer logging = yes
__________________________________
Do you Yahoo!?
Send a seasonal email greeting and help others. Do good.
http://celebrity.mail.yahoo.com