caching_server: kill lingering caching_server before starting it
If a process is bound to the caching server port for whatever
reason, we need to kill it before restarting a new one.
TEST=Manually do the following test on a chameleon host.
# Remove the pid file so that chameleond would not be stopped.
1. rm /var/run/chameleond.pid
# Restart chameleond.
2. /etc/init.d/chameleond restart
Without applying this patch,
observe the following error messages in /var/log/chameleond_init
socket.error: [Errno 98] Address already in use
With this patch,
the above errors should not be seen.
Reviewed-by: Michael Sun <firstname.lastname@example.org>
Commit-Queue: Shyh-In Hwang <email@example.com>
Tested-by: Shyh-In Hwang <firstname.lastname@example.org>
1 file changed