Documentation -> Manuals -> Manual devel -> Binary Internal Interface
Page for other versions: devel 1.9 1.8 old versions: 1.7 1.6 1.5 1.4
The Binary Internal Interface is an OpenSIPS core interface which offers an efficient way for communication between individual OpenSIPS instances. This is especially useful in scenarios where realtime data (such as dialogs) cannot be simply stored in a database anymore, because failover would require entire minutes to complete. This issue can be solved with the new internal binary interface by replicating all the events related to the runtime data (creation / updating / deletion) to a backup OpenSIPS instance.
Configuring the Binary Internal Interface listeners
In order to send or listen for Binary Packets, an interface must be specified using the bin_listen global script parameter. The number of listener processes can be tuned with the optional bin_children (default: 1)
bin_listen = 10.0.0.150:5062 bin_children = 2
Currently, the only module to make use of the interface is the dialog module, which can now replicate all dialog-related events to one or more OpenSIPS instances. Configuration can be done as follows:
modparam("dialog", "accept_replicated_dialogs", 1) modparam("dialog", "replicate_dialogs_to", "18.104.22.168:5062")
More details can be found in the documentation page of the module.
C Interface Overview (for module developers)
The interface allows the module writer to build and send compact Binary Packets in an intuitive way.
In order to send packets the interface provides the following primitives: