UCP Menu Error

In my testing FreePBC-12 with Asterisk-12, I have not yet messed around with the UCP, but I have clicked on the menu option and get the following error message. Eventually I would like to look at the UCP because I thought this was a large part of the rewrite for FreePBX-12. Any thoughts on this error message?

Object not found!

The requested URL was not found on this server. The link on the referring page seems to be wrong or outdated. Please inform the author of that page about the error.

If you think this is a server error, please contact the webmaster.

Error 404
Apache/2.4.9 (Unix) PHP/5.5.14

Doesn’t look like UCP is installed at all. You should try reinstalling it. 404s mean files aren’t found, which, in this case means the directory “ucp” doesn’t exist where it’s suppose to.

Also appears you are on PHP 5.5 which is not tested at this time. How did you install FreePBX?

I’ve been working for a few weeks to create a fully automated installation of FreePBX-12 / Asterisk-12 on ArchLinux ARM. I have always thought FreePBX/Asterisk is a great “appliance” on many of the low cost ARM systems. There was a successful project on the Raspberry Pi awhile back, but that is an older version of FreePBX/Asterisk. ArchLinux ARM already has a native compiled version of Asterisk-12, it’s as simple as pacman -Sy asterisk, just like apt-get on Debian/Ubuntu.

So it’s become a pet project of mine to now get FreePBX-12 setup as a very easy scripted install. I have been working with tm1000 who has been very helpful, I tried to link the other post but it didn’t work. You can find my other post under the INSTALLATION category which will show you my script / notes and exactly what I have had to do to get FreePBX to work with ArchLinux ARM.

The point here is that we’ve only actively tested and developed this on the FreePBX Distro. If you want to use it with no problems then that’s the way to go. Will it work on other OSes? perhaps but that is not a high priority at the moment. For all of the nay-sayers out there I am not even remotely saying it won’t ever work on other ones I am just detailing my development environment

I have no gripes about “package management systems” but it might be of note that we also package our own versions of Asterisk in the FreePBX distro, which now has 12.4.0, the only version of 12 that actually works with WebRTC. Meaning we control what we want in the distro. I could care less if Ubuntu or ArchLinux have Asterisk in their systems, when it comes down to it if there is a security update to Asterisk we will have a release the next day, you can not often say that for pacman or any of the upstream providers.

That said, I just checked the Ubuntu 14.04 system I spun up two days ago and UCP is installed correctly and working from the right address, you didn’t do what I requested which think about it from my perspective, I am asking you to do something and you totally avoid my “proposed” solution to talk about why ArchLinux is so amazing, which means I came in here to see your response thinking you did what I requested only to get lectured about ArchLinux. It’s aggravating from my perspective. My boss asks what you are using simply because he knows what we’ve developed on and you could have answered his question and mine! So let’s try to make this not a waste of either of our time and stick to the topic at hand and what I requested: Please uninstall UCP then reinstall it and run: amportal a r.

I sincerely apologize, my excitement for FreePBX-12 and rambling on about building a simple-to-install version for ARM got the best of me. I would never presume to lecture anyone at FreePBX, and I am very thankful for your assistance tm1000. I think you guys are great and your dedication to bring an easy-to-use UI to Asterisk is phenomenal.

That said, I apologize for forgetting to mention in my response that I actually did as you asked and from Module Admin, I ran both an Uninstall on UCP, then I ran a Remove on UCP. Finally I ran a Download/Install on UCP, ran amportal a r, rebooted my system, clicked the UCP button and received the same error. For reference, I am running Asterisk 12.4.0.

