I think that this is common (general) problem in modular implementation. I've revised doc/module_interface. In Section 3: "..When the server is being shut down...detach() is called for each module instance." But in my situation this does not happens. As I understand -- this must be done within radiusd.c by calling appropriate function from modules.c (module_list_free() or instance_list_free()) but radiusd.c calls only setup_modules(). Any signal handling code does not operates with modules.
May be I'm wrong or missed something? >> After 'killall -KILL radiusd' or 'rc.radiusd stop' I notice >> (in postgresql log) messages like this: >> >> pq_recvbuf: unexpected EOF on client connection >> >> It's seems that radiusd does not cleanup sql module >> properly and connections to server are not closes >> in regular way (eg. via PGfinish()). > I have the same problem. Furthermore, "pq_recvbuf: unexpected EOF on > client connection" server get for _all_ requests to my server (including > start,stop,alive RADIUS-packets)!! I have started using FreeRADIUS > from 0.4 version, and this problem persist... >> >> What's wrong? >> >> The second -- in sql_postgresql.c sql_free_result is marked >> as 'not_implemented' in rlm_sql_postgresql structure, however >> sql_free_result function is declared and implemented. Maybe I >> need simply export this function in rlm_sql_postgresql structure? >> Calling PQclear is critical in order to avoid memory leaks. - List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
