Generating OpenSIPS config files is accomplished by using the menuconfig tool. Because the graphical interface is ncurses based, please make sure to first install the ncurses development library ( typically libncurses5-dev ).

1. Using the Menuconfig Tool

The menuconfig can be ran either directly from the OpenSIPS sources, or post installation, from the installation path :

From sources, you can run

make menuconfig

After installation, you can run menuconfig directly from the installation path, by running

[install_path]/sbin/osipsconfig

Once in the menuconfig tool, navigate to the 'Generate OpenSIPS Script' option, and then choose your desired script type.
Once you have chosen you script type, you will be able to go to configure the various available options for that script ( described below ). Enabling certain options per script is done by using the spacebar key. Once you have configured your desired options, you can hit the 'q' key to go to the previous menu, and hit 'Save Changes'. Then, you can generate the OpenSIPS script with your configurations. At the end, the graphical tool will give you the path for your newly generated config file ( eg : Config generated : /usr/local/opensips_proxy/etc/opensips/opensips_residential_2013-5-21_11:39:48.cfg )

2. Types of Configs

So far, the OpenSIPS 1.9 menuconfig automated script generator supports 3 types of scripts. Here are the types of scripts, along with the available options per script :

USE_DIALPLAN : OpenSIPS will use dialplan for transformation of local numbers

USE_DIALOG : OpenSIPS will keep track of active dialogs

DO_CALL_LIMITATION : OpenSIPS will limit the number of parallel calls per trunk

Load-Balancer Script

ENABLE_TCP : OpenSIPS will listen on TCP for SIP requests

ENABLE_TLS : OpenSIPS will listen on TCP for SIP requests

USE_DBACC : OpenSIPS will save ACC entries in DB for all calls

USE_DISPATCHER : OpenSIPS will use DISPATCHER instead of Load-Balancer for distributing the traffic

DISABLE_PINGING : OpenSIPS will not ping at all the destinations (otherwise it will ping when detected as failed)

3. Post-Generation Script editing

After generating your OpenSIPS script with the menuconfig tool, you need to open the script with your favorite editor, and go through all the '# CUSTOMIZE ME' comments in the script. Those comments mark the places where user attention is needed, and usually refer to customizing the OpenSIPS listening address or setting the proper database URL.

Upon making the appropriate '# CUSTOMIZE ME' changes, you can save your script and take it for a test drive.