Troubleshooting 0 8

Installation Problems

Error was: No module named ext when viewing index page

You will likely see this on Ubuntu Hardy (and possibly later) if you installed python-xml using:

$ apt-get install python-xml

instead of installing from the .tar.gz file.

See the Installation Manual under the python-xml section, it explained in detail

Error loading ESL module

This means its not finding the ESL module on the python path from within the wsgi context.


  • You forgot to build the ESL module for python
  • You forgot to set the WSGIPythonPath wsgi variable in the apache config, or had a typo
  • You correctly set it and for whatever reason its being ignored

The workaround is to modify the /usr/src/wikipbx/wikipbx.wsgi file to manually add the ESL directory. Please post on the forum if you need help with that.

ImportError: No module named django

Looks like you're using a newer ubuntu or other debian-based distro where they've renamed site-packages to dist-packages for python 2.6.

So you can do one of the following:

1. Create the symlink in /usr/lib/python2.6/dist-packages directory instead of site-packages.

2. Add site-packages to python path by setting it:

sudo PYTHONPATH="/usr/lib/python2.6/site-packages:$PYTHONPATH" syncdb

3. Don't install django, add it's root directory to pythonpath instead:

sudo PYTHONPATH="/usr/src/django:$PYTHONPATH" syncdb

No module named wikipbx.settings

This can happen for a number of reasons:

  • You forgot to copy to
  • You have a typo in the WSGIPythonPath variable
  • Mod_wsgi is not picking up the WSGIPythonPath variable correctly (please post on forum if that's the case)

Operation Problems

The XML config files are not being updated

WikiPBX is not supposed to update any xml files, instead FreeSWITCH '''pulls''' dynamic xml configuration from WikiPBX, over HTTP. The dynamic XML configuration is generated based on information in the WikiPBX database.

FreeSWITCH is not pulling configuration from WikiPBX

Most likely, mod_xml_curl is not correctly loaded or configured to pull configuration from freeswitch. To find out, try the following:

  • Type "sofia status" on the command line. If you don't see the profiles that you defined in WikiPBX, then mod_xml_curl is not correctly loaded or configured.
  • After starting FreeSWITCH, scroll up and look at the output, and make sure mod_xml_curl is loaded.
  • While starting FreeSWITCH, look on the WikiPBX console and you should see output when FreeSWITCH queries WikiPBX for configuration.

To fix the problem:

  • Make sure xml_curl is being compiled, is correctly configured, set to load at freeswitch startup (modules.conf.xml). See Installation Manual for details.

The Completed Calls (CDR) section is empty

Double check that you uncommented this line in modules.conf.xml:

 <load module="mod_xml_cdr"/>

CDR errors on freeswitch console

If you see an error like:

Got error [404] posting to web server []

Then you need to modify wikipbx/ and set FREESWITCH_URL_PORT to an appropriate value.

If you see an error like:

[ERR] mod_xml_cdr.c:246 Error writing [/var/log/wikipbx/cdr/4fc2dfe6-7714-44b1-8a1f-1446c6eda52c.cdr.xml][]

Then you need to create the directory specified in the LOG_DIR_ROOT parameter in, and/or set the permissions on that directory so the user that runs the freeswitch process can write to it.

How do I debug the configuration passed from WIkiPBX -> FreeSWITCH?

WikiPBX logs output to stderr which gets added to apache logs. The locations may vary based on where you configured the logs to write to, but it should be approximately like this:

 tail -f /var/log/apache2/error.log /var/log/apache2/

My SIP endpoint doesn't register

One reason this can fail is that FreeSWITCH is not even pulling the configuration from WikiPBX, and thus defaulting to the static XML files. See FreeSWITCH is not pulling configuration from WikiPBX in this document.

Attempt to debug using the xml config menu from the root dashboard.

If that does'nt work, deconfigure wikipbx and make it work using FreeSWITCH XML file config, then post a message to the forum describing the problem.

What version of MySQL does it work with?

1.2.1p2 or newer is required.

What version of PostgreSQL does it work with?

It is known to work with 7.4.7-6 and 8.1. Newer versions will probably work but have not been tested.

How do I get the Django Admin working?

This does not work and the link has been removed from the GUI. Hopefully this will get fixed at some point, but in the meantime you can:

  • Use something like phppgadmin or phpmyadmin to modify the database directly
  • Start a python console and import/query the data models directly from the python shell

DSA sig error installing python-psycopg

Try installing this rpm instead.

undefined symbol: PyUnicodeUCS4_Decode

If you get an error like

ImportError at /add_extension/
/usr/lib/python2.5/site-packages/_xmlplus/parsers/ undefined symbol: PyUnicodeUCS4_Decode

when trying to add an extension (or at any point), then you will need to do the following:

  • Follow instructions in earlier part of document regarding building PyXML from a tar.gz file
  • Try python clean followed by python install in the PyXML source dir

The error can be reproduced with the following:

 $ python
 $ from xml.dom import minidom
 $ dom = minidom.parseString("<hello/>")

If the above runs without any error, the problem is fixed.

More information on error

postgres: FATAL: Ident authentication failed

Try making the following changes in /etc/postgresql/x.y/main/pg_hba.conf:


 local   all         postgres                          ident sameuser
 local   all         all                               ident sameuser


 local   all         postgres                          md5
 local   all         all                               md5

and restarting the postgres server with /etc/init.d/postgresql-x.y restart

NOTE: make sure you are editing the correct pg_hba.conf if you have multiple postgres instances installed.

Apache server hangs on certain pages

There have been reports of apache hanging on certain pages (live calls, manage account, manage gateways) on some distros. Rebuilding ESL with a recent version of SWIG (2.0.0 or higher) should fix it.

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License