Jump to content

Recommended Posts

Posted

My forum is running on version 3.3. After the migration, it loads fine and I'm able to login and view topics, read PMs, etc. However, I cannot access ACP after entering my username and password. It shows the following message.

www.my-forum.com Driver Error
There appears to be an error with the database.
If you are seeing this page, it means there was a problem communicating with our database. Sometimes this error is temporary and will go away when you refresh the page. Sometimes the error will need to be fixed by an administrator before the site will become accessible again.

You can try to refresh the page by clicking here

I do not see the /uploads/logs folder to check for any error messages generated by IPB. The hosting provider tried changing to ea_5.6 versions, with all the MySQL addons but still doesn't work.

I just renewed my classic license for $40 (Haven't renewed since 2008 so I'm not up to date on the new terms, etc.) but it's not allowing me to submit a ticket to support. How do I get the option? Hope someone can help me. Thank you.

 

Posted

Ok, I found sql error log in the cache folder.

 

Date: Fri, 06 Oct 2023 02:19:29 +0000
 Error: 1064 - 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 'rows FROM ibf_sessions WHERE running_time > 1696555169' at line 1
 IP Address: 72.69.94.188 - /admin/index.php?adsess=e7a8276df23be0cc48516f61f108852c&
 ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 mySQL query error: SELECT count(*) as rows FROM ibf_sessions WHERE running_time > 1696555169
 .--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------.
 | File                                                                       | Function                                                                      | Line No.          |
 |----------------------------------------------------------------------------+-------------------------------------------------------------------------------+-------------------|
 | admin/sources/base/ipsController.php                           | [admin_core_mycp_dashboard].doExecute                                         | 306               |

Posted
7 minutes ago, TCWT said:

it's not allowing me to submit a ticket to support. How do I get the option?

Support for self-hosted clients is provided right here in this forum. It's currently after hours. While someone at Invision might happen to read this tonight, they usually aren't actively monitoring until they open in the morning.

At least it's running on the front end. I don't think it's going to be easy to upgrade from 3.3 to the latest release. You're gonna have to jump through some hoops.

Posted (edited)

Would support login to my server if needed? I thought I have to submit Email support ticket for that but it's not allowing me to in the Client Area.

I wasn't planning on upgrading the forum as it's using some hooks that haven't been updated in many years.

Well, my web host replied with this message:

This is another issue with your code being very old unfortunately, new versions of MySQL/MariaDB reserve the "rows" keyword and it cannot be used as an identifier in queries unless the keyword is quoted(https://mariadb.com/kb/en/reserved-words/). That query would need to be modified to SELECT count(*) as "rows" FROM ibf_sessions WHERE running_time > 1696555169 to work correctly.

I'm afraid there isn't anything we can do on our end to fix this, you will need to modify the code for your site.

I also wanted to add that recovery mode doesn't work after adding this to constants.php file.

<?php
define('RECOVERY_MODE',True);

Edited by TCWT
Posted

Support won’t login to your server and support for 3.X ended YEARS ago.  Off hand it sounds like when you moved servers you moved to a host that has a newer version of MySQL than what 3.3 supported. 

The 3.3.X line is 10+ years old and like 10 versions of PHP behind modern standards. 

I would HIGHLY recommend working with a 3rd party resource that specializes in legacy upgrades and move to an updated version. Otherwise IPS itself won’t be able to provide support. 

https://invisioncommunity.com/third-party/providers-directory/?advanced_search_submitted=1&content_field_231[4]=4&content_field_232[0]=0&content_field_232[1]=1

Posted (edited)

They don't offer any more support for the 3.x version. Also, the RECOVERY_MODE constant works only for 4.x, so it won't work for you on 3.3.

 

That said, your issue is that your MySQL (MariaDB) version is too new compared to the version required by the 3.3 version, and the "column name" rows throws an error because it's a reserved word now.

It can be changed to make it compatible, but I really suggest either downgrading your database version or updating the site to the latest 4.7 version. 🙄

Edited by teraßyte
Posted (edited)
5 minutes ago, teraßyte said:

They don't offer any more support for the 3.x version. Also, the RECOVERY_MODE constant works only for 4.x, so it won't work for you on 3.3.

 

That said, your issue is that your MySQL (MariaDB) version is too new compared to the version required by the 3.3 version, and the old column named rows throws an error because it's a reserved word now.

It can be changed to make it compatible, but I really suggest either downgrading your database version or updating the site to the latest 4.7 version. 🙄

I have no control over the database version as it's a shared host. 99% of the forum works. Heck, can't even get into ACP to perform any admin tasks and it would likely have issues with the new MySQL versions. It would be a major pita at this point. I just want a functioning forum, the version is fine the way it is.

Hope someone can tell me how to modify the code.

Edited by TCWT
Posted
14 minutes ago, TCWT said:

Hope someone can tell me how to modify the code.

Honestly, I don't even know where I have my 3.3 backup files to look at the code.

 

All I can tell you is that adding backticks to the name should allow you to make it work. Try replacing:

rows

in the query with:

`rows`

Since the error log above is not complete, I don't remember the session file location. You'll have to search for it.

 

That query throwing the error most likely isn't the only one. A few similar ones are probably around in the code, but searching a generic "rows" term would return tons of useless results. The only way is to fix the errors/queries as they come up. Anyway, we can't give you a simple "edit file X and Y to fix it". 😔

Posted

In file:

/admin/applications/core/modules_admin/mycp/dashboard.php

Find:

$online	= $this->DB->buildAndFetch( array( 'select' => 'count(*) as rows', 'from' => 'sessions', 'where' => "running_time > {$time}" ) );

Change to:

$online	= $this->DB->buildAndFetch( array( 'select' => 'count(*) as `rows`', 'from' => 'sessions', 'where' => "running_time > {$time}" ) );

Save and upload.

Posted
16 hours ago, DawPi said:

In file:

/admin/applications/core/modules_admin/mycp/dashboard.php

Find:

$online	= $this->DB->buildAndFetch( array( 'select' => 'count(*) as rows', 'from' => 'sessions', 'where' => "running_time > {$time}" ) );

Change to:

$online	= $this->DB->buildAndFetch( array( 'select' => 'count(*) as `rows`', 'from' => 'sessions', 'where' => "running_time > {$time}" ) );

Save and upload.

That worked! 🙂 Thanks so much, the community support is excellent.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...