Moodle
  1. Moodle
  2. MDL-12357

Mnethostid is changed in moodle table mdl_config. This cause users to lose permissions and students not enrolled on courses

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Won't Fix
    • Affects Version/s: 1.8.2
    • Fix Version/s: None
    • Component/s: Administration
    • Labels:
      None
    • Environment:
      windows server moodle 1.8.2 using ldap authentication
    • Database:
      MySQL
    • Affected Branches:
      MOODLE_18_STABLE
    • Rank:
      1927

      Description

      Mnethostid is changed in moodle table mdl_config. This cause users to lose permissions and students not enrolled on courses. This is a real problem as the admin permissions are lost and users are created again as brand new users with new id's and no permisions.

        Activity

        Hide
        Dan Poltawski added a comment -

        I've seen similar problems to this in the past, but never got to the bottom of what caused it. Have you seen any idea of what caused it?

        Show
        Dan Poltawski added a comment - I've seen similar problems to this in the past, but never got to the bottom of what caused it. Have you seen any idea of what caused it?
        Hide
        russell added a comment -

        No we have no idea of what is causing this to happen. Everytime this happens we check our log files and sql server files but can not see anything that would be causing this to happen. Happens a couple of times a day now.

        Show
        russell added a comment - No we have no idea of what is causing this to happen. Everytime this happens we check our log files and sql server files but can not see anything that would be causing this to happen. Happens a couple of times a day now.
        Hide
        Xavier de Pedro added a comment -

        Hi:
        I wonder whether we have exactly the same problem, but if not the same, it looks quite related.
        We've just upgraded a site from 1.6.3 (long story why we were still using that version) to 1.8.11.
        Users lost the ability to login and also lost their enrollment to courses.
        We fix the enrollment to courses by adding them again course by course with the new roles, etc.
        But even after that, students can't log in.

        I've created a brand new user, and I've noticed that I can log in with no problems. So then I compared that new user with former students (directly at the mdl_user table; phpmyadmin has been very helpfull! ), and I noticed that the mnethostid field was "0" for former students which suffered the upgrade process, and "1" for the brand new user with no problem to log in.
        So, I changed that field to 1 to 1 former student, and it worked! So that I applied the change to all users (2000+).

        I wonder if this is a good workaround or if we will face other problems in other tables due to this unresolved issue with mnethostid...

        And hint would be welcome...
        xp1829 at iesbarcelona.org

        Xavi

        Show
        Xavier de Pedro added a comment - Hi: I wonder whether we have exactly the same problem, but if not the same, it looks quite related. We've just upgraded a site from 1.6.3 (long story why we were still using that version) to 1.8.11. Users lost the ability to login and also lost their enrollment to courses. We fix the enrollment to courses by adding them again course by course with the new roles, etc. But even after that, students can't log in. I've created a brand new user, and I've noticed that I can log in with no problems. So then I compared that new user with former students (directly at the mdl_user table; phpmyadmin has been very helpfull! ), and I noticed that the mnethostid field was "0" for former students which suffered the upgrade process, and "1" for the brand new user with no problem to log in. So, I changed that field to 1 to 1 former student, and it worked! So that I applied the change to all users (2000+). I wonder if this is a good workaround or if we will face other problems in other tables due to this unresolved issue with mnethostid... And hint would be welcome... xp1829 at iesbarcelona.org Xavi
        Hide
        Michael de Raadt added a comment -

        Thanks for reporting this issue.

        We have detected that this issue has been inactive for over a year has been recorded as affecting versions that are no longer supported.

        If you believe that this issue is still relevant to current versions (2.3 and beyond), please comment on the issue. Issues left inactive for a further month will be closed.

        Michael d;

        4d6f6f646c6521

        Show
        Michael de Raadt added a comment - Thanks for reporting this issue. We have detected that this issue has been inactive for over a year has been recorded as affecting versions that are no longer supported. If you believe that this issue is still relevant to current versions (2.3 and beyond), please comment on the issue. Issues left inactive for a further month will be closed. Michael d; 4d6f6f646c6521
        Hide
        Michael de Raadt added a comment -

        I'm closing this issue as it has been inactive for over a year has been recorded as affecting versions that are no longer supported.

        If you still believe this is an issue in supported versions, please report a new issue.

        Show
        Michael de Raadt added a comment - I'm closing this issue as it has been inactive for over a year has been recorded as affecting versions that are no longer supported. If you still believe this is an issue in supported versions, please report a new issue.

          People

          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: