Web GUI is gone


(Mvogel4949) #1

Running an update from V13 to V14 everything came back except the GUI. apache is running and the schmoozecom.conf file is correct for port 80. The dashboard module is enabled. Any thoughts on how to get the GUI back?


(Communication Technologies) #2

What do you mean “gone”? Is there a chance your firewall (local or network) is blocking?


(Mvogel4949) #3

The GUI is also invisible locally


(Communication Technologies) #4

This is not descriptive. when you enter the URL into the browser, what happens?


(Mvogel4949) #5

Blank screen in Chrome. HTTP error page can’t be found in IE


(Communication Technologies) #6

Is there a chance your firewall (local or network) is blocking? Rebooting the PBX twice in a row will temporally disable the firewall.

Has you IP address changed?

Are you using an IP address or DNS entry for the PBX URL? If not using IP, what happens when you use the IP address?

http://IP.Address/admin/config.php


(Mvogel4949) #7

I’ve disabled the firewall module with no success


(Communication Technologies) #8

When you attempt to reach the site, are you seeing the connection via the network logs? OR the local Apache logs?


(Mvogel4949) #9

You may be on to something here. I found the http logs and see myself trying to access:

188.45.2:57601] PHP Warning:  include_once(/etc/freepbx.conf): failed to open stream: Permission denied in /var/www/html/admin/config.php on line 126, referer: http://98.103.0.115:58088/
[Wed Oct 07 08:48:35.279779 2020] [:error] [pid 12417] [client 66.188.45.2:57601] PHP Warning:  include_once(): Failed opening '/etc/freepbx.conf' for inclusion (include_path='.:/usr/share/pear:/usr/share/php') in /var/www/html/admin/config.php on line 126, referer: http://98.103.0.115:58088/
[Wed Oct 07 08:48:35.279856 2020] [:error] [pid 12417] [client 66.188.45.2:57601] PHP Fatal error:  Class 'FreePBX' not found in /var/www/html/admin/config.php on line 136, referer: http://98.103.0.115:58088/

(Communication Technologies) #10

Does /etc/freepbx.conf exist?

If both files above exist, does the asterisk user have the correct permissions to these files?


(Mvogel4949) #11

It does exist. Could the password be wrong?
<?php
// This file was generated at 2019-10-07T12:49:01+00:00

$amp_conf["AMPDBUSER"] = "freepbxuser";
$amp_conf["AMPDBPASS"] = "BVNzdZObU2Rn";
$amp_conf["AMPDBHOST"] = "localhost";
$amp_conf["AMPDBNAME"] = "asterisk";
$amp_conf["AMPDBENGINE"] = "mysql";
$amp_conf["datasource"] = "";

require_once “/var/www/html/admin/bootstrap.php”;

image


(Tom Ray) #12

SSH in and do fwconsole chown this could be related to bad ownership/group settings.


(Mvogel4949) #13

No luck with the chown. Reinstall apache?


(Mvogel4949) #14

It appears httpd is running with root permissions instead of asterisk, any thoughts on how to change the permission of httpd?

[root@localhost sbin]# ls -al httpd
-rwxr-xr-x 1 root root 523608 Apr  2  2020 httpd

(Dave Burgess) #15

I wouldn’t reinstall apache.

First, check the ‘/etc’ directory and make sure that the permissions are ‘rwxr-xr-x’. The last ‘r-x’ is "everyone can read the files in this directory and everyone can ‘cd’ to this directory. If the last triplet is ‘—’, no one but the owner can read the files. Should not be a problem, since the Asterisk user has already stored all of its files in there, but check it first.

Log into the console as ‘root’ and ‘su -m asterisk’. Once there, make sure you can read and edit the /etc/freepbx.conf file. If you can’t, the file perms are messed up. If you can, the permissions in the Apache Config files are messed up.

Next, ‘cd’ to the /etc/apache directory and type the followiing:

grep freepbx.conf `find . -type f`

This should lead you to the Asterisk config file for Apache. Make sure that the configuration stanza that’s set up for the “/etc” directory is correct so that you can read files from the “/etc” directory (and not just the “/etc/asterisk” directory) is correct. It’s possible that your config is set up to read from “/etc/asterisk” just fine, but can’t read the files in “/etc”.

Make sure your /etc/freepbx.conf file isn’t a ‘symlink’ (I don’t think it is, but ‘ls -al /etc/freepbx.conf’ will tell you for sure). Apache is usually configured to not allow symlinks to be opened, so verify that.

One other person recently had a strange permissions problem after an update - this could be a simple manifestation of the same thing.


(Mvogel4949) #16

First, check the ‘/etc’ directory and make sure that the permissions are ‘rwxr-xr-x’. The last ‘r-x’ is "everyone can read the files in this directory and everyone can ‘cd’ to this directory. If the last triplet is ‘—’, no one but the owner can read the files. Should not be a problem, since the Asterisk user has already stored all of its files in there, but check it first. - Permissions are correct

[root@localhost /]# su -m asterisk
bash: /root/.bashrc: Permission denied
bash-4.2$

is this correct?


(Dave Burgess) #17

Yeah - you just don’t have the ‘root’ user’s shell shortcuts. To verify your identity in the shell, type ‘who am i’ to get verification.


(Mvogel4949) #18

bash-4.2$ who am i
root pts/0 2020-10-07 11:59 (066-188-045-002.biz.spectrum.com)


(Dave Burgess) #19

Sorry - ‘whoami’ all one word.


(Mvogel4949) #20

I"m not as familiar with the bash prompt. I am the asterisk user. How do I go about doing this?

sudo /etc/freepbx.conf?