Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Vanilla 2 Upgrading Tips

TimTim Vanilla Staff
edited January 2011 in Vanilla 2.0 - 2.8
Upgrading software can often be frustrating and there are always ways to make things go more smoothly. I'm going to be compiling a list of tips and tricks for completing Vanilla upgrades (as discovered by you guys, our community) in this thread.

Start posting your ideas :)

Before you make any changes...

  1. Back up your database
  2. Back up your conf/config.php

The upgrade process

  1. If you can, instead of simply copying the new files over the old files, delete your original files first (everything except conf/, cache/, uploads/, custom themes/and custom plugins/ and *then* copy the news files. This will ensure that any files we've removed from Vanilla in the updated version will not stick around in your installation.

If you've just upgraded Vanilla 2...

  1. Delete all the .ini files in your cache/ folder
  2. Run the /utility/update database update script

/utility/update

Running /utility/updateis pretty simple, but we often find people getting extremely confused. I'm going to explain how Vanilla URLs work here. Please read carefully.

If you're reading this, your browser's address bar has the following in it:
http://www.vanillaforums.org/discussion/12740/vanilla-2-upgrading-tips

Lets break that URL into its constituent parts

The Scheme:
http://
It should be pretty obvious what this is.

The Domain:
www.vanillaforums.org
This is the domain on which your forum is installed.

The Webroot:
http://www.vanillaforums.org/
This is the hardest one to understand. On vanillaforums.org, we've installed the forum at the topmost level of the web server's document root, so there are no additional folders in the URL. Lets say, however, that we installed Vanilla into a subfolder on our web server, and lets say we called that folder "myforum/". Now the web root would be: http://www.vanillaforums.org/myforum/. Basically, when in doubt, the web root is the shortest URL that gets you to the discussions list.

The Path:
discussion/12740/vanilla-2-upgrading-tips
This is the "request" that Vanilla is processing for you. In this case, if we converted the path to pseudo English, it would sound something like: "give me the discussion with id number 12740". The title part is optional, and is only there to make links look nicer and to improve user experience and search engine optimization.

Now, back to our instructions for accessing "/utility/update"

"Navigate to the page in your forum that updates your database (this will not work if you did not sign in as UserID = 1): www.yourdomain.com/path/to/vanilla/utility/update"

"Navigate to the page in your forum" - This tells us to start with the Webroot. Cool, so right now our URL looks like this:
http://www.vanillaforums.org/

"that updates your database" - This is filler text, ignore it. It simply describes the page you are about to visit. URL still looks the same as before:
http://www.vanillaforums.org/

"(this will not work if you did not sign in as UserID = 1)" - This tells us to be logged in as the ORIGINAL CREATOR ACCOUNT of the forum. This is the user your created DURING THE INSTALL PROCESS. URL still looks the same, but we should now be logged in as the primary admin.
http://www.vanillaforums.org/

"www.yourdomain.com/path/to/vanilla/" - This is a common way of specifying URLs whose beginning is unknown to the writer. When we write "/path/to" it is a way of saying "the fully qualified path to ". This is basically a reiteration of the first part, where we say "Navigate to the page in your forum". URL stays the same.
http://www.vanillaforums.org/

"utility/update" - And now we just tack this on the end of our URL:
http://www.vanillaforums.org/utility/update

And that's it! If you did everything correctly, you should get a page that says "Success"!

Vanilla Forums COO [GitHub, Twitter, About.me]

Tagged:
«134

Comments

  • edited August 2010
    I assume you also don't want to delete themes/ when you upgrade. Anyone with a custom theme would be in trouble if they deleted that folder!
  • What about utility/structure?
  • TimTim Vanilla Staff
    What about utility/structure?
    Good idea, thanks.

    Vanilla Forums COO [GitHub, Twitter, About.me]

  • When I click "Run structure & data scripts" I get "The structure was successfully executed." and everything looks ok.

    When I click "rescan" it brings up all the same stuff from "The following structure changes are required for your database." over and over again everytime I run it and rescan it so it looks like it isn't making any changes.
  • TimTim Vanilla Staff
    There are a couple of things in there right now which will always come up. We're working on new rules that don't do that.

    Vanilla Forums COO [GitHub, Twitter, About.me]

  • When I click "Run structure & data scripts" I get "The structure was successfully executed." and everything looks ok.

    When I click "rescan" it brings up all the same stuff from "The following structure changes are required for your database." over and over again everytime I run it and rescan it so it looks like it isn't making any changes.
    @Tim So are we right to assume the script was successful
  • TimTim Vanilla Staff
    yup

    Vanilla Forums COO [GitHub, Twitter, About.me]

  • Any idea what I'm doing wrong? I followed all your instructions, but when I try to open utility/structure it gives me this error

    Parse error: syntax error, unexpected ',', expecting '(' in /nfs/c06/h04/mnt/95421/domains/talkvancouver.ca/html/bootstrap.php on line 64
  • RaizeRaize ✭✭
    edited September 2010
    deactivating all plugins didn't help.. this sucks, my forum was off to such a good start :(
  • TimTim Vanilla Staff
    Running PHP4 by accident?

    Vanilla Forums COO [GitHub, Twitter, About.me]

  • Yes that was it! I came here to break the news but you beat me to it lol. All is well once again.

    Thanks for the response Tim, I wasn't expecting anyone to be around at this time :)

    The weird thing is that the setting changed from PHP5 to PHP4 on it's own somehow (after I uploaded the new files to the server).
  • Added to the upgrade documentation and unannouncing.
  • edited January 2011
    After deleting and uploading the directories described above, I'm stuck with a 500 error when I try to go to /utility/structure and a BONK when I try to go to my homepage. This is so depressing...

    (I'm trying to upgrade from 2.0.14 to 2.0.17)
  • TimTim Vanilla Staff
    edited January 2011
    Add/change this to/in your config:
    $Configuration['Garden']['Errors']['MasterView'] = 'deverror.master.php';
    Then go to the homepage and tell me what the error is.

    Vanilla Forums COO [GitHub, Twitter, About.me]

  • @Tim: Thanks for the quick response. Here's what I get:

    Fatal Error in Gdn_Database.Query();
    Unknown column 'c.TreeRight' in 'field list'

    Need more details?
  • TimTim Vanilla Staff
    Try visit /utility/update
    on your forum

    Vanilla Forums COO [GitHub, Twitter, About.me]

  • This again: Error 500 - Internal server error

    Is it file permissions or something?
  • Hello. Is anybody else discussing this issue (one similar to mine) on a more appropriate page?
  • TimTim Vanilla Staff
    Internal Server Error is just a polite phrase that means "Check your webserver error log, something bad happened"

    Vanilla Forums COO [GitHub, Twitter, About.me]

  • Right. I understand the 500 error, but what about the database error feedback that Vanilla gave me? I would like to know if this is a bug that needs to be fixed or if I have done something wrong. Here's more complete:

    Fatal Error in Gdn_Database.Query();
    Unknown column 'c.TreeRight' in 'field list'
    select c.Name as `Name`, c.CategoryID as `CategoryID`, c.TreeRight as `TreeRight`, c.TreeLeft as `TreeLeft`, c.Depth as `Depth`, c.Description as `Description`, c.CountDiscussions as `CountDiscussions`, c.CountComments as `CountComments`, c.UrlCode as `UrlCode`, c.LastCommentID as `LastCommentID`, co.DateInserted as `DateLastComment`, co.InsertUserID as `LastCommentUserID`, cu.Name as `LastCommentName`, cu.Photo as `LastCommentPhoto`, co.DiscussionID as `LastDiscussionID`, d.Name as `LastDiscussionName` from GDN_Category c left join GDN_Comment co on c.LastCommentID = co.CommentID left join GDN_User cu on co.InsertUserID = cu.UserID left join GDN_Discussion d on d.DiscussionID = co.DiscussionID where c.AllowDiscussions = :cAllowDiscussions order by TreeLeft asc
This discussion has been closed.