On 22.05.2015 07:22, Martin Kletzander wrote:
On Thu, May 21, 2015 at 05:46:54PM +0200, Michal Privoznik wrote:
> On 20.05.2015 07:19, Martin Kletzander wrote:
>> For this to pe properly separated from other protocols used by the
>> server, there is second server added which allows access to the whole
>> virNetDaemon to its clients.
>>
>> Signed-off-by: Martin Kletzander <mkletzan(a)redhat.com>
>> ---
>> cfg.mk | 3 ++
>> daemon/Makefile.am | 34 ++++++++++++++-
>> daemon/admin_server.c | 116
>> ++++++++++++++++++++++++++++++++++++++++++++++++++
>> daemon/admin_server.h | 36 ++++++++++++++++
>> daemon/libvirtd.c | 104
>> +++++++++++++++++++++++++++++++++++++++-----
>> daemon/libvirtd.h | 14 +++++-
>> po/POTFILES.in | 1 +
>> 7 files changed, 295 insertions(+), 13 deletions(-)
>> create mode 100644 daemon/admin_server.c
>> create mode 100644 daemon/admin_server.h
>>
>
>> + !!config->keepalive_required,
>> + NULL,
>> + remoteAdmClientInitHook,
>> + NULL,
>> + remoteAdmClientFreeFunc,
>> + dmn))) {
>> + ret = VIR_DAEMON_ERR_INIT;
>> + goto cleanup;
>> + }
>> +
>> + if (virNetDaemonAddServer(dmn, srvAdm) < 0) {
>> + ret = VIR_DAEMON_ERR_INIT;
>> + goto cleanup;
>> + }
>
> This is what I was talking about in reply to 02/13. Imagine the limits
> for domain worker pool and sockets were set really low on daemon
> startup. No new client can be accepted there. I would expect mgmt
> application to connect to admin API and size up the limits. However, due
> to bug in 2/13 all servers are suspended. I'll leave it up to you where
> you'd like to solve it.
>
There's nothing to solve. The client is being added in a particular
server and that server will call virNetServerUpdateServicesLocked()
only on itself, not virNetDaemonUpdateServices() on the daemon.
Oh, right. I recalled adding updateServices function somewhere so that
server stops accepting new clients when a certain limit is reached. I
forgot it was updateServicesLocked() which you don't touch. Disregard my
comments to this then.
Michal