Invision Community 4: SEO, prepare for v5 and dormant account notifications Matt November 11, 2024Nov 11
Posted May 6, 20231 yr Webhost switched site to php8 from php7.4 which broke forums. Was running version 4.2 which was only compatible with php7 when I went to 8 just got a white screen. Switched back and it all worked fine. Reading around realized I needed a version of forums compatible with php8 so I upgraded and downloaded the files for a manual upgrade since I can't upgrade thru the admin panel. I ran the compatibility check and it reported no errors. Started manual upgrade and everything goes fine at first until I get the following error which seems to be related to the database? Need some help, I've tried retry and continue and both options reproduce this error and halt the upgrade. Edit: Also, I have no plugins Edited May 6, 20231 yr by CannonFolly spelling, note about plugins
May 6, 20231 yr Author Also not sure if this will help or not, but it points to this file in the upgrade directory and seems to reference line 58 which is highlighted in the attached image. Also attached message when visiting site since update is in progress Edited May 6, 20231 yr by CannonFolly
May 6, 20231 yr Author Error seems to be evolving. I left the page for a while, came back reloaded and went back thru. Did this several times eventually after some time it changed to the attached and is still stuck again. I also went and checked my database in phpmyadmin (I don't know what I'm doing, but trying to follow that log) The message reads like it is trying to modify the database and drop a column called pf_admin_only. However, that column does not exist in that specific table according to phpmyadmin
May 6, 20231 yr When you flashed back the 7.x PHP and restored your forum, it was OK. right? After downloading ips 4.7.9 files, and upload it, you should change php to 8.x and then run update.
May 6, 20231 yr Author Thanks for replying, Yes when I went back to php7.4 it was ok, no errors and functioning like normal. I then downloaded the files and manually uploaded them via SFTP. I also moved back to php8.1. After that I started the upgrade and this is when I encountered the message. I also checked that compatibility file again before starting the upgrade and everything was green as shown in the first image.
May 6, 20231 yr Open your PhPMyAdmin - your database, open menu SQL Copy the last line in the red message, and paste in Then Go. Once done, repeat site/admin/upgrade
May 6, 20231 yr Author I get the following error in phpmyadmin Edit: Also, not sure if this is related, but any reason why my database backups vary in size so much? There were no additional posts/uplaods/etc... to my knowledge. I haven't restored any of those backups btw. Also after query failed same error persists between some of those dates. Edited May 6, 20231 yr by CannonFolly Edit for additional context on database size?
May 6, 20231 yr Try this: In this command, replace DROP with ADD This will create the missing column, then upgrader will successfully remove it. I.e. After successfully creating it, run upgrader
May 6, 20231 yr Author Something about my syntax is wrong: ALTER TABLE `ibf_core_pfields_data` ADD COLUMN `pf_admin_only`; Reports: Error SQL query: Copy ALTER TABLE `ibf_core_pfields_data` ADD COLUMN `pf_admin_only`; MySQL said: Documentation #1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1 I tried changing the apostrophes as well
May 6, 20231 yr Author Oh dear, it's evolving further. So that query worked and then that specific error went away on the upgrade, but it brought up a new one now. How screwed up is my database!?!?? Don't really get it since it was working fine on php7.4 This one says there is a duplicate entry. I don't see this specific table in phpmyadmin. I see the table, but without the "PRIMARY" at the end. Forgot the error message Edited May 6, 20231 yr by CannonFolly
May 6, 20231 yr Author The command went thru and inserted 1 row, but the same error persists Table after query:
May 6, 20231 yr Author I went to that upgrade file and then found those lines around 160 foreach ( array( 'new_reg_notify' => 'core_NewRegComplete', 'spm_notify' => 'core_Spammer', 'error_notify_level' => 'core_Error' ) as $settingKey => $notificationKey ) { if ( \IPS\Settings::i()->$settingKey ) { $member = \IPS\Member::load( \IPS\Settings::i()->email_in, 'email' ); if ( $member->member_id ) { \IPS\Db::i()->insert( 'core_acp_notifications_preferences', array( 'member' => $member->member_id, 'type' => $notificationKey, 'view' => 1, 'email' => 'always' ) ); } } }
May 6, 20231 yr Author Error persists, I also tried to change "core_NewVersion" to something like "core_4.7" and the error also persisted
May 6, 20231 yr Author Ok, I may have briefly clicked into the wrong table and got into "ibf_core_acp_notifications" instead of ibf_core_acp_notifications_preferences" briefly Would you mind double checking your ibf_core_acp_notifications and comparing it to mine to make sure I didn't remove anything I shouldn't? I went back and made my table look like yours for the Preferences version and it got rid of that error and moved onto another one. This table looks like this for me:
May 6, 20231 yr Author Ok I have a quick update. I went thru that table all the rows and got to the very end. I deleted the favicon row (bye my little icon) and then it threw another one for a favicon share one. I deleted that too. Then the favicon error message came back and I deleted it again. This has let the upgrade proceed a little more. It's currently going thru "Upgrading Database" so fingers crossed. Well that success was rather short lived... now I'm just sad 😞