hi list!<br><br>we tried to log accounting of ser on postgres, but it seems that logging was not successful. here are the simulations we did :<br><br>- we convert all the schema of mysql to postgresql databse (ser schema), just minor revision on datatypes since we don't find any 
posgresql.sql for ser on the net<br>- followed this steps <a href="http://www.voip-info.org/wiki/view/SER+module+postgres">http://www.voip-info.org/wiki/view/SER+module+postgres</a><br>- recompiled ser to support postgresql database
<br>- tried to configure/run ser.cfg to log accounting but no luck<br>- we did some search and tried it first on mysql database<br>&nbsp;&nbsp; - edit the src of acc module and edit the Makefile to support SQL logging, recompile the 
acc.so <br>&nbsp;&nbsp; - copy the new acc.so to /path/of/ser/modules/<br>&nbsp;&nbsp; - add db_flag on ser.cfg<br>&nbsp;&nbsp; - now acc mysql was logging <br>- tried to replace the connector from mysql to postgresql on ser.cfg with the same config<br>
&nbsp;&nbsp; - ngrep port 5432 on localhost but it seems no request came from ser<br>&nbsp;&nbsp; - ser was running ok and we see logs on /var/log/messages that acc was working<br><br>* do we missed something? or probably tweak some configuration? 
<br>* below are snippet of my ser.cfg<br><br>thanks and regards<br>emer <br><br>------------------------------------------------------------<br>fifo=&quot;/tmp/ser_fifo&quot;<br>fifo_db_url=&quot;postgres://ser:heslo-757@localhost
:5432/ser&quot;<br><br># ------------------ module loading ----------------------------------<br><br>loadmodule &quot;/usr/local/lib/ser/modules/tm.so&quot;<br>loadmodule &quot;/usr/local/lib/ser/modules/acc.so&quot;<br>loadmodule &quot;/usr/local/lib/ser/modules/sl.so&quot;
<br>loadmodule &quot;/usr/local/lib/ser/modules/maxfwd.so&quot;<br>loadmodule &quot;/usr/local/lib/ser/modules/rr.so&quot;<br>loadmodule &quot;/usr/local/lib/ser/modules/postgres.so&quot;<br><br># ----------------- setting module-specific parameters ---------------
<br>modparam(&quot;usrloc&quot;, &quot;db_mode&quot;, 0)<br>modparam(&quot;auth_db&quot;, &quot;calculate_ha1&quot;, 1)<br>modparam(&quot;auth_db&quot;, &quot;password_column&quot;, &quot;password&quot;)<br>modparam(&quot;auth_db&quot;,&quot;db_url&quot;, &quot;
postgres://ser:heslo-757@localhost:5432/ser&quot;)<br><br># -- acc params --<br>modparam(&quot;acc&quot;, &quot;log_level&quot;, 1)<br># that is the flag for which we will account -- don't forget to<br># set the same one :-)
<br>modparam(&quot;acc&quot;, &quot;log_flag&quot;, 1 )<br>modparam(&quot;acc&quot;, &quot;db_flag&quot;, 1)<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; /* ********* RR ********************************** */<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; /* grant Route routing if route headers present */
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if (loose_route())<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; # mark the BYEs -- they are requests within a dialog<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if(method==&quot;BYE&quot;)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; setflag(1);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; t_relay();
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; break;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; };<br><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; /* record-route INVITEs -- all subsequent requests must visit us */<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if (method==&quot;INVITE&quot;) {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; setflag(1);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; record_route();
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; };<br>----------------------------------------------------------------------------------------------------<br># postges/ser process<br>10199 ?&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; S&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0:00 ser -f pstn.ser02<br>10201 ?&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; S&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0:00 ser -f 
pstn.ser02<br>10205 ?&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; S&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0:00 postgres: ser ser 127.0.0.1(56629) idle<br>10203 ?&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; S&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0:00 ser -f pstn.ser02<br>10209 ?&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; S&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0:00 postgres: ser ser 127.0.0.1(56630) idle<br>10211 ?&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; S&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0:00 postgres: ser ser 
127.0.0.1(56631) idle<br>10206 ?&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; S&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 0:00 ser -f pstn.ser02<br><br><br>