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.
Options

2.1 Roles & Permission not working properly

2

Comments

  • Options

    The porter script is not for updating, but porting.

    Always follow the documentation. Lesson learned.

    grep is your friend.

  • Options
    gohuntergohunter
    edited April 2014

    @x00 said:
    The porter script is not for updating, but porting.

    Always follow the documentation. Lesson learned.
    @x00 said:
    The porter script is not for updating, but porting.

    Always follow the documentation. Lesson learned.

    I thought I was just using it for changing format for vanilla format :pensive: Lesson learned...

  • Options

    Hi.

    I believe I have the same problem.

    I have use porter to export a vanilla 2.0.18 to vanilla 2.1.

    I am getting the same issue with the role ( get a bonk error ).

    Is there a way to fix this ?

    Tks

  • Options
    whu606whu606 I'm not a SuperHero; I just like wearing tights... MVP
    edited May 2014

    @Carlo_13‌

    One way to resolve this is to set up a clean install of 2.1, with a new database.

    Once it is set up, make sure you can change permissions.

    Assuming that is successful, use something like phpMyAdmin to export the GDN_Permission table from your clean install and import it into the 'old' database.

    As always, when working on a database MAKE A BACKUP FIRST before you try anything.

  • Options

    I have use porter to export a vanilla 2.0.18 to vanilla 2.1.

    There is your problem. Why didn't you follow the upgrade instructions?

    Porting is not the same as upgrading. If you are already using vanilla 2 there is no need to port.

    grep is your friend.

  • Options

    Stop using the porter to upgrade it is not for that.

    If you have to move the database, use mysql dump.

    grep is your friend.

  • Options

    @whu606 said:
    Carlo_13‌

    One way to resolve this is to set up a clean install of 2.1, with a new database.

    Once it is set up, make sure you can change permissions.

    Assuming that is successful, use something like phpMyAdmin to export the GDN_Permission table from your clean install and import it into the 'old' database.

    As always, when working on a database MAKE A BACKUP FIRST before you try anything.

    This is an unnecessary way to do it. It means start from scratch. You don't port to upgrade.

    grep is your friend.

  • Options
    LincLinc Detroit Admin

    I've amended the porter repository to clearly state it is not for upgrades.

  • Options
    whu606whu606 I'm not a SuperHero; I just like wearing tights... MVP

    @x00‌

    Not sure what is unnecessary about my suggesstion.

    I was simply pointing to a way out of the poster's predicament.

    No point saying 'don't do that' when they already have.

  • Options

    Sorry to shout, but for other's benefit.

    grep is your friend.

  • Options
    x00x00 MVP
    edited May 2014

    I believe the actual corruption is caused by lack of schema enforcement and default values in the import format. This is relevant to the porter but not upgrading.

    grep is your friend.

  • Options

    Hi, ok sorry I have made a mistake.

    Actually I didn't have a choice. Some hacker, or robot, injected some script into my forum (old version of vanilla).
    Because of that, I wanted to restart a fresh install.

    So far everything works, but the role thing.

    I'd like to give a try to you method @whu606‌ , can you tell me a little more ?

    Tks

  • Options
    whu606whu606 I'm not a SuperHero; I just like wearing tights... MVP

    @Carlo_13

    It assumes you can use the options in phpMyAdmin.

    Have you ever used them before?

  • Options
    peregrineperegrine MVP
    edited May 2014

    One way to fix things as whu606 was suggesting (I think).

    make a new clean installation with vanilla 2.1 (don't import your old database yet). (save the permissions and role tables each as a sql dump from the new clean installation). or (use these http://vanillaforums.org/discussion/comment/208508/#Comment_208508 (from 2.0.18.x)

    then delete the database in your vanilla 2.1 install, import (via phpmyamdin) the tables from vanilla installation that has all your discussions, comments, etc, everything. (albeit with bad permissions). then empty the permissions table and empty the role table, then import the two tables you saved from the pristine installation). then run /utility/structure and utility update. Then make sure the userrole table reflects all the correct roles for each userid. Then go into the dashboard and adjust the permissions for each role.
    It will definitely work if you follow these instructions.

    you may need to disable all your plugins via dashboard and then enable, but running /utility/update and utility/structure should add the necessary columns in your permissions table.

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • Options
    peregrineperegrine MVP
    edited May 2014

    @linc what about having a place on the site with two clean tables (permissions and roles) downloadable from documentation from a fresh vanilla install. It would save numerous people steps after they post something intentionally or unintentionally at least until porter works perfectly. we see the same problem time and again with porter dealing with permissions and roles. I believe I've ported these tables a couple of times but they are impossible to find.

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • Options

    here are links to pristine 2.0.18.8 tables which could also be used as the two tables to import via phpmyadmin after you have imported via phpmyadmin your vanilla data.

    http://vanillaforums.org/discussion/comment/196686/#Comment_196686

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • Options

    here is a tutorial (every where you see 2.2.2.3 which I can't edit in tutorial) use 2.1

    http://vanillaforums.org/discussion/24793/yet-another-vanilla-upgrade-and-duplication-tutorial

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

  • Options
    LincLinc Detroit Admin

    I'd be fine with have a dba tool that diagnosed & repaired missing permissions. I'm less keen to have an official SQL download.

  • Options
    hgtonighthgtonight ∞ · New Moderator

    I smell a DBAController method coming on.

    Search first

    Check out the Documentation! We are always looking for new content and pull requests.

    Click on insightful, awesome, and funny reactions to thank community volunteers for their valuable posts.

  • Options
    peregrineperegrine MVP
    edited May 2014

    @hgtonight‌
    your sense of smell is better than mine, or maybe your sense of smell detects smells way into the future. :)

    no time like the present for an aid in the mean time :)

    thanks for the reply linc

    I may not provide the completed solution you might desire, but I do try to provide honest suggestions to help you solve your issue.

Sign In or Register to comment.