Upgrade 3CX to v18 and get it hosted free!

OpenPBX.org How to use the dialplan checking and conversion script

Author image

Background

CallWeaver uses hash values to identify variables and application names in the dialplan. This is much faster and more efficient than the character-by-character string comparison method used in Asterisk. However, it leads to case sensitive variables and application names.

Also, AGI has been renamed to OGI to avoid any potential trademark disputes and Macro has been renamed to Proc because it was a misnomer as macros do not execute in their own stack, procedures do.

Therefore, a dialplan checking and conversion script is provided so that users who migrate from Asterisk can automatically check and convert their dialplan. This page describes how to use this script.

Some important notes

  • chkDialplan.pl, applications.txt and all the extensions config files you want to convert need to be in the same directory (just pick one!)
  • The script assumes your main extensions config file is called extensions.conf and that the application list file is called applications.txt.
  • If this is not the case, do the following:
  • $ vi chkDialplan.pl
  • Find my $def_applications=”applications.txt” and modify its value
  • Find my $def_extensions=”extensions.conf” and modify its value

Using the script

  • For help type
  • $ ./chkDialplan.pl (Usage: ./chkDialplan.pl [modify|validate])
  • If extensions.conf or applications.txt are not found or are not in the same directory, you will get some errors.
  • ALL the configuration files you want to check or convert need to be in the same directory as the above files
  • The script will automatically build a list of included files in extensions.conf

Checking your dialplan

  • To check your dialplan type:
    • $ ./chkDialplan.pl validate
      • This will generate a log file with some lines like this:
        • extensions.conf:41: ‘exten => s-BUSY,2,wait(4)’ should be Wait
          • That means in extensions.conf, on line 41 you need to make that change
  • If you get the following message:
    • Unknown command: Voicemail2
      • This means we either dont support that application or our applications.txt is outdated.
      • Please log in to the CLI and type: CLI> show applications and look for it.

Modifying your dialplan

  • To modify your dialplan type:
    • $ ./chkDialplan.pl modify
      • This will rename all your original files to .bak
  • If you get the following message:
    • Unknown command: Voicemail2
      • This means we either don’t support that application or our applications.txt is outdated.
      • Please log in to the CLI and type: CLI> show applications and look for it.

More info

OpenPBX.org wiki on VoIP-Info.org | CallWeaver home page |

Related Posts:

Get 3CX - Absolutely Free!
Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.