FreePBX | Register | Issues | Wiki | Portal | Support

Will Mysql 8+ be supported with Freepbx15?


#1

Will Mysql 8+ be supported with Freepbx15?

I attempted to install Freepbx 15 on a system running mysql 8 and the freepbx installer just hangs:

./install -n
Assuming you are Database Root
Checking if SELinux is enabled...Its not (good)!
Reading /etc/asterisk/asterisk.conf...Done
Checking if Asterisk is running and we can talk to it as the 'asterisk' user...Yes. Determined Asterisk version to be: 13.18.3
Preliminary checks done. Starting FreePBX Installation
Checking if this is a new install...Yes (No /etc/freepbx.conf file detected)
Database Root installation checking credentials and permissions..

It seems mysql 8 is likely the cause from what I have read.

Found the line here:

freepbx/installlib/installcommand.class.php changes to (around line 421):

Was wondering if there was plans to support mysql 8 in Freepbx 15 or not until a later version. Was mostly just testing latest software packages, for now will go back to mysql 5.7. Thanks for any response.


(Andrew Nagy) #2

It’s not clear what the error is??


#4

Yes it has something to do with mysql8 by default install not using root with empty password.

so I logged into mysql directly:

sudo mysql

CREATE DATABASE asterisk;
CREATE DATABASE asteriskcdrdb;
CREATE USER 'asterisk'@'localhost' IDENTIFIED BY 'ainxi3asgefs2yu5DbsSgbf6uTy7';
GRANT ALL PRIVILEGES ON asterisk.* TO 'asterisk'@'localhost';
GRANT ALL PRIVILEGES ON asteriskcdrdb.* TO 'asterisk'@'localhost';
EXIT;

EDIT (removed the -n from the installer):

./install

most questions just press enter for defaults, except the below two questions:

Database username [root]: asterisk
Database password: ainxi3asgefs2yu5DbsSgbf6uTy7

For anyone else that finds this, ainxi3asgefs2yu5DbsSgbf6uTy7 is just an example, obviously make your own.

If your on linux, or have the openssl package, here is a neat way to generate a 32 digit password for use with mysql:

openssl rand -base64 32 | tr -dc _A-Z-a-z-0-9 | head -c 32 ; echo

After those couple things the installer went just fine :slight_smile:


(Andrew Nagy) #5

Did you actually look at the installer? You can define --dbpass on the command line. You dont need to modify anything.

Furthermore if you run install without the -n option it would prompt you for that. Do you even know why you are typing -n? Or are you just doing it blindly copying it from a guide?

Please run --help on the installer before continuing any further.


#6

ouch, guess I deserve that for not looking for and reading the help.

I was just doing what had worked in previous installs was all, which was normally ./install -n

Thanks for the reply, checking out the --help now


(Andrew Nagy) #7

Sorry but it’s frustrating to know that the team of people I work with that spent hours/weeks/months designing and perfecting the installer was/is kind of just pointless when people just attach -n and instead go modify the installer without investigating why they are even attaching -n…

All of the install options are specifically tailored for non-distro machines. They are there for the community. So when I see the community not using them and just modifying the installer it’s just baffling.


#8

Aye! and I appreciate you pointing it out, its not just freepbx that I (and probably others) do that with. Often when your not sure what the problem is you just start digging in without actually stopping to read documentation/help of what might be the cause.

I removed freepbx and am trying the installer without the -n :slight_smile: after having read the --help


#9

worked like a charm, updated my previous post for anyone that find this.

Thanks @tm1000