Simple Machines Community Forum

SMF Support => SMF 2.0.x Support => Topic started by: VALLEYSBOY on September 01, 2020, 09:38:30 AM

Title: fatal error on upload 2.017
Post by: VALLEYSBOY on September 01, 2020, 09:38:30 AM
Hi, i have contacted my host several times about this, i am at 25% install i click for next stage and get fatal error, my host says it is : " You'll need to try some things to fix the issue. This thread here appears to have some relevant information on the problem:

https://github.com/SimpleMachines/SMF2.1/issues/5504

This is definitely a coding issue with your setup, not an issue with the server or web space. "

can you plz advise me, thanks for your time, Gareth.
Title: Re: fatal error on upload 2.017
Post by: shawnb61 on September 01, 2020, 11:01:15 AM
What's the error?

Php version?

Mysql version?

Title: Re: fatal error on upload 2.017
Post by: VALLEYSBOY on September 01, 2020, 11:19:24 AM
Hi, its on mysql, i am using cuteftp via binary upload  :)
Title: Re: fatal error on upload 2.017
Post by: shawnb61 on September 01, 2020, 12:25:47 PM
What is the specific error message you get when it fails?

To help, we also need to know the version of php - it will be a number, e.g., 7.3?

Same with mysql - to help, we need to know the version, e.g., 8.0?

If you don't know the versions, your host should be able to tell you. 

Or, you can use a tool like phpinfo, which is very handy:
https://wiki.simplemachines.org/smf/What_is_a_phpinfo()_file

Title: Re: fatal error on upload 2.017
Post by: shawnb61 on September 01, 2020, 12:47:31 PM
If you are running mysql 8.0 - we are seeing two issues:

UTF8 issue.  Early indications are that SMF will run on mysql8, but you must check the "Use UTF-8 as default character set" during the install.  Otherwise you get several errors.

DB connection issue.  This is actually due to the lack of support of mysql 8 with some (most... ::)) php versions.  The installer will tell you"Cannot connect to the database server with the supplied data.".  This can happen when you have mysql8 and a version of php <7.4, and your DB user is using an authentication plugin other than 'mysql_native_password'.  To fix this, you need to change the 'authentication plugin' for the database user you are using via this command:
ALTER USER mydbuser IDENTIFIED WITH mysql_native_password BY 'mypassword';

If you don't know how to do so, or don't have access, your host must do this for you. 

Title: Re: fatal error on upload 2.017
Post by: VALLEYSBOY on September 01, 2020, 02:09:38 PM
Hi there, many thanks for your time and effort, error reads : Fatal error: Uncaught Error: Call to undefined function db_fatal_error() in /var/www/vip3/sites/vip8080901/httpd/htdocs/Sources/Subs-Db-mysql.php:807 Stack trace: #0 /var/www/vip3/sites/vip8080901/httpd/htdocs/Sources/Subs-Db-mysql.php(36): SMF_DB_MySQLi->initiate('localhost', '', 'xxx', 'xxx', 'xxx_', Array) #1 /var/www/vip3/sites/vip8080901/httpd/htdocs/install.php(369): smf_db_initiate('localhost', '', 'xxx', 'xxx', 'xxx_', Array) #2 /var/www/vip3/sites/vip8080901/httpd/htdocs/install.php(906): load_database() #3 /var/www/vip3/sites/vip8080901/httpd/htdocs/install.php(138): ForumSettings() #4 {main} thrown in /var/www/vip3/sites/vip8080901/httpd/htdocs/Sources/Subs-Db-mysql.php on line 807
ill try get the answers for your other questions asp, thankyou again for your continued help :)

php is : Apache
Database client version: libmysql - mysqlnd 5.0.12-dev - 20150407 - $Id: 3591daad22de08524295e1bd073aceeff11e6579 $
PHP extension: mysqliDocumentation curlDocumentation mbstringDocumentation
PHP version: 7.2.33

um i think im wrong on this bit mysql :Server: Localhost via UNIX socket
Server type: MySQL
Server connection: SSL is not being used Documentation
Server version: 5.7.29-log - MySQL Community Server (GPL)
Protocol version: 10
User: c1215_cast@localhost
Server charset: UTF-8 Unicode (utf8)

