[Serdev] CVS:commitlog: sip_router/modules/domain domain.c
Vaclav Kubart
vaclav.kubart at iptel.org
Fri Jan 26 11:06:55 UTC 2007
Hi,
this problem can be related to improper process initialization. We
solved some time ago problem like this - database connection is
initialized in child_init, but CTL module (responsible for handling
binrpc) created a new process which didn't call child_init (or called
with a rank for which was not created DB connection, I don't remember
exactly), so the DB connection was not initialized for "binrpc" process
and thus DB operations called via binrpc failed.
Vaclav
On Fri, Jan 26, 2007 at 11:33:14AM +0100, Hendrik Scholz wrote:
> Hi!
>
> There is another issue inside the domain module.
> Inside mod_init() the database connection is established but even if
> everything is loaded successfully the connection is torn down before
> regular operation.
> As a result the RPC domain.reload will fail.
> Two solutions:
>
> 1) remove disconnect_db() from mod_init()
> 2) call connect_db() whenever needed, i.e. in reload_domains() from RPC
>
> I'm no friend of persistent but unused MySQL connections which
> might introduce issues later down the road (closed remotely by MySQL
> et al). I'd go for the connection re-establishments upon need and
> teardown afterwards.
>
> Any comments?
>
> Cheers,
> Hendrik
>
> --
> freenet Cityline GmbH, Hamburger Chaussee 2-4, 24114 Kiel, Germany
> Phone: +49 (0)431 9020552, Fax: +49 (0)431 9020559
> Internet: http://www.freenet.de, eMail: hendrik.scholz at freenet-ag.de
> _______________________________________________
> Serdev mailing list
> Serdev at lists.iptel.org
> http://lists.iptel.org/mailman/listinfo/serdev
More information about the Serdev
mailing list