HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Upgrading from 2.0.18b1 to 3.3

aalpataalpat New
edited April 2020 in Vanilla 3.x Help

Hello.

I've tried to upgrade from 2.0.18b1 to 3.3 and the hell broke. I've put at least 15-20 hours to find a solution but I couldn't. Can you please help me solve this problem? I've read and tried every possible solution that was recommended here but each of every one caused another problem. 

I am using a shared hosting with CPanel and PHPMyadmin. Domain is: http://forum.arduinoturkiye.com

I've tried (1):

  • I've installed a fresh v3.3 from CPanel application installer. I've checked that forum was working.
  • Export the CDN_Rules and CDN_Permission of the new db.
  • Delete the CDN_Rules and CDN_Permission of the old DB
  • Import CDN_Rules and CDN_Permission of the new DB to old DB
  • Edit the config file to show old DB
  • Visited /utility/structure "Permission Problem You don't have permission to do that." 
  • /utility/update give the message below

I have also changed roles and permission numbers to current ones.

I've tried (2)

  • I've installed v3.3 from scratch using Cpanel auto application installation. It was working.
  • Drop all of the tables in new DB
  • Import old DB to new DB without any change on config file


I've tried (3)

  • Wipe everything in the forum folder.
  • Upload the vanilla-core as a zip file. Extracted it.
  • Follow the installation steps but couldn't get into setup dashboard


Answers

  • R_JR_J Admin

    Not sure where you are stuck right now, but let me say that I'm impressed with the research you already did! So you are not able to run http://forum.arduinoturkiye.com/utility/structure that would help a lot.

    Looking at your forum right now shows an error about the column FullName in the GDN_Tag missing. Create it as varchar(100) and retry running /utility/structure

  • @R_J thank you for your reply and solid advice. After doing what you said, now I am able to see the http://forum.arduinoturkiye.com/utility/structure page. But not the http://forum.arduinoturkiye.com

    Here is what happened after adding FullName as varchar(100);

    • I get into utility/structure
    • I've seen the login, clicked forgot password. It sent me password reset email.
    • I've reset the password succesfully.
    • It redirects me to login screen, I've put in email and password
    • It says "Sorry permission denied" but (permission denied page SS is attached)
    • I am able to see the categories but not discussions (categories page view is attached)

    When I click discussions, it gives the same error as I try to get into forum.arduinoturkiye.com. Do you mind if I ask a little more help? I appreciate your time. Thank you again!



  • R_JR_J Admin

    As long as you haven't run /utility/structure, don't mind the error messages.

    Look at the GDN_User table. There is a column called IsAdmin or something like that. Change the value for your user to 1 to make that account a SuperAdmin. Then you should be able to log in and run /utility/structure

  • Thanks again, @R_J , you are doing a great favor to me!

    I did it, but it seems it did not recognize me as admin. But I've seen and recognize the email address that I've register as admin and requested password to it.

    • I've reset the password.
    • I logged in as admin.
    • I am able to see /utility/structure page. There I've seen "Database Structure Upgrades. Scan your database for changes."
    • I've clicked the "Scan" button
    • Seen the attached error page

    As you have done previously, I 've tried to understand this error:

    [message] 'Unknown column \'c.CountCategories\' in \'field list\''
    

    I think it is about ParentCategoryID but couldn't understand what to do with it. Does it mean "ParentCategoryID column is irrelevant with this version of Vanilla and I couldn't recognize it"? Is it so? What should I do with it?

    Thanks in advance.

  • R_JR_J Admin

    Does the GDN_Category table has a column CountCategories?

    It should have. The error message looks to me as if this column is missing.

    You can look up the type it should have in

    /applications/vanilla/settings/structure.php

  • @R_J, sorry for not replying your answer for a long time. I was dealing with Covid.

    I've add the CountCategories with the value "0" as it seen on /applications/vanilla/settings/structure.php.

    As I've try to login http://forum.arduinoturkiye.com, this time the error message is:

    [message] 'Unknown column \'w.Participated\' in \'field list\''
    

    I can login and see the "scan" button on /utility/structure. As I click it, the error message is the same as previous.

    [message] 'Unknown column \'c.CountCategories\' in \'field list\''
    

    I think it will goes on like this for hundreds of times until there is no difference between db structure of 2.0.18 and the 3.3. Can you teach me how to think to figure out the problem? I mean, where can I find all of these db structure differences so I can fix them all?

    Can you teach me or share me any resources on how to read error messages and their meanings?

    Thank you in advance.

  • R_JR_J Admin

    You can take a look at the files:

    /applications/dashboard/settings/structure.php

    /applications/vanilla/settings/structure.php

    /applications/conversations/settings/structure.php


    For the Participated column, you will find this code in the vanilla/settings/structure.php file (search all files for "Participated" and if there are more tables with the same column names, check your database which tables already are correct and which are not):

    $Construct->table('UserDiscussion');
    
    $ParticipatedExists = $Construct->columnExists('Participated');
    
    $Construct->column('UserID', 'int', false, 'primary')
       ->column('DiscussionID', 'int', false, ['primary', 'key'])
       ->column('Score', 'float', null)
       ->column('CountComments', 'int', '0')
       ->column('DateLastViewed', 'datetime', null)// null signals never
       ->column('Dismissed', 'tinyint(1)', '0')// relates to dismissed announcements
       ->column('Bookmarked', 'tinyint(1)', '0')
       ->column('Participated', 'tinyint(1)', '0')// whether or not the user has participated in the discussion.
       ->set($Explicit, $Drop);
    


    The code deals with the table "UserDiscussion" and it should be of the same type as the column "Bookmarked" (tinyint(1), default 0)

Sign In or Register to comment.