[OpenSIPS-Users] Clusterer without a database

Fabian Gast fgast+opensips at only640k.net
Wed Aug 8 04:43:43 EDT 2018


Hi, 

add this: 

loadmodule "db_text.so"
modparam("clusterer", "db_url", "text:///etc/opensips/db/")

In the database directory add two files 
 - version ( found in sources at scripts/dbtext/opensips/version )
 - clusterer from scripts/dbtext/opensips/clusterer 

Add your cluster nodes to 'clusterer' file like 

id(int,auto) cluster_id(int) node_id(int) url(string) state(int) no_ping_retries(int) priority(int) sip_addr(string,null) flags(string,null) description(string,null)

1:200:1:bin\:192.168.99.201\:60200:1:3:50:NULL:NULL:node-a
2:200:2:bin\:192.168.99.202\:60200:1:3:50:NULL:NULL:node-b


Cheers, 

Fabian 

----- Ursprüngliche Mail -----
Von: "Callum Guy" <callum.guy at x-on.co.uk>
An: "OpenSIPS users mailling list" <users at lists.opensips.org>
Gesendet: Mittwoch, 8. August 2018 10:25:30
Betreff: [OpenSIPS-Users] Clusterer without a database

Hi All, 
For "greater good" I thought it would be interesting to add some clusterer dialog replication to my OpenSIPs pair. 

Specifically I am on 2.4, installed the appropriate clusterer module and applied the following configuration: 

+# Replication listener 
+listen=bin: [ http://172.18.0.112:5566/ | 172.18.0.112:5566 ] 
+loadmodule "proto_bin.so" 
+loadmodule "clusterer.so" 
+ 
+# Setup replication cluster 
+modparam("clusterer", "current_id", 2) 
+modparam("clusterer", "db_mode", 0) 
+modparam("clusterer", "current_info", "cluster_id=1, url=bin: [ http://172.18.0.112:5566/ | 172.18.0.112:5566 ] ") # data about this node 
+modparam("clusterer", "neighbor_info", "cluster_id=1,node_id=1,url=bin: [ http://172.18.0.111:5566/ | 172.18.0.111:5566 ] ") # data about other node 
+modparam("dialog", "dialog_replication_cluster", 1) 
+modparam("dialog", "profile_replication_cluster", 1) 

Once configured I attempted to start the service only to discover that clusterer will not load without a database module. See below: 

Aug 08 08:55:10 [ http://pci-fram-proxy2.x-onsecure.net/ | pci-fram-proxy2.x-onsecure.net ] opensips-m4cfg[30867]: Aug 8 08:55:10 [30867] WARNING:core:solve_module_dependencies: module clusterer depends on an sqldb module, but none was loaded! 
Aug 08 08:55:10 [ http://pci-fram-proxy2.x-onsecure.net/ | pci-fram-proxy2.x-onsecure.net ] opensips-m4cfg[30867]: Aug 8 08:55:10 [30867] ERROR:core:main: failed to solve module dependencies 

For now I have simply reverted back however I wonder if this is a user error or a module/documentation error? 

Thanks, 

Callum 
-- 
Callum Guy 
Head of Information Security 
X-on 






0333 332 0000 | [ http://www.x-on.co.uk/ | www.x-on.co.uk ] | [ https://www.linkedin.com/company/x-on ] [ https://www.facebook.com/XonTel ] [ https://twitter.com/xonuk ] 
X-on is a trading name of Storacall Technology Ltd a limited company registered in England and Wales. 
Registered Office : Avaland House, 110 London Road, Apsley, Hemel Hempstead, Herts, HP3 9SD. Company Registration No. 2578478. 
The information in this e-mail is confidential and for use by the addressee(s) only. If you are not the intended recipient, please notify X-on immediately on +44(0)333 332 0000 and delete the 
message from your computer. If you are not a named addressee you must not use, disclose, disseminate, distribute, copy, print or reply to this email. Views or opinions expressed by an individual 
within this email may not necessarily reflect the views of X-on or its associated companies. Although X-on routinely screens for viruses, addressees should scan this email and any attachments 
for viruses. X-on makes no representation or warranty as to the absence of viruses in this email or any attachments. 


_______________________________________________ 
Users mailing list 
Users at lists.opensips.org 
http://lists.opensips.org/cgi-bin/mailman/listinfo/users 




More information about the Users mailing list