User Tools

Site Tools


tutorials:kamailio-and-mongodb

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Last revision Both sides next revision
tutorials:kamailio-and-mongodb [2015/09/08 21:36]
miconda [Other Tables]
tutorials:kamailio-and-mongodb [2015/09/09 00:58]
miconda [Version Table]
Line 1: Line 1:
 ====== Kamailio and MongoDB ====== ====== Kamailio and MongoDB ======
  
 +Details about how to use Kamailio with a MongoDB backend.
 ===== Kamailio Database ===== ===== Kamailio Database =====
  
Line 51: Line 52:
 > db.getCollection("version").insert({table_name: "watchers", table_version: NumberInt(3) }) > db.getCollection("version").insert({table_name: "watchers", table_version: NumberInt(3) })
  
-db.getCollection("version").insert({table_name: "active_watchers", table_version: NumberInt(11) })+db.getCollection("version").insert({table_name: "active_watchers", table_version: NumberInt(11) })
  
 </code> </code>
Line 66: Line 67:
 > db.createCollection("tablename") > db.createCollection("tablename")
 </code> </code>
-===== DB URL in Kamailio Config =====+===== Kamailio Config ===== 
 + 
 +==== DB URL ====
  
 The corresponding database URL in kamailio.cfg: The corresponding database URL in kamailio.cfg:
Line 80: Line 83:
 <code> <code>
 #!define DBURL "mongodb://username:password@localhost/kamailio" #!define DBURL "mongodb://username:password@localhost/kamailio"
 +</code>
 +
 +==== Other Parameters ====
 +
 +If you store location records in MongoDB, set the following parameter for usrloc modules:
 +
 +<code>
 +modparam("usrloc", "db_insert_null", 1)
 </code> </code>
tutorials/kamailio-and-mongodb.txt · Last modified: 2019/01/07 09:24 by henningw