Announcement

Collapse
No announcement yet.

System user is not retrieveable after rebuilding

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • System user is not retrieveable after rebuilding

    I got below error after rebuilding even though the system user is right in the user table(active=1, delete=0), and the user object is returned as Null by the entityManager in the Espo\Core\Utils\Auth.php

    Please see the attached screenshots.

    Espo.ERROR: Uncaught Exception Espo\Core\Exceptions\Error: "System user is not found" at C:\WinNMP\WWW\EspoCRM\application\Espo\Core\Utils\ Auth.php line 113 {"exception":"[object] (Espo\\Core\\Exceptions\\Error(code: 500): System user is not found at C:\\WinNMP\\WWW\\EspoCRM\\application\\Espo\\Core\ \Utils\\Auth.php:113)"} []

    Don't really want to reinstall it


    Cheers!
    Steven
    Last edited by stevengpn; 11-27-2018, 01:54 PM.

  • #2
    Hello,
    run php rebuild.php as webserver user in cli

    Comment


    • #3
      yes, I ran it in the first place lead to this problem and ran again with the same error.

      Comment


      • #4
        Check whether config.php wasn't crashed? Check permissions as well. Do you have files backup?

        Comment


        • #5
          EspoCRM\data\config.php is intact, seems fine to me. Yes, I have backup source code always.
          I work on windows, BTW.

          Comment


          • #6
            do you have any customization related with User entity?
            try to empty custom folder and execute again rebuild.

            Comment


            • #7
              this is the last line of the log rebuilding:
              [2018-12-04 02:11:06] Espo.ERROR: Fault to rebuild database schema. Details: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry 'system' for key 'PRIMARY' [] []

              Comment


              • #8
                weird...
                try to remove this record from the table and run again rebuild in cli

                Comment


                • #9
                  thanks, that error is gone, now I got new one, please help:
                  [2018-12-05 01:48:53] Espo.ERROR: Uncaught Exception TypeError: "Argument 2 passed to Espo\Core\Acl::__construct() must be an instance of Espo\Entities\User, null given, called in C:\WinNMP\WWW\EspoCRM\application\Espo\Core\Contai ner.php on line 263" at C:\WinNMP\WWW\EspoCRM\application\Espo\Core\Acl.ph p line 41 {"exception":"[object] (TypeError(code: 0): Argument 2 passed to Espo\\Core\\Acl::__construct() must be an instance of Espo\\Entities\\User, null given, called in C:\\WinNMP\\WWW\\EspoCRM\\application\\Espo\\Core\ \Container.php on line 263 at C:\\WinNMP\\WWW\\EspoCRM\\application\\Espo\\Core\ \Acl.php:41)"} []

                  Comment


                  • #10
                    Is system user created after rebuild?
                    And, again ... do you have any customization related with User entity?

                    Comment


                    • #11
                      Yes, it got inserted into user table.

                      Yes, I searched it and deleted any custom entity files from the custom folder. Not sure if I deleted completely.

                      Comment


                      • #12
                        is it work well after removing customization?

                        Comment


                        • #13
                          nope, re-installed

                          Comment

                          Working...
                          X