Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 110000 - remaining rsync child process after kill with rsync-2.6.0-r5
Summary: remaining rsync child process after kill with rsync-2.6.0-r5
Status: RESOLVED UPSTREAM
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High minor (vote)
Assignee: Gentoo's Team for Core System packages
URL: https://bugzilla.samba.org/show_bug.c...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-10-21 01:58 UTC by b52
Modified: 2006-02-20 16:32 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description b52 2005-10-21 01:58:43 UTC
Hi,

I discovered that rsync-2.6.0-r5 keeps a remaining process after you kill rsync
on remote end. E.g.:

1. Start rsync --daemon on server (with timeout set)
2. Start rsync on client (with timeout set)
3. While exchanging a file you get three instances of rsync on the server like
   root      5047  0.0  0.2   1856   672 ?        Ss   10:26   0:00 rsync --daemon
   root      5262  5.8  0.3   1860   980 ?        S    10:31   0:09  \_ rsync
--daemon
   root      5272  0.0  0.4   1996  1076 ?        S    10:31   0:00      \_
rsync --daemon
4. Kill rsync on client while exchanging a file with kill or Ctrl-C
5. Child of rsync remains on server which will not be killed by timeout, so forever
   root      5047  0.0  0.2   1856   672 ?        Ss   10:26   0:00 rsync --daemon
   root      5262  5.6  0.3   1860   980 ?        S    10:31   0:09  \_ rsync
--daemon

The problem is that after doing this sometime you will anytime reach your max
connections and not be able to sync anymore until you kill this processes by hand.

Reproducible: Always
Steps to Reproduce:
1. see Details
2.
3.

Actual Results:  
remaining child process

Expected Results:  
only one instance of rsync

rsync-2.6.0-r5 on both ends
Comment 1 euclid80 2005-11-23 08:12:40 UTC
I've been poking around in the rsync source, so I thought I'd try to fix this
bug, but I can't seem to reproduce it.  I get only two processes during the file
transfer (not 3), and the server process dies with the client.  I am using the
standard config provided with Gentoo (copied below); perhaps your config is
different.

--- 8< --------

# This line is required by the /etc/init.d/rsyncd script
pid file = /var/run/rsyncd.pid
use chroot = yes
read only = yes
timeout = 20

# Simple example for enabling your own local rsync server
[gentoo-portage]
	path = /usr/portage
	comment = Gentoo Linux Portage tree
Comment 2 euclid80 2005-11-23 14:01:56 UTC
(In reply to comment #1)
> I've been poking around in the rsync source, so I thought I'd try to fix this
> bug, but I can't seem to reproduce it.

Never mind.  I see that the client has to be uploading.  I guess I can reproduce
it after all.
Comment 3 euclid80 2005-11-23 21:11:25 UTC
I have discovered a workaround.  Add "#define SHUTDOWN_ALL_SOCKETS" to config.h.

For more information, refer to the upstream bugzilla:
https://bugzilla.samba.org/show_bug.cgi?id=3271
Comment 4 SpanKY gentoo-dev 2006-02-20 16:32:58 UTC
thanks for filing that