Announcement

Collapse
No announcement yet.

EspoCRM migrated to other server. User or password is incorrect

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

  • EspoCRM migrated to other server. User or password is incorrect

    I am using espocrm 6.1.10. I just migrated the application and database to another localhost VM server. I managed to copy the application, the database and modify config.php. The login page opens. I entered the admin user and password and I receive the message that the user or password is incorrect. I also tried with the other users. Same message. I've compared users and passwords from new DB with source DB. There are identical with DB source. But still ESPOCRM return message "user or password is incorrect".
    2. I tried to reset password. I've filled in User and email. I receive error 403.

    How can I fix it? Please help
    Last edited by yuri; 05-10-2023, 06:48 AM.

  • #2
    Hi sazicem,

    Try specifying Permissions again: https://docs.espocrm.com/administrat...n/#permissions.

    Comment


    • #3
      Hi sazicem,

      Perhaps you don't copied 'passwordSalt', 'cryptKey', and 'hashSecretKey' (if it exists) values from backup config.php to a newly installed instance.
      After replacing, rebuild via CLI and set new password for admin:


      ​​
      Last edited by Vadym; 05-09-2023, 08:41 AM.

      Comment


      • STARFLEET
        STARFLEET commented
        Editing a comment
        @Vadym: :-) 1 minute faster than me :-)

    • #4
      Hi @sazicem,

      in the config-internal you can find the following lines:
      'passwordSalt' => '89131c4fb2831b2a',
      'cryptKey' => '26ce13f3a19107a9a0d73bbbce1dd5d3',
      'hashSecretKey' => '0d0be064886e6ea18be65c6899abf0b3',​

      Copy them fro your current working instance into your new instance if not done already.

      Hope that helps.

      Comment


      • esforim
        esforim commented
        Editing a comment
        I hope that fake key!

    • #5
      Originally posted by victor View Post
      Hi sazicem,

      Try specifying Permissions again: https://docs.espocrm.com/administrat...n/#permissions.

      The new CRMESPO instance is on Windows OS. Full permissions already.

      Comment


      • #6
        Originally posted by STARFLEET View Post
        Hi @sazicem,

        in the config-internal you can find the following lines:
        'passwordSalt' => '89131c4fb2831b2a',
        'cryptKey' => '26ce13f3a19107a9a0d73bbbce1dd5d3',
        'hashSecretKey' => '0d0be064886e6ea18be65c6899abf0b3',​

        Copy them fro your current working instance into your new instance if not done already.

        Hope that helps.
        I find that lines in the config-internal. Same as source instance config.php

        'hashSecretKey' => '857e4aed1274e0202c343f809afd7dbb',
        'passwordSalt' => 'ecda6d0e25411446',
        'cryptKey' => 'e112e4323a69d03a05962225d751a728',

        Still didn't work​

        Comment


        • #7
          Originally posted by Vadym View Post
          Hi sazicem,

          Perhaps you don't copied 'passwordSalt', 'cryptKey', and 'hashSecretKey' (if it exists) values from backup config.php to a newly installed instance.
          After replacing, rebuild via CLI and set new password for admin:


          ​​

          I find that lines in the config-internal. Same as source instance config.php

          'hashSecretKey' => '857e4aed1274e0202c343f809afd7dbb',
          'passwordSalt' => 'ecda6d0e25411446',
          'cryptKey' => 'e112e4323a69d03a05962225d751a728',

          I've rebuilded via CLI
          I cannot add admin user or set user password. docs ar for ESPOCRM version 7. This commands works for ESPO v6?

          PS If I install old instance to new instance on same server.. everythig ok. If I change server.. did not !​

          Comment


          • #8
            sazicem ,

            Maybe the following thread will be helpful:


            Click image for larger version

Name:	image.png
Views:	423
Size:	106.9 KB
ID:	92020

            Comment


            • #9
              Originally posted by Vadym View Post
              Thanks Vadym,

              There is 2 instances I've tried to migrate.
              1st - VM Ubuntu
              2nd - VM Windows 11 ( for issue replay)

              Same problem on both of them.. I lose all day on this issue.. bad for me.

              No solution yet


              Comment


              • #10
                My preferred solution when something is not fixable within a reasonable period of time is simply to dump everything and start from scratch.

                Check this post for instructions: https://forum.espocrm.com/forum/inst...1187#post61187

                Please consider the following before opting for this option:

                I am not sure if it is still possible to download a fresh installation of Espo 6.1.10 but if not, you will need to upgrade.

                If you have code customizations (aside from anything done through the Admin GUI) you might have to iron out some issues caused by the extensive re-factorization to the codebase from Espo 6 to Espo 7.

                It is possible to replicate everything as long as you have the following:

                sql database export script (to load the database)

                copy of the data/upload folder (to recover attachments and images)

                copy of the config.php script (to recover setting preferences, like menu structure, etc)

                copy of the config-internal.php script (to recover hashes and secret keys for passwords)

                copy of folder custom/Espo/Custom and folder client/custom (to recover customizations made through the GUI)

                Best of luck !

                Last edited by telecastg; 05-09-2023, 04:02 AM.

                Comment


                • #11
                  Originally posted by telecastg View Post
                  My preferred solution when something is not fixable within a reasonable period of time is simply to dump everything and start from scratch.

                  Check this post for instructions: https://forum.espocrm.com/forum/inst...1187#post61187

                  Please consider the following before opting for this option:

                  I am not sure if it is still possible to download a fresh installation of Espo 6.1.10 but if not, you will need to upgrade.

                  If you have code customizations (aside from anything done through the Admin GUI) you might have to iron out some issues caused by the extensive re-factorization to the codebase from Espo 6 to Espo 7.

                  It is possible to replicate everything as long as you have the following:

                  sql database export script (to load the database)

                  copy of the data/upload folder (to recover attachments and images)

                  copy of the config.php script (to recover setting preferences, like menu structure, etc)

                  copy of the config-internal.php script (to recover hashes and secret keys for passwords)

                  copy of folder custom/Espo/Custom and folder client/custom (to recover customizations made through the GUI)

                  Best of luck !
                  Thank you for help.
                  I have already installed a new version espo 7.4.3. Now I'm mentally preparing to manually make all the changes in espo 6.1.10. according with yours steps. I hope it will work.

                  I notice that config.php from version 7.4 differs from config.php from 6.10. In config.php version 7.4.3 installed on a xamp windows, I cannot find the name of the database, the user, the user password. Where can I change the connection data to another database in v7.4.3?​

                  Comment


                  • #12
                    You're welcome, under Espo 7 the database parameters are stored in config-internal.php

                    Comment


                    • #13
                      One more hint: When you install the fresh instance, create an administrator account with a user name that is DIFFERENT than the admin user name that tou have in your database, so when you import the data to the new instance there will be no conflict becasue you are importing a user with the same name.

                      After you have substituted the settings-internal.php with your orignal version, the new administrator account will not be accesible becasue its password wash hashed with a different key.

                      Comment


                      • #14
                        Originally posted by telecastg View Post
                        One more hint: When you install the fresh instance, create an administrator account with a user name that is DIFFERENT than the admin user name that tou have in your database, so when you import the data to the new instance there will be no conflict becasue you are importing a user with the same name.

                        After you have substituted the settings-internal.php with your orignal version, the new administrator account will not be accesible becasue its password wash hashed with a different key.
                        Thanks a lot.

                        Comment

                        Working...
                        X