Upgrade from 2.11 to 12.x failure. freepbx_conf.class.php:1075 reports unknown type: [textarea]

I have been attempting to upgrade from 2.11 to 12.x and am stumped with this error. I was able to access the 12.x module admin and download/update the modules. However, I now get this error:

FATAL ERROR

unknown type: [textarea]

Trace Back

/usr/local/www/apache24/data/admin/libraries/freepbx_conf.class.php:1075 die_freepbx()
[0]: unknown type: [textarea]

/usr/local/www/apache24/data/admin/libraries/freepbx_conf.class.php:228 freepbx_conf->_prepare_conf_value()
[0]: FreePBX – Let Freedom Ring Sangoma Technologies
[1]: textarea
[2]: 1
[3]:

/usr/local/www/apache24/data/admin/libraries/freepbx_conf.class.php:178 freepbx_conf->__construct()

/usr/local/www/apache24/data/admin/bootstrap.php:88 freepbx_conf::create()

/etc/freepbx.conf:9 require_once()
[0]: /usr/local/www/apache24/data/admin/bootstrap.php

/usr/local/www/apache24/data/admin/config.php:99 include_once()
[0]: /etc/freepbx.conf

I have the following pear modules installed:

Installed packages, channel pear.php.net:

Package Version State
Archive_Tar 1.3.13 stable
Cache_Lite 1.7.16 stable
Console_Color 1.0.3 stable
Console_Getopt 1.3.1 stable
DB 1.7.14 stable
DB_DataObject 1.11.3 stable
Date 1.4.7 stable
File_Gettext 0.4.2 beta
File_PDF 0.3.3 beta
HTML_Common 1.2.5 stable
HTML_Common2 2.1.0 stable
HTML_Javascript 1.1.2 stable
HTML_QuickForm 3.2.13 stable
HTML_QuickForm2 0.6.1 beta
HTML_Template_Flexy 1.3.12 stable
I18Nv2 0.11.4 beta
Image_Canvas 0.3.2 alpha
Image_Color 1.0.4 stable
Image_Graph 0.8.0 alpha
Log 1.12.7 stable
MDB2 2.5.0b5 beta
Mail 1.2.0 stable
Mail_Mime 1.8.9 stable
Net_SMTP 1.6.2 stable
Net_Socket 1.0.14 stable
PEAR 1.9.5 stable
Structures_Graph 1.0.4 stable
Translation2 2.0.4 stable
Validate 0.8.5 beta
XML_HTMLSax 2.1.2 stable
XML_Parser 1.3.4 stable
XML_RPC 1.5.5 stable
XML_Serializer 0.20.2 beta
XML_Util 1.2.3 stable

In FreePBX 12 this file is 10 lines of code. Your update didn’t go as expected. Revert to a backup and try again.

Thanks. I blew away all the existing stuff from my /usr/local/apache24/data/freepbx directory and started over. I am doing this on FreeBSD BTW, 10.1. However, I am now running into a problem with freepbx_engine during the install or when I attempt to fix stuff with amportal. I see:

PHP Warning: PHP Startup: Unable to load dynamic library ‘/usr/local/lib/php/20121212-zts/http.so’ - Cannot open “/usr/local/lib/php/20121212-zts/http.so” in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library ‘/usr/local/lib/php/20121212-zts/memcache.so’ - Cannot open “/usr/local/lib/php/20121212-zts/memcache.so” in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library ‘/usr/local/lib/php/20121212-zts/soap.so’ - /usr/local/lib/php/20121212-zts/soap.so: Undefined symbol “ps_globals_id” in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library ‘/usr/local/lib/php/20121212-zts/wddx.so’ - /usr/local/lib/php/20121212-zts/wddx.so: Undefined symbol “ps_globals_id” in Unknown on line 0
PHP Warning: PHP Startup: Unable to load dynamic library ‘/usr/local/lib/php/20121212-zts/memcached.so’ - /usr/local/lib/php/20121212-zts/memcached.so: Undefined symbol “ps_globals_id” in Unknown on line 0
/usr/local/asterisk/bin/freepbx_engine: line 98: Warning:: command not found
**** WARNING: ERROR IN CONFIGURATION ****
astrundir in ‘/etc/asterisk’ is set to but the directory
does not exists. Attempting to create it with: 'mkdir -p ’

usage: mkdir [-pv] [-m mode] directory_name …
**** ERROR: COULD NOT CREATE ****
Attempt to execute 'mkdir -p ’ failed with an exit code of 64
You must create this directory and the try again.

That line is:

$gen_path/gen_amp_conf.php

And the whole thing dies even though I can run that script (which really lives at /usr/local/asterisk/bin/gen_amp_conf.php):

