EspoCRM migration to a new hosting server login problem

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • nunos
    Member
    • Mar 2018
    • 94

    EspoCRM migration to a new hosting server login problem

    Hi everyone,

    I have migrated an old EspoCRM (5.x) system to a new hosting server, database backup and restore, all files restored to the new hosting.

    I can get normally to the login page on the new server installation but none of the users / passwords are working. Wrong username / password error message.

    Everything seems to have migrated ok. What is wrong / missing?

    Thanks,

    Nuno
    Last edited by nunos; 02-20-2024, 11:23 AM.
  • victor
    Active Community Member
    • Aug 2022
    • 857

    #2
    Hi nunos,

    - Please enable Debug mode in your instance on the new server: https://docs.espocrm.com/administrat...ng/#debug-mode.
    - Reproduce the error
    - Submit the EspoCRM error log. By default, log files are created in {ESPO_ROOT}/data/logs/ directory.​

    Comment

    • Firyo
      Senior Member
      • Jun 2022
      • 137

      #3
      Hi there,

      Could you check if the
      Code:
      passwordSalt
      value inside the file
      Code:
      data/config-internal.php
      is still the same (from before your migration) ?
      This parameter is (re)generated when you install an EspoCRM (
      Code:
      install/core/Installer.php inside saveData() at line 392
      )

      Regards,
      Firyo.

      Comment


      • esforim
        esforim commented
        Editing a comment
        This is likely the problem. You can either reset the password or change the 'salt' (I remember this is the harder method). Luckily for me when I migrate like this I didn't have many account and just forced everyone to have new password.

        Anyway from what I know. Salt is basically a random extra data that get add before your password is encrypted. That way if your database get leak, the true password is hidden and unknown and people can't use the same password/email/username to 'hack' other website.

      • nunos
        nunos commented
        Editing a comment
        Hi Firyo,

        Sorry for the delay... was away during some time...

        The passwordSalt param in data/config-internal.php is different from the old install version.

        Can i update it? How?

        Thanks,

        Nuno
    • item
      Active Community Member
      • Mar 2017
      • 1518

      #4
      Hi,
      it's really basic error : new server say : new php version certainly, all php extension installed.
      espoCrm v5.x is "senior" now.
      if new server, php is certainly newer.
      If you could give the project a star on GitHub. EspoCrm believe our work truly deserves more recognition. Thanks.​

      Comment

      • victor
        Active Community Member
        • Aug 2022
        • 857

        #5
        nunos, if you managed to log in normally, you can change user passwords to temporary ones through the UI or through the CLI: https://docs.espocrm.com/administrat...st-cant-log-in.

        Also, if users have the specified e-mails and Outbound Emails is configured, users can create a new password for themselves or you via the Send Password Change Link.

        Click image for larger version

Name:	image.png
Views:	203
Size:	13.5 KB
ID:	105861

        Comment


        • nunos
          nunos commented
          Editing a comment
          Thanks victor,

          No luck, at the moment i can't login with any user/password, not even admin.

          Just the message "Wrong username/password"

          And no access to CLI ...

          EspoCRM version installed 8.1.1

          The strange thing is that after the update i have been able to login to the system and then logout. After that not allowing to login anymore.
          Last edited by nunos; 05-08-2024, 12:23 PM.
      • victor
        Active Community Member
        • Aug 2022
        • 857

        #6
        nunos,

        Using EspoCRM on your own server without access to the CLI is quite inconvenient, and at different stages of operation, you will encounter various problems that are easily solved through the CLI and difficult to solve (or not solved at all) when there is no access to the CLI.

        In your case, there is still an opportunity to fix the situation:
        - as yuri suggested in this post: https://forum.espocrm.com/forum/gene...0564#post10564;
        - and how a community member implemented this advice: https://forum.espocrm.com/forum/gene...0578#post10578.

        Please note that passwordSalt was located in your_instance_name/data/config.php for older versions of EspoCRM, and in your_instance_name/data/config-internal.php for newer versions.

        Comment


        • nunos
          nunos commented
          Editing a comment
          Thanks @victor,

          Going to give it a try...
      • nunos
        Member
        • Mar 2018
        • 94

        #7
        Ok guys, so i think i got it, thanks to the following post https://forum.espocrm.com/forum/gene...word#post10564 Thanks victor !!!

        The solution is to install a new instance of EspoCRM into a new directory (just to be able to extract the necessary data)

        1 - Install new EspoCRM instance
        2 - Copy passwordSalt info from the new installed instance to your current instance (config.php for older versions of EspoCRM, config-internal.php for recent ones)
        3 -
        With PHPmyadmin copy hashed password from new installed instance (Admin or any other user) to current instance PHPmyadmin (Admin or any other user)
        4 - login

        Nuno​

        Comment

        • sjonnaert
          Junior Member
          • May 2023
          • 5

          #8
          I have a similar issue:

          I’m doing a migration, at the same time upgrading from EspoCRM version 7.3.4 to version 9.0.6. I’m following the instructions provided on (https://docs.espocrm.com/extensions/...import/export/). The export goes fine. The import however hangs on:
          “EntityEmailAddress...
          Total: 146664
          EntityPhoneNumber...”
          I’ve tried a couple of times.
          On two occasions I received an error:
          Error: The connection to the server ended in failure at 12:33:20 AM. (ABORTED)
          Error: The connection to the server ended in failure at 11:39:47 PM. (SIGKILL)
          Any suggestions?

          -Serge

          Comment


          • victor
            victor commented
            Editing a comment
            - First, upgrade your instance from 7.3.4 to version 9.0.6 and only then perform Export/Import.
            - Or perform Export/Import from 7.3.4 to 7.3.4, and only then perform Upgrade.

          • abhilash.kumar.niit
            abhilash.kumar.niit commented
            Editing a comment
            Hi @victor,

            i am also migrating the code from one dev to uat and getting the wrong password error when ever i perform import/export can you suggest what i am mising?
        • victor
          Active Community Member
          • Aug 2022
          • 857

          #9
          abhilash.kumar.niit Where exactly are you getting an error with your password?

          Comment

          • abhilash.kumar.niit
            Member
            • Sep 2024
            • 86

            #10
            i am getting wrong password error on my uat env the dev env works fine.

            bin/command export-import export --format=json --path="./data/export-import" --skip-password

            this is the command i am using for exporting from dev and import on uat env.

            Comment

            Working...