Skip to content

MI_FIFO module

This is a module which provides a FIFO transport layer implementation for Management Interface. It receives the command over a FIFO file and returns the output through the reply_fifo specified.

The module checks every 30 seconds if the FIFO file exists, and if it was deleted, it recreates it. If one wants to force the fifo file recreation, it should send a SIGHUP signal to the MI process PID.

The external commands issued via FIFO interface must follow the following syntax:

  • request = first_line argument*
  • first_line = ’:‘command_name’:‘reply_fifo’\n’
  • argument = (arg_name ’::’ (arg_value)? ) | (arg_value)
  • arg_name = not-quoted_string
  • arg_value = not-quoted_string | ’”’ string ’”’
  • not-quoted_string = string - {’,”,\n,\r}

The following modules must be loaded before this module:

  • No dependencies on other OpenSIPS modules.

The following libraries or applications must be installed before running OpenSIPS with this module loaded:

  • none

The name of the FIFO file to be created for listening and reading external commands.

Default value is NONE.

Set fifo_name parameter
...
modparam("mi_fifo", "fifo_name", "/tmp/opensips_fifo")
...

Permission to be used for creating the listening FIFO file. It follows the UNIX conventions.

Default value is 0660 (rw-rw----).

Set fifo_mode parameter
...
modparam("mi_fifo", "fifo_mode", 0600)
...

Group to be used for creating the listening FIFO file.

Default value is the inherited one.

Set fifo_group parameter
...
modparam("mi_fifo", "fifo_group", 0)
modparam("mi_fifo", "fifo_group", "root")
...

User to be used for creating the listening FIFO file.

Default value is the inherited one.

Set fifo_user parameter
...
modparam("mi_fifo", "fifo_user", 0)
modparam("mi_fifo", "fifo_user", "root")
...

Directory to be used for creating the reply FIFO files.

Default value is “/tmp/“

Set reply_dir parameter
...
modparam("mi_fifo", "reply_dir", "/home/opensips/tmp/")
...

Strings to be used for line indentation. As the MI data structure is tree oriendeted, the depth level will printed as indentation.

Default value is ""\t” (TAB)”.

Set reply_indent parameter
...
modparam("mi_fifo", "reply_indent", " ")
...

No function exported to be used from configuration file.

This is an example showing the FIFO format for the “get_statistics dialog: tm:” MI commad: response.

FIFO request
:get_statistics:reply_fifo\n
dialog:\n
tm:\n
\n

doc copyrights:

Top contributors by DevScore(1), authored commits(2) and lines added/removed(3)

#NameDevScoreCommitsLines++Lines—
1.Bogdan-Andrei Iancu (@bogdan-iancu)56312279273
2.Daniel-Constantin Mierla (@miconda)12102022
3.Liviu Chircu (@liviuchircu)862457
4.Razvan Crainea (@razvancrainea)8515657
5.Stefan Darius (@dariusstefan)7421220
6.Henning Westerholt (@henningw)5262109
7.Jerome Martin3133
8.Walter Doekes (@wdoekes)3122
9.Konstantin Bokarius3125
10.Ovidiu Sas (@ovidiusas)3122

All remaining contributors: Julián Moreno Patiño, Edson Gellert Schubert, Dusan Klinec (@ph4r05).

(1) DevScore = author_commits + author_lines_added / (project_lines_added / project_commits) + author_lines_deleted / (project_lines_deleted / project_commits)

(2) including any documentation-related commits, excluding merge commits

(3) ignoring whitespace edits, renamed files and auto-generated files

#NameCommit Activity
1.Stefan Darius (@dariusstefan)Jun 2026 - Jul 2026
2.Razvan Crainea (@razvancrainea)Feb 2012 - Jun 2026
3.Bogdan-Andrei Iancu (@bogdan-iancu)Oct 2006 - Jun 2018
4.Liviu Chircu (@liviuchircu)Mar 2014 - Jun 2018
5.Julián Moreno PatiñoFeb 2016 - Feb 2016
6.Dusan Klinec (@ph4r05)Dec 2015 - Dec 2015
7.Walter Doekes (@wdoekes)May 2014 - May 2014
8.Daniel-Constantin Mierla (@miconda)Nov 2006 - Mar 2008
9.Konstantin BokariusMar 2008 - Mar 2008
10.Edson Gellert SchubertFeb 2008 - Feb 2008

All remaining contributors: Ovidiu Sas (@ovidiusas), Henning Westerholt (@henningw), Jerome Martin.

(1) including any documentation-related commits, excluding merge commits

Last edited by: Razvan Crainea (@razvancrainea), Bogdan-Andrei Iancu (@bogdan-iancu), Liviu Chircu (@liviuchircu), Daniel-Constantin Mierla (@miconda), Konstantin Bokarius, Edson Gellert Schubert, Jerome Martin.

All documentation files (i.e. .md extension) are licensed under the Creative Common License 4.0