Fixed a bug "permission denied" with "--pid-file".
Clsync uses effective pid of "nobody" by default. In turn there's no permission to create new files in /var/run on some systems under the "nobody". So this patch uses "root" to create and fchown() the file. Debug3 (pid: 19860; thread: 0x7f606105db40): main(): Trying to drop effective gid to 65533 Debug3 (pid: 19860; thread: 0x7f606105db40): main(): Trying to drop effective uid to 65534 Debug1 (pid: 19860; thread: 0x7f606105db40): main(): / [/] (0xf7eed0) -> rsync://********@**********/******* [***] (0xf7ba30) Warning (pid: 19860; thread: 0x7f606105db40): main(): Directory "/dev/shm/clsync" doesn't exist. Creating it. Debug2 (pid: 19860; thread: 0x7f606105db40): main(): Trying to open the pidfile "/var/run/clsync-backup.pid" Error (pid: 19860; thread: 0x7f606105db40): main(): Cannot open file "/var/run/clsync***.pid" to write a pid there (13: Permission denied) Debug3 (pid: 19860; thread: 0x7f606105db40): main(): Current errno is 13. Error (pid: 19860; thread: 0x7f606105db40): main(): Cannot unlink pidfile "/var/run/clsync***.pid" (2: No such file or directory)
Showing
1 changed file
with
36 additions
and
7 deletions
-
Please register or login to post a comment