Edit: I have made some progress, when I press the UCP button from the FreePBX UI I get the error, but if I enter the path to the UCP folder ( I now get a solid blue/grey screen. The path to the regular FreePBX admin screen is ( which works fine. Just pressing the UCP button in the FreePBX UI was taking me to ( which was an incorrect path. At least I am pointing my browser to what I think is the correct UCP path, I get the blue/grey screen but no text.

You might want to investigate the relative placement of FreePBX with respect to your native DocumentRoot in the FreePBX install script. I believe admin prefers to be directly in your Document root and the sub directories as peers of it. Such was the case in Debian Wheezy, but Jessie has changed it’s default root to /var/www/html instead of /var/www.

1 Like

@dicko is correct. UCP is coded thus that it must be in the root directory. At least for now. It can’t be under anything else.

You can always see errors (such as blue/grey screen) by simply running: amportal a dbug

Thank you dicko and tm1000. I incorrectly assumed that during FreePBX installation (e.g., ./install_amp …) when you are prompted to enter the web directory for FreePBX, it would have applied to all FreePBX “modules” but I realize we are in beta and this may be one of those items that may be addressed at a later date. So for now, I will re-install FreePBX in the DocumentRoot and see if that changes anything.

I did run amportal a dbug and received the following output. I am not sure what I am looking at, but I at least wanted to share this output in case it was helpful in any way.

[[email protected] freepbx]# amportal a dbug

Please wait…

trying to run as user asterisk:

[FPBXDBUGDISABLE] already set to [0]

==> /var/log/asterisk/freepbx_debug <==

2014-Jul-20 05:27:53 /usr/share/pear/DB/mysql.php:240
[DEPRECATION_WARNING]: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead

2014-Jul-20 05:27:53 /usr/share/pear/DB/mysql.php:240
[DEPRECATION_WARNING]: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead

2014-Jul-20 05:27:54 /usr/share/pear/DB/mysql.php:240
[DEPRECATION_WARNING]: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead

==> /var/log/httpd/error_log <==
[Sat Jul 19 10:07:58.908677 2014] [access_compat:error] [pid 308] [client] AH01797: client denied by server configuration: /srv/http/freepbx/ucp/index.html
[Sat Jul 19 10:07:59.375087 2014] [:error] [pid 308] [client] PHP Fatal error: Call to undefined function UCP\openssl_random_pseudo_bytes() in /srv/http/freepbx/admin/modules/ucp/htdocs/includes/Session.class.php on line 32
[Sat Jul 19 10:08:11.055803 2014] [access_compat:error] [pid 215] [client] AH01797: client denied by server configuration: /srv/http/freepbx/ucp/index.html
[Sat Jul 19 10:08:11.527991 2014] [:error] [pid 215] [client] PHP Fatal error: Call to undefined function UCP\openssl_random_pseudo_bytes() in /srv/http/freepbx/admin/modules/ucp/htdocs/includes/Session.class.php on line 32
[Sat Jul 19 10:19:40.421650 2014] [access_compat:error] [pid 566] [client] AH01797: client denied by server configuration: /srv/http/freepbx/ucp/index.html
[Sat Jul 19 10:19:40.883498 2014] [:error] [pid 566] [client] PHP Fatal error: Call to undefined function UCP\openssl_random_pseudo_bytes() in /srv/http/freepbx/admin/modules/ucp/htdocs/includes/Session.class.php on line 32
[Sat Jul 19 10:20:00.104532 2014] [access_compat:error] [pid 215] [client] AH01797: client denied by server configuration: /srv/http/freepbx/ucp/index.html
[Sat Jul 19 10:20:00.578278 2014] [:error] [pid 215] [client] PHP Fatal error: Call to undefined function UCP\openssl_random_pseudo_bytes() in /srv/http/freepbx/admin/modules/ucp/htdocs/includes/Session.class.php on line 32
[Sat Jul 19 10:22:27.515184 2014] [access_compat:error] [pid 607] [client] AH01797: client denied by server configuration: /srv/http/freepbx/ucp/index.html
[Sat Jul 19 10:22:27.977056 2014] [:error] [pid 607] [client] PHP Fatal error: Call to undefined function UCP\openssl_random_pseudo_bytes() in /srv/http/freepbx/admin/modules/ucp/htdocs/includes/Session.class.php on line 32

==> /var/log/asterisk/freepbx.log <==
[2014-Jul-19 17:19:49] [PHP-NOTICE] (/srv/http/freepbx/admin/modules/webrtc/functions.inc/hook_core.php:15) - Undefined index: tech_hardware
[2014-Jul-19 17:27:26] [PHP-NOTICE] (/srv/http/freepbx/admin/modules/webrtc/functions.inc/hook_core.php:15) - Undefined index: tech_hardware
[2014-Jul-20 05:27:27] [INFO] (bin/freepbx_setting:39) - trying to run as user asterisk:
[2014-Jul-20 05:27:27] [INFO] (bin/freepbx_setting:40) -
[2014-Jul-20 05:27:28] [INFO] (bin/freepbx_setting:76) - [FPBXDBUGDISABLE] changed from previous value: [1] to new value: [0]
[2014-Jul-20 05:27:28] [INFO] (bin/freepbx_setting:77) -
[2014-Jul-20 05:27:54] [INFO] (bin/freepbx_setting:39) - trying to run as user asterisk:
[2014-Jul-20 05:27:54] [INFO] (bin/freepbx_setting:40) -
[2014-Jul-20 05:27:54] [INFO] (bin/freepbx_setting:61) - [FPBXDBUGDISABLE] already set to [0]
[2014-Jul-20 05:27:54] [INFO] (bin/freepbx_setting:62) -

You need to install OpenSSL for php. Look at the undefined function mention above

Good progress, thank you tm1000 :slight_smile:

I modified my install script/notes to enable openssl.so in my php.ini file and will post an updated script in my install thread. I now have access to the UCP, but for now I’m leaving FreePBX installed in my DocumentRoot/freepbx directory (/srv/http/freepbx/admin and /srv/http/freepbx/usp). I just don’t use the UCP button in the FreePBX UI to access UCP, but later (in a few weeks because I’m headed out-of-town) I will do a complete re-install, install FreePBX in my DocumentRoot, run some other tests and report back.

I think i have a solution for the button “wrong link” issue but need to confirm.

Hi - I need some help regarding this same issue. I’m using FreePBX based on a RaspberryPi Debian OS. I used the “Upgrade to version 12” module and followed the instructions. The system is up and running (had to do some minor manual fixes to correct the .htaccess warnings). But when I try to access the ucp i get the 404 error, it doesn’t look like it was installed on my system? The only ucp folders found fall under:

@tm1000 you reference “uninstalling ucp” and reinstalling it… how can i do this, or do you have another recommendation how to fix this?


As noted previously. I am only focusing on support for CentOS at this time. So it working on other systems is up in the air. Though it should work fine and I have reports of it working on beaglebones and pis…

The directories are created (actually symlinked) during “amportal a r” aka retrieve_conf or apply changes (all the same thing)

The directory would be: /var/www/html/ucp but this depends on if AMPWEBROOT was setup correctly and in most non cent/manual installs that value is wrong due to a really old bug that got fixed but is still sometimes there (won’t be officially fixed till 13)

You can uninstall through module admin, just like you can with any other module.

Thanks for the quick response @tm1000

I think the AMPWEBROOT is properly set to /var/www/html/ from what i can see in the amportal.conf .

To your comment that it can be removed through module admin - what is the module to uninstall? All i did was use the “upgrade to version 12” module which upgraded all the necessary framework module, and others as required, and disabled the “ARI” which i understand is now the deprecated ucp. There is no “UCP” module listed under module admin…

so i guess i either have to enable the ARI module in order to have access to the old UCP or live without one, right? Because when i upgraded it said there was no going back…

Thanks for your help.

I understand your focus is on centos, but all i did was follow the instructions and just want to ensure that i’m not screwing up my system!

One other quick note… when i click “check online” in module admin, it “times out” and all i see at the top of the page is “Module Administration”, no css formatting or anything, OR a blank page. not sure if that’s a hint as to what has happened during this upgrade…

Check online and download it. Go to module admin. Check online. Then download and install UCP. You don’t need to use the old ARI. It’s just not an automated process getting it because its a module, just like any other.

You need to upgrade framework. The PIs are waaaaay to slow.

Go to the CLI:

amportal a ma upgrade framework

Thanks. See my comment in the other threat i just made, seems to be OK now and i can get to the online section where i can download and install the userman and ucp.


I installed the software according to the Ubuntu 14.04 instructions. The UCP module IS installed according the module administration (12.0.0beta34 stable), and there is a symlink in the root of the installation which points to the UCP location. However, the menu-linked URL doesn’t work:

The direct link works:

So I created a new symlink in /var/www/ and it works. The symlink created by the installation didn’t work. FWIW

sorry to hear that but the symlink works on thousands of other systems.

Actually your message is confusing. Does the symlink work or not. You have a different site prefix (freepbx) which can mess up the button but that’s all. You should have access at “freepbx/ucp”

No, the symlink I created is one folder ABOVE the freebpx folder. That’s where it needs to be to work. Weird.