Warning: PHP Startup: Unable to load dynamic library ‘/usr/local/lib/php/20121212-zts/http.so’ - Cannot open “/usr/local/lib/php/20121212-zts/http.so” in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘/usr/local/lib/php/20121212-zts/memcache.so’ - Cannot open “/usr/local/lib/php/20121212-zts/memcache.so” in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘/usr/local/lib/php/20121212-zts/soap.so’ - /usr/local/lib/php/20121212-zts/soap.so: Undefined symbol “ps_globals_id” in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘/usr/local/lib/php/20121212-zts/wddx.so’ - /usr/local/lib/php/20121212-zts/wddx.so: Undefined symbol “ps_globals_id” in Unknown on line 0

Warning: PHP Startup: Unable to load dynamic library ‘/usr/local/lib/php/20121212-zts/memcached.so’ - /usr/local/lib/php/20121212-zts/memcached.so: Undefined symbol “ps_globals_id” in Unknown on line 0
export AS_DISPLAY_FRIENDLY_NAME=1
export AS_DISPLAY_HIDDEN_SETTINGS=0
export AS_DISPLAY_READONLY_SETTINGS=1
export AS_OVERRIDE_READONLY=1
export HTTPENABLESTATIC=1
export HTTPENABLED=1


Has anyone got by this madness?

Thanks

That script expects parameters to be EXPORTED to bash so that it can read them. If there is any garbage out it won’t work. You’ve got a ton of garbage from your system (completely un freepbx related) that you should fix. I am really baffled that PHP Startup messages have not even grabbed your attention, they are really really bad.

OK, I have FreePBX 12.x up and running (sort of) on FreeBSD 10.1 with asterisk 1.8.x. What I have done so far is…

portupgrade -r -f php55

Which completely rebuilds all php55 modules recursively. Then clean out all the stuff under /usr/local/www/apache24/data/freepbx and then run install_amp. After that I struggled through sprintf_ errors in the GPG scripts by cli upgrading framework and core. I had to upgrade all the “broken” modules using the cli since the module admin gui is a complete fail. Now, most of the gui functions except for the apply config button which fails because of errors like these:

PHP Strict Standards: Non-static method DB::isManip() should not be called statically, assuming $this from incompatible context in /usr/local/share/pear/DB/common.php on line 2200
PHP Strict Standards: Non-static method DB::isError() should not be called statically in /usr/local/www/apache24/data/freepbx/admin/libraries/sql.functions.php on line 24
PHP Strict Standards: Non-static method DB::isManip() should not be called statically, assuming $this from incompatible context in /usr/local/share/pear/DB/common.php on line 2200
PHP Strict Standards: Non-static method DB::isError() should not be called statically in /usr/local/www/apache24/data/freepbx/admin/libraries/sql.functions.php on line 24

I assume there should be coding changes to depricate reliance on DB in php at some point? In any event - I can manually from retreive_conf from the cli and it updates the conf files. So, it’s limping along.

Something else I had to do is symlink /usr/local/bin/gpg to /usr/bin/gpg to get updates to work…

Those are not errors. They won’t prevent apply changes. There’s more you aren’t showing us. Would be nice to know the sprintf errors as well instead of being left in the dark

The sprintf errors are the ones documented in the bug forums. I am going to guess that it is a known thing. Other than that, I had to manually update everything to get things working. The retrieve_conf error I get is “error = 20” in case you are wondering. Other than that - you are missing nothing. Perhaps a new tarball download is in order. 12.0.3 does not work. Period. Not out of the box anyway…

Ian

P.S If there is better documented error reporting info I will happily report my woes… :smiley:

Oh right 12.0.3 is very old. We are at 23 now. Most people just checkout from our source these days. I will update the tarball links. No need to report bugs on things that were already fixed.

FreeBSD is not supported. But I guess you know that.

I do. It’s mostly working now though…

I had to add this to /usr/local/etc/php.ini to get apply changes:

error_reporting = E_ALL & ~E_NOTICE & ~E_WARNING & ~E_STRICT & ~E_DEPRECATED

That’s all I have so far. More support beyond Linux is better all the way round I would guess. :smiley:

But I still wonder if DB needs to replaced with something more current as far as php is concerned. Like move something PDO, etc…

This is already done in 13. It was not an easy process.

I have a new problem that you might know the answer to (before I go down the rabbit hole) is this:

Warning: Cannot connect to online repository(s) (http://mirror1.freepbx.org,http://mirror2.freepbx.org). Online modules are not available.

When trying to check for new modules online…

You have some firewall or packet filtering technology that isn’t allowing freepbx to connect online. Note that it uses cURL and wget as a fallback

So, in the end I would consider this “solved” as it turned out that I removed wget some time ago on the server (I forget exactly why). A simple reinstall of wget and all seems well. So far…

Thanks,

Iansouth1