(shawnb61 edited out password, etc...)
Title: Re: fatal error on upload 2.017
Post by: shawnb61 on September 01, 2020, 03:56:45 PM
Well it's not mysql 8.0, so there goes that theory...  What is interesting is that it looks like it connected, but failed on the subsequent select db.

So... 

Could you figure out what privileges that db user has?  Is the user granted privileges for that DB?  I suspect a gap there somewhere.

Some notes here:
https://wiki.simplemachines.org/smf/SMF2.0:Requirements_and_recommendations

If nothing turns up the review of privileges, we need to get better connection error info...

Title: Re: fatal error on upload 2.017
Post by: VALLEYSBOY on September 01, 2020, 04:30:45 PM
sheesh !! :) ok um i will try tomorrow now, um just for history sake, ive never had any issues with smf before, so i will get back to you asp, many thanks, this is the zip im using just in case ?  Gareth.
Title: Re: fatal error on upload 2.017
Post by: VALLEYSBOY on September 02, 2020, 11:13:46 AM
Quote from: shawnb61 on September 01, 2020, 12:47:31 PM
If you are running mysql 8.0 - we are seeing two issues:

UTF8 issue.  Early indications are that SMF will run on mysql8, but you must check the "Use UTF-8 as default character set" during the install.  Otherwise you get several errors.

DB connection issue.  This is actually due to the lack of support of mysql 8 with some (most... ::)) php versions.  The installer will tell you"Cannot connect to the database server with the supplied data.".  This can happen when you have mysql8 and a version of php <7.4, and your DB user is using an authentication plugin other than 'mysql_native_password'.  To fix this, you need to change the 'authentication plugin' for the database user you are using via this command:
ALTER USER mydbuser IDENTIFIED WITH mysql_native_password BY 'mypassword';

If you don't know how to do so, or don't have access, your host must do this for you.

Hi, i have messaged my host with theser details, when they reply i will ask about permissions, if all this fails ? would you allow me to pm you plz ? Gareth.
Title: Re: fatal error on upload 2.017
Post by: shawnb61 on September 02, 2020, 11:16:52 AM
Yes, no problem.
Title: Re: fatal error on upload 2.017
Post by: VALLEYSBOY on September 02, 2020, 12:08:31 PM
Hi, thankyou for allowing me to pm you :), 1st off though i am with freeola never had any issues uploading smf before, there reply to me sending them your txt on " to fix " there reply reads as : " They've basically asked you to change something that's already set. This is not the issue. We checked the logs, and it looks like whatever you are trying to upload is not submitting the user name and database name correctly (they should be the same).

According to our systems team, you should be able to start the install again and ignore any warnings at the beginning. It looks like it should install correctly if you drop the current tables from the database and reinstall. "
Title: Re: fatal error on upload 2.017
Post by: shawnb61 on September 02, 2020, 12:15:07 PM
What a terribly unclear message.

Sounds like they want you to clear out the tables & start over...  I'd reload the files, too.  Start fresh.

Let's see if that works.  If it does, they caught & fixed something...

If it doesn't, then we'll make it cough up a better error msg.
Title: Re: fatal error on upload 2.017
Post by: VALLEYSBOY on September 02, 2020, 12:35:25 PM
Ok, i will clear db and reinstall smf, i posted the zip i was using, have i got the right one ? im just trying to think parts of the process if you get my meaning ?  " like me, the human error in picking "
Title: Re: fatal error on upload 2.017
Post by: shawnb61 on September 02, 2020, 12:52:51 PM
If you downloaded the 2.0.17 install from this site, yes, that's the correct one.

Yes, it normally just works.  Not sure yet what the issue is here.
Title: Re: fatal error on upload 2.017
Post by: VALLEYSBOY on September 02, 2020, 01:32:52 PM
Hi there, well Im in !!!! go figure !! like you say they must have done something :) may i now pm you plz ?
Title: Re: fatal error on upload 2.017
Post by: shawnb61 on September 02, 2020, 01:57:06 PM
They definitely did something...

Due to 8.0 issues reported, I have been experimenting with different deliberately broken accts to learn how it responds...  I actually saw that exact issue the other day - and tragically forgot which variant it was...   ::)

I think the only restriction on PMs is a minimum post limit?  Not sure.  It was probably a 10 post min?

Anyway, glad you're ok!