Please select To the mobile version | Continue to access the desktop computer version
| |
| | |

CodersClub

 Forgot password?
 Register
Search
View: 249|Reply: 29
Collapse the left

[Fixed] MariaDb Installation error

[Copy link]

 India

Post time: 2018-5-19 12:26
| Show all posts |Read mode
Hi

I am not able to install discuz x 3.4

The error -

run_sql_error
SQL:CREATE TABLE ucenter_applications ( appid int(11) unsigned NOT NULL auto_increment, `type` varchar(32) NOT NULL default '', `name` varchar(255) NOT NULL default '', url varchar(255) NOT NULL default '', authkey varchar(255) NOT NULL default '', ip varchar(15) NOT NULL default '', viewprourl varchar(255) NOT NULL, apifilename varchar( 255 ) NOT NULL DEFAULT 'uc.php', charset varchar(16) NOT NULL default '', dbcharset varchar(16) NOT NULL default '', synlogin tinyint(1) NOT NULL default '0', recvnote tinyint(1) DEFAULT '0', extra text NOT NULL, tagtemplates text NOT NULL, allowips text NOT NULL, PRIMARY KEY (appid)) TYPE=MYISAM
Error:You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'TYPE=MYISAM' at line 1
Errno:1064

I read in the forums

Solution :
Search and Replace TYPE=MyISAM with ENGINE=MyISAM in all .sql files at install/data/ and uc_server/install/uc.sql

But still the same error.

I have mariadb on the hosting.

Please help

 Russia

Post time: 2018-6-5 21:02
| Show all posts
function v_compare() is placed in 3 files:
1) install/include/install_function.php
2) source/function/function_core.php
3) uc_server/model/base.php

Check if your revision is the latest.

 Russia

Post time: 2018-5-20 18:10
| Show all posts
It is not possible to get the same error, if you really changed SQL files!
Show your error message here.

 India

 Author| Post time: 2018-5-21 13:00
| Show all posts
Edited by 0tmy2 at 2018-5-21 13:29

I have rechecked the SQL files and it does not contain -  'TYPE=MYISAM' anywhere but still I get many errors in the end saying - Error:You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'TYPE=MYISAM' at line 1
Errno:1064


Is there any other source it reads a sql file from ? I deleted the source code. unzipped from official download from you guys , added the en package. Edited the sql files and the uploaded this.

Its still reading TYPE=MYISAM from where no idea.

Regards

Database server
  • Server: Localhost via UNIX socket
  • Server type: MariaDB
  • Server version: 10.1.31-MariaDB-cll-lve - MariaDB Server
  • Protocol version: 10
       
  •         Server charset:                    UTF-8 Unicode           (utf8)        
      

Web server
  • cpsrvd 11.62.0.42
  • Database client version: libmysql - 5.1.73
  • PHP extension: mysqli
      


 India

 Author| Post time: 2018-5-21 13:16
| Show all posts
Also in the error - SQL:CREATE TABLE ucenter_applications

in sql file it is uc_applications.

From where its reading those sql statments ?

Regards

 Russia

Post time: 2018-5-21 21:32
| Show all posts
I have found a bug in Discuz code.
It can not understand that MariaDB v.10.1 is greater than MySql v.4.1

I'm trying to fix the problem.
Wait please...

 India

 Author| Post time: 2018-5-22 13:58
| Show all posts
Edited by 0tmy2 at 2018-5-22 13:59

There are some hacks posted regards to this on official discuz forum

http://www.discuz.net/thread-3832258-1-1.html
http://www.discuz.net/thread-3613281-1-1.html
http://www.discuz.net/thread-3605344-1-1.html


But will like a proper bugfix , so it holds in place for anything related to database operations.

Regards

 Russia

Post time: 2018-5-22 20:47
| Show all posts
Nothing interested in the threads recommended

But I can offer my own solution

Try revision #808: Install: MariaDB compatibility

If installation will be ok, I will expand the solution to all the Discuz code.

 India

 Author| Post time: 2018-5-22 20:59
| Show all posts
I used those threads and was able to install discuz.

But I knew you will fix the code in the repo.

Let me test and give feedback.

Thank you

 India

 Author| Post time: 2018-5-22 21:19
| Show all posts
Edited by 0tmy2 at 2018-5-22 21:26

Hi

Still the same error -

Error:You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'TYPE=MYISAM' at line

Do I need to edit the .sql files to engine ? or it should have installed without any changes ?

Regards
Edit - does not matter if changed to engine in sql files. Same error

Also I think you will need to make changes on the following files also -

[tr][/tr]
[tr][/tr]
Source\class\db\db_driver_mysql.php
source\class\db\db_driver_mysqli.php
uc_client\lib\db.class.php
uc_server\lib\db.class.php
api\db\dbbak.php








if you make the fix only on installation file , it will install.

But when you try to install plugins or such db operations , it will still think it is less than 4.1 mysql , because the files in the above  quote will read it like that.


 Russia

Post time: 2018-5-22 22:04
| Show all posts
Still the same error

What the SQL query was wrong?
Do I need to edit the .sql files to engine ? or it should have installed without any changes ?

No changes required in SQL files!
You have to log in before you can reply Login | Register

Points Rules

Archive|Mobile|Dark room|CodersClub  

2018-6-20 02:59 GMT+3 , Processed in 0.108437 sec., 10 queries .

Powered by Discuz! X3.4

Release 20170801, © 2001-2018 Comsenz Inc.

MultiLingual version, Rev. 710, © 2009-2018 codersclub.org

Quick Reply To Top Return to the list