[Serusers] Postgres instead of Mysql

Jan Janak jan at iptel.org
Tue Dec 13 12:56:46 CET 2005


There are more modules using database than just usrloc, in your config
file it is also auth_db. They default to mysql, thus if you want to use
postgres then you should reconfigure db_url parameters of all modules:

modparam("usrloc|auth_db", "db_url", "postgres://ser:my_pass@localhost:5432/ser")

On 13-12-2005 09:47, Felipe Louback wrote:
> Jan, thanx for replying....
> 
> I did what you suggested but I got the following error(from my log):
> 
>  0(0) find_mod_export: <db_use_table> in module mysql not found
>  0(0) bind_dbmod: Module mysql does not export db_use_table function
> 
> Now Module mysql appeared.... weird...I have no mention to Mysql. Any
> other clue?
> 
> Felipe Louback
> 
> On 12/13/05, Jan Janak <jan at iptel.org> wrote:
> > This line in your config:
> > modparam("usrloc", "db_url", "sql://ser:my_pass@localhost:5432/ser")
> >
> > should read
> >
> > modparam("usrloc", "db_url", "postgres://ser:my_pass@localhost:5432/ser")
> >
> >   Jan.
> >
> > On 13-12-2005 09:36, Felipe Louback wrote:
> > > I am trying to use Postgres instead of Mysql, but I dont know why,
> > > then I initialize ser, I get the following error:
> > >
> > >  0(0) find_mod_export: <db_use_table> in module sql not found
> > >  0(0) bind_dbmod: Module sql does not export db_use_table function
> > >  0(0) ERROR: mod_init(): Can't bind database module
> > >
> > > I cant figure out the reason for this message "<db_use_table> in
> > > module sql not found".
> > >
> > > I have no idea why this is happening. When I was working with Mysql, I
> > > didn't have this problem, but now, I just cant put Postgres to work.
> > > Any ideas?
> > >
> > > Here is part of my ser.cfg:
> > > ============================================================
> > > loadmodule "/usr/local/lib/ser/modules/postgres.so"
> > > loadmodule "/usr/local/lib/ser/modules/sl.so"
> > > loadmodule "/usr/local/lib/ser/modules/tm.so"
> > > loadmodule "/usr/local/lib/ser/modules/rr.so"
> > > loadmodule "/usr/local/lib/ser/modules/maxfwd.so"
> > > loadmodule "/usr/local/lib/ser/modules/usrloc.so"
> > > loadmodule "/usr/local/lib/ser/modules/registrar.so"
> > > loadmodule "/usr/local/lib/ser/modules/textops.so"
> > >
> > > # Uncomment this if you want digest authentication
> > > # mysql.so must be loaded !
> > > loadmodule "/usr/local/lib/ser/modules/auth.so"
> > > loadmodule "/usr/local/lib/ser/modules/auth_db.so"
> > >
> > >
> > > modparam("usrloc", "db_mode", 2)
> > > modparam("auth_db", "calculate_ha1", yes)
> > > modparam("auth_db", "password_column", "password")
> > >
> > > modparam("rr", "enable_full_lr", 1)
> > >
> > > modparam("usrloc", "user_column", "username")
> > > modparam("usrloc", "db_url", "sql://ser:my_pass@localhost:5432/ser")
> > > ===================================================================
> > >
> > > Here is part of the log when I initialize SER:
> > > =============================================================
> > >  0(0) DEBUG: init_mod: usrloc
> > >  0(0) usrloc - initializing
> > >  0(0) DEBUG: register_fifo_cmd: new command (ul_stats) registered
> > >  0(0) DEBUG: register_fifo_cmd: new command (ul_rm) registered
> > >  0(0) DEBUG: register_fifo_cmd: new command (ul_rm_contact) registered
> > >  0(0) DEBUG: register_fifo_cmd: new command (ul_dump) registered
> > >  0(0) DEBUG: register_fifo_cmd: new command (ul_flush) registered
> > >  0(0) DEBUG: register_fifo_cmd: new command (ul_add) registered
> > >  0(0) DEBUG: register_fifo_cmd: new command (ul_show_contact) registered
> > >  0(0) unixsock_register_cmd: New command (ul_stats) registered
> > >  0(0) unixsock_register_cmd: New command (ul_rm) registered
> > >  0(0) unixsock_register_cmd: New command (ul_rm_contact) registered
> > >  0(0) unixsock_register_cmd: New command (ul_dump) registered
> > >  0(0) unixsock_register_cmd: New command (ul_flush) registered
> > >  0(0) unixsock_register_cmd: New command (ul_add) registered
> > >  0(0) unixsock_register_cmd: New command (ul_show_contact) registered
> > >  0(0) find_mod_export: <db_use_table> in module sql not found
> > >  0(0) bind_dbmod: Module sql does not export db_use_table function
> > >  0(0) ERROR: mod_init(): Can't bind database module
> > >  0(0) init_mod(): Error while initializing module usrloc
> > > ERROR: error while initializing modules
> > >  0(0) DEBUG: tm_shutdown : start
> > >  0(0) DEBUG: unlink_timer_lists : emptying DELETE list
> > >  0(0) DEBUG: tm_shutdown : emptying hash table
> > >  0(0) DEBUG: tm_shutdown : releasing timers
> > >  0(0) DEBUG: tm_shutdown : removing semaphores
> > >  0(0) DEBUG: tm_shutdown : destroying tmcb lists
> > >  0(0) DEBUG: tm_shutdown : done
> > >  0(27948) shm_mem_destroy
> > >  0(27948) destroying the shared memory lock
> > > ================================================================
> > >
> > > Any clue is more than welcome... thanks.
> > >
> > > Felipe Louback
> > >
> > > --
> > > Mestrando - Departamento de Engenharia Elétrica
> > > Grupo de Pesquisa em Engenharia da Computaç?o e Telecomunicaç?es
> > > Universidade Federal de Minas Gerais - Brasil
> > >
> > > "Todas as coisas cooperam para o bem daqueles que amam a Deus"
> > > Romanos 8:28
> > >
> > > _______________________________________________
> > > Serusers mailing list
> > > serusers at lists.iptel.org
> > > http://lists.iptel.org/mailman/listinfo/serusers
> >
> 
> 
> --
> Mestrando - Departamento de Engenharia Elétrica
> Grupo de Pesquisa em Engenharia da Computaç?o e Telecomunicaç?es
> Universidade Federal de Minas Gerais - Brasil
> 
> "Todas as coisas cooperam para o bem daqueles que amam a Deus"
> Romanos 8:28
> 
> _______________________________________________
> Serusers mailing list
> serusers at lists.iptel.org
> http://lists.iptel.org/mailman/listinfo/serusers




More information about the sr-users mailing list