News:

Wondering if this will always be free?  See why free is better.

Main Menu

Upgrade from 2.0.19 to 2.1.2 fails at 58%

Started by tsedgar, September 02, 2022, 01:00:36 PM

Previous topic - Next topic

tsedgar

Trying to upgrade from 2.0.19 to 2.1.2. No mods and removed all old themes. Tried it a couple times and it keeps failing at this point (58%). I have seen some say to just try the upgrade again so I thought of trying that but also thought I would check to see if anyone has any ideas.

I copied the details from the screen from my last attempt (#3). 2nd attempt shows some different info in the attached screenshot. This appears to be a new one as I searched for the errors and I don't find anything.

We are on PHP 7.4.

Executing database changes
Please be patient - this may take some time on large forums. The time elapsed increments from the server to show progress is being made.
Executing upgrade script 2 of 2.
Executing: "Aligning legacy column data" (61 of 71 - of this script)

Renaming table columns...done
Converting "log_online"...done
Implementing board redirects...done
Creating spider table...done
Removing a spider...done
Creating spider hit tracking table...done
Making some changes to spider hit table...done
Creating spider statistic table...done
Resetting settings_updated...done
Changing stats settings...done
Enable cache if upgrading from 1.1 and lower..done
Changing visual verification setting...done
Changing visual verification setting, again...done
Changing default personal text setting...done
Removing allow hide email setting...done
Ensuring stats index setting present...done
Ensuring forum width setting present...done
Replacing old calendar settings...done
Deleting old calendar settings...done
Adjusting calendar maximum year...done
Adding advanced signature settings...done
Updating spam protection settings...done
Adjusting timezone settings...done
Checking theme layers are correct for default themes...done
Adding index to log_notify table...done
GDPR compliance settings...done
Creating "custom_fields" table...done
Adding search ability to custom fields...done
Fixing default value field length...done
Enhancing privacy settings for custom fields...done
Checking display fields setup correctly...done
Adding new custom fields columns...done
Creating "log_digest" table...done
Adding digest option to "members" table...done
Creating "log_packages" table...done
Adding extra "log_packages" columns...done
Changing URL to SMF package server...done
Creating "mail_queue" table...done
Adding new mail queue settings...done
Change mail queue indexes...done
Adding type to mail queue...done
Creating "log_reported" table...done
Creating "log_reported_comments" table...done
Adding moderator center permissions...done
Adding moderation center preferences...done
Creating member notices table...done
Creating comments table...done
Adding user warning column...done
Ensuring warning settings are present...done
Creating "log_group_requests" table...done
Adding new membergroup table columns...done
Creating "group_moderators" table...done
Altering attachment table...done
Adding file hash...done
Populate the attachment extension...done
Updating thumbnail attachments JPG...done
Updating thumbnail attachments PNG...done
Calculating attachment mime types...done
Creating "approval_queue" table...done
Adding approved column to attachments table...done
Adding approved column to messages table...done
Adding unapproved count column to topics table...done
Adding approved column to topics table...done
Adding approved columns to boards table...done
Adding post moderation permissions...done
Adding columns to log_errors table...done
Updating error log table...done
Creating Scheduled Task Table...done
Populating Scheduled Task Table...done
Adding the simple machines scheduled task...done
Deleting old scheduled task items...done
Moving auto optimise settings to scheduled task...done
Creating Scheduled Task Log Table...done
Adding new scheduled task setting...done
Setting the birthday email template if not set...done
Creating "permission_profiles" table...done
Adding profile columns to boards table...done
Adding profile columns to board permission table...done
Cleaning up some 2.0 Beta 1 permission profile bits...done
Migrating old board profiles to profile system...done
Removing old board permissions column...done
Check the predefined profiles all have the right permissions...done
Adding inherited permissions...done
Make sure admins and moderators don't inherit...done
Deleting old permission settings...done
Removing old permission_mode column...done
Adding column to hold the boards being ignored ...done
Purge flood control ...done
Adding advanced flood control ...done
Sorting out flood control keys ...done
Adding guest voting ...done
Implementing admin feature toggles...done
Adding advanced password brute force protection to "members" table...done
Add the columns and the keys to log_actions ...done
Add the user log...done
Update the information already in log_actions...done
Creating repository table ...done
Add in the files to get from Simple Machines...done
Ensure that the table has the filetype column...done
Set the filetype for the files...done
Ensure that the files from Simple Machines get updated...done
Adding personal message rules table...done
Adding new message status columns...done
Set the new status to be correct....done
Adding personal message tracking column...done
Adding personal message tracking column...done
Adding Open ID Association table...done
Adding column to hold Open ID URL...done
Creating subscriptions table...done
Creating log_subscribed table...done
Clean up any pre-2.0 mod settings..done
Clean up any pre-2.0 mod settings (part 2)..done
Confirming paid subscription keys are in place ...done
Adding scheduled task...done
Adding pruning option...done
Adding restore from recycle feature...done
Changing field_options column to a larger field type...done
Changing ignore_boards column to a larger field type...done
Changing event title column to a larger field type...done
Changing holidays title column to a larger field type...done
Adding reset poll timestamp and guest voters counter...done
Fixing guest voter tallys on existing polls...done
Changing all tinytext columns to varchar(255)...done
Adding column that stores the PM receiving setting...done
Enable the buddy and ignore lists if we have not done so thus far...done
Add new security settings for attachments and avatars...done
Add other attachment settings...done
Checking for "babylon" and removing it if necessary...done
Installing new smiley sets...done
Adding index member_started...done
Adding index last_message_sticky...done
Adding index board_news...done
Adding index on total_time_logged_in...done
Adding index on id_theme...done
Dropping index on real_name(30) ...done
Adding index on real_name...done
Dropping index member_name(30)...done
Adding index on member_name...done
Adding index id_member_msg...done
Adding index current_topic...done
Adding index related_ip...done
Adding index on attachment_type...done
Removing index on hits...done
Adding email address and member ip columns...done
Moving to next script file...done
Updating old values...done
Changing default values...done
Removing all karma data, if selected...done
Emptying error log, if selected...done
Adding login history...done
Copying the current package backup setting...done
Copying the current "allow users to disable word censor" setting...done
Converting collapsed categories...done
Parsing board descriptions and names...done
Dropping "collapsed_categories"...done
Adding new "topic_move_any" setting...done
Adding new "enable_ajax_alerts" setting...done
Adding new "alerts_auto_purge" setting...done
Adding new "minimize_files" setting...done
Collapse object...done
Adding new "DEFAULTMaxListItems" setting...done
Adding new "loginHistoryDays" setting...done
Enable some settings we ripped from Theme settings...done
Adding new "httponlyCookies" setting...done
Adding new "samesiteCookies" setting...done
Disable Moderation Center Security if it doesn't exist...done
Disable Moderation Center Security if it doesn't exist...done
Adding new profile data export settings...done
Adding settings for marking boards as read...done
Adding more space to the mime_type column...done
Converting legacy attachments...done
Note attachment conversion complete...done
Fixing invalid sizes on attachments...done
Fixing attachment directory setting...done
Adding new columns to log_group_requests...done
Adjusting the indexes for log_group_requests...done
Adding support for tag in package manager...done
Adding support for package hashes...done
Adding support for validation servers...done
Add Package Validation to Downloads Site...done
Ensure The Simple Machines Customize Site is https...done
Add validation to Simple Machines Customize Site...done
Altering the session_id columns...done
Adding new columns to topics ...done
Adding a new column "callable" to scheduled_tasks table...done
Adding new scheduled tasks...done
Adding a new task-related setting...done
Remove old tasks added by modifications...done
Adding the new table...done
Adding new columns to boards...done
Adding the boardindex_max_depth setting...done
Removing manage_boards permission...done
Adding new columns to categories...done
Adding the count to the members table...done
Adding the new table for alerts...done
Adding alert preferences...done
Upgrading post notification settings...done
Dropping old notification fields from the members table...done
Creating alert prefs for watched topics...done
Creating alert prefs for watched boards...done
Updating obsolete alerts from before RC3...done
Adding new column to log_topics...done
Fixing column name change...done
Altering mil_queue table...done
Altering the membergroup stars to icons...done
Renaming default theme...done
Fader time update...done
Adding the enableThemes setting...done
Setting "default" as the default...done
Check the current saved names for icons and change them to the new name...done
Clean up settings for unused themes...done
Adding new field_order column...done
Adding new show_mlist column...done
Insert fields...done
Add an order value to each existing cust profile field...done
Converting member values...done
Dropping old fields...done
Create the displayFields setting...done
Creating draft table...done
Adding draft permissions...done
Creating likes table...done
Adding likes column to the messages table. (May take a while)..done
Creating mentions table...done
Creating moderator_groups table...done
Deleting integration hooks...done
Fixing a deprecated option...done
Cleaning up the old Core Features page...done
Cleaning up old settings...done
Cleaning up old theme settings...done
Update the SM Stat collection...done
We no longer call on several files...done
But we do need new files...done
Creating qanda table...done
Moving questions and answers to the new table...done
Updating log_packages...done
Removing the old "view your own profile" permission...done
Updating the old "view any profile" permission...done
Removing the old notification permissions...done
Removing the send-topic permission...done
Removing the draft "autosave" permissions...done
Adding "profile_password_own"...done
Adding "view_warning_own" and "view_warning_any" permissions...done
Adding other profile permissions...done
Adding pm_labels table...done
Adding pm_labeled_messages table...done
Adding "in_inbox" column to pm_recipients...done
Moving label info to new tables and updating rules (May be slow!!!)...done
Adding "modified_reason" column to messages (May take a while)...done
Removing permissions guests can no longer have...done
Adding DEFAULT settings for the mail queue...done
Adding DEFAULT gravatar settings...done
Adding the "timezone" column to the members table...done
Converting time offset to timezone...done
Removing the "send_email_to_members" permission...done
Dropping the "hide_email" column from the members table...done
Dropping the "email_address" column from log_reported_comments...done
Removing the task and associated data...done
Removing the openid_uri column in the members table...done
Dropping the openid_assoc table...done
Removing related settings...done
Changing url column size in log_spider_hits from 255 to 1024...done
Changing url column in log_online from TEXT to VARCHAR(1024)...done
Adding the secret column to members table...done
Adding the backup column to members table...done
Force 2FA per membergroup...done
Add tfa_mode setting...done
Duplicates to messages_current_topic...done
Duplicate to topics_last_message_sticky and topics_board_news...done
Add columns to ban_items...done
Convert data for ban_items...done
Create new index on ban_items...done
Dropping columns from ban_items...done
Remove the old ip column...done
Add the new one...done
Delete old column log banned ip...done
Add the new log banned ip...done
Delete old log errors ip column...done
Add the new ip columns to log errors...done
Add the ip index for log errors...done
Rename old ip columns on members...done
Add the new ip columns to members...done
Create an ip index for old ips...done
Initialize new ip columns...done
Convert member ips...done
Convert member ips2...done
Remove the temporary ip indexes...done
Remove the old member columns...done
Rename old ip column on messages...done
Add the new ip column to messages...done
Create an ip index for old ips...done
Initialize new ip column...done
Convert ips on messages...done
Remove the temporary ip indexes...done
Drop old column to messages...done
Add the index again to messages poster ip topic...done
Add the index again to messages poster ip msg...done
Prep floodcontrol...done
Add the new floodcontrol ip column...done
Modify log_type size...done
Create primary key for floodcontrol...done
Delete the old ip column for log online...done
Add the new ip column for log online...done
Drop old ip column for reported comments...done
Add the new ip column for reported comments...done
Drop old ip columns for member logins...done
Add the new ip columns for member logins...done
Changing the "profile_other" permission to "profile_website"...done
Upgrading pm notification settings...done
drop column pm_email_notify on table members...done
Add start_time end_time, and timezone columns to calendar table...done
Update cal_maxspan and drop obsolete cal_allowspan setting...done
Add location column to calendar table...done
Update the max year for the calendar...done
Adding various calendar settings...done
Update the members' languages...done
Add Index for messages likes...done
Updating board_permissions...done
Updating log_digest id_topic...done
Updating log_digest id_msg...done
Updating log_reported...done
Updating log_spider_hits...done
Updating members new_pm...done
Updating members pm_ignore_list...done
Updating password_salt...done
Updating member_logins id_member...done
Updating member_logins time...done
Updating pm_recipients is_new...done
Updating pm_rules id_member...done
Updating polls guest_vote...done
Updating polls id_member...done
[b]Error!
Out of range value for column 'id_member' at row 3
[/b]

This is from attempt #2. Above is from attempt #3.
You cannot view this attachment.

Sir Osis of Liver

It's having a problem with 3rd row in smf_polls table.  Can you post a screenshot of the table?
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

tsedgar

Quote from: Sir Osis of Liver on September 02, 2022, 01:14:10 PMIt's having a problem with 3rd row in smf_polls table.  Can you post a screenshot of the table?


It is empty. Mine shows as sm_polls. All my tables start with sm_. Just wanted to clarify that.

You cannot view this attachment.

Sir Osis of Liver

Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

tsedgar

Correct. I also see a backup_sm_polls and that is also empty. 1KB total size.

Sir Osis of Liver

You can try replacing sm_polls with a clean 2.0.19 table (attached), then rerun upgrade.  Don't forget to change the prefix from smf_ to sm_

Gotta go ............
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Doug Heffernan

Can you click the structure tab for the table in question, make a screenshot and post it here?

This error usualy happens when data a particular field is storing doesn't fit. In this case a number might be too large.

tsedgar


tsedgar

So I created a fresh 2.0.19 forum and db. I did the 2.1.2 upgrade on that and it flew through with no issues. Our forum has been around for awhile (I see messages back to 2007) and has gone through a number of upgrades so far. I am not sure what version it started with as I have only been working on the website for 4 years.

tsedgar

I am also noticing tables with similar names but without the sm_ or smf_ prefixes. I would assume this came from the many upgrades based on having this active for 15+ years. Am I correct in my thinking and this is likely causing the issues when I try to go from 2.0.19 to 2.1.2?

You cannot view this attachment.You cannot view this attachment. 

tsedgar

I just realized I forgot to add the URL - it is www.carboyclub.com/forum [nofollow]. You can get to the front page and some of the forums but members are given more access to more boards. I can provide a login, if needed. Would just need to get one setup first.

Doug Heffernan

Quote from: tsedgar on September 02, 2022, 04:22:05 PMI am also noticing tables with similar names but without the sm_ or smf_ prefixes. I would assume this came from the many upgrades based on having this active for 15+ years. Am I correct in my thinking and this is likely causing the issues when I try to go from 2.0.19 to 2.1.2?

Can you check the Settings.php file and see what value does the $db_passwd var have? That is the prefix that your forum 's database tables have.

tsedgar

#12
Quote from: Doug Heffernan on September 02, 2022, 04:36:21 PMCan you check the Settings.php file and see what value does the $db_passwd var have? That is the prefix that your forum 's database tables have.

So I checked settings.php. The $db_passwd has the db password. The db prefix for the old forum has no prefix listed.

$db_prefix = '';

I checked the other test forum I upgraded to 2.1.2 and it has the sm_ prefix.

$db_prefix = 'sm_';

Doug Heffernan

Quote from: tsedgar on September 02, 2022, 05:09:14 PMThe db prefix for the old forum has no prefix listed.

By the old forum, do you mean your current forum? If that is a yes, then the tables without prefix are the tables you need.

Quote from: tsedgar on September 02, 2022, 01:34:26 PMIt is empty. Mine shows as sm_polls. All my tables start with sm_. Just wanted to clarify that.

You have been looking at the wrong database all along. As per your post above:

Quote from: tsedgar on September 02, 2022, 05:09:14 PMI checked the other test forum I upgraded to 2.1.2 and it has the sm_ prefix.

Please make sure that you get all the tech details right when you post for help, otherwise it serves no purpose.

tsedgar

Yeah, my bad. I seldom get in and mess with the DB tables and never have needed to touch the SMF DB until now. With all the tables in the database, it didn't dawn on my to check the prefix.

So the polls table has some data in it and it could be a length issue. I think this poll is aged so I can likely find it and remove it. I will try that and see if that allows the upgrade to complete. Sorry for the runaround. SMF just works so my experience level with it is not at the same level as other aspects of our website, until now.

You cannot view this attachment.


Sir Osis of Liver

If you remove the _polls table you'll lose any polls that are on the forum.  What is the value for id_member in the third row?
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

tsedgar

I went in to the forum and looked and all the polls were more than 6 years old and nothing was still in use/relevant. The one causing the error was over 10 years old. I deleted it, backed things up and started the upgrade again. This time it made it through without error. Opened the new forum and love the fresh look.

I appreciate the guidance/direction. Been working in SMF for a few years but this was my first real foray into the SMF DB but I definitely know it better than I did. You guys got me to the right place for sure.

Doug Heffernan

Glad to see that you got your forum upgraded. Marking this as solved.

Advertisement: