I had a problem where I couldn't upgrade my Espocrm 10.1.1 to 10.1.4

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • delarosa
    Junior Member
    • Jul 2020
    • 9

    #1

    I had a problem where I couldn't upgrade my Espocrm 10.1.1 to 10.1.4

    Up through version 10.1.1, the simple method—running `php command.php upgrade` - worked for me on three servers.

    I had a problem where I couldn't upgrade my Espocrm 10.1.1 to 10.1.4.

    The old version (10.1.1) kept reappearing whenever I cleared the cache and pressed CTRL+F5.
    Maybe this will help others; it worked for me this way:


    Espocrm
    Version: 10.1.1
    Configuration Server:
    1. Operating System: Debian 13.7 (64-bit)
    2. Keyhelp Control Panel: 26.2 (Build 3756)
    3. PHP: 8.4.28
    4. Database Server: MariaDB 11.8.6
    The following solution helped me
    1. Log in as root
    2. Navigate to the relevant Espocrm root directory
    3. Execute Command 1
    4. Run Command 2 until there are no more upgrades available. Then run Commands 3 through 4.
    5. In espocrm (UI), press CTRL-5

    In the commands, simply replace "Username" with the correct username - that is, the username associated with the domain (Espocrm).

    Command-1

    Code:
    chown -R Username:Username .
    Command-2

    Code:
    su -s /bin/bash Username -c "/opt/keyhelp/php/8.5/bin/php -d memory_limit=512M -d opcache.enable_cli=0 command.php upgrade -y"
    Command-3

    Code:
    su -s /bin/bash Username -c "/opt/keyhelp/php/8.5/bin/php clear_cache.php && /opt/keyhelp/php/8.5/bin/php rebuild.php"
    Command-4

    Code:
    systemctl restart keyhelp-php85-fpm

    If errors occur, such as "PHP path is incorrect" or "PHP not found":

    As an administrator, install PHP 8.5 (or another version) in Keyhelp.

    It's possible that no additional PHP was installed in the /opt directory.

    I'd be happy if a specialist had a better suggestion or could evaluate my suggestion.
  • victor
    Active Community Member
    • Aug 2022
    • 1257

    #2
    delarosa ,

    Do I understand correctly that the update proceeds in the CLI without errors, yet after the upgrade and rebuild, you are still on version 10.1? If so, try the following:

    1. Create a backup of all Espo files and a database dump.
    2. Download the v10.1.4 archive and copy all files from it, excluding the /data and /custom directories.
    3. Replace the old files with the copied ones.
    4. Make Rebuild.

    Everything should work after this.
    In any case, you have a backup available for restoration.

    Comment


    • delarosa
      delarosa commented
      Editing a comment
      Hi victor,

      Thank you very much for the tip.

      I always make sure to have an up-to-date backup before performing actions like this.

      My method described above also works—maybe even a little faster. I just copy the 4 commands into the CLI, and only then do I go into Espocrm to update and then press CTRL-F5.

      Thank you very much again.
  • yuri
    EspoCRM product developer
    • Mar 2014
    • 10127

    #3
    There was a missing file (default config) in the upgrade packages between 10.1.1 and 10.1.3. No issue in the upgrade packages for 10.1.4.

    When rebuild was made, due to the missing file the system reverted the 'version' parameter to 10.1.1 because the file was from 10.1.1.

    - Upgrade to 10.1.4 from any version should work fine.
    - Docker setups were not affected.

    Comment


    • delarosa
      delarosa commented
      Editing a comment
      Hi Yuri,

      Thanks so much for the info.
      Does that mean I'll be able to use 'php command.php upgrade' as usual again starting with version 10.1.4?
  • yuri
    EspoCRM product developer
    • Mar 2014
    • 10127

    #4
    You should be able to use upgrade from any version since 10.1.4 is out. As there are direct patches from 10.1.0-10.0.3 to 10.0.4.

    If upgrade to 10.1.4 indeed does not work for you, I don't know the reason why. Maybe opcache related?

    I just tested upgrade from 10.1.1 to 10.1.4 via the command and it worked fine – upgraded directly to 10.1.4.

    Comment


    • delarosa
      delarosa commented
      Editing a comment
      Hi Yuri,
      It worked using the method I described in my post above.

    • yuri
      yuri commented
      Editing a comment
      The question why it didn't work just by running the regular upgrade command. I don't know.
Working...