Earlier I wrote in with a question about a database upgrade failing because of date constraints (Upgrade to 5.57.1 Fails With Error executing task "Fix dangerous delete cascade"). I did not think that this failure left the database partially upgraded. In retrospect this make sense but it did not occur to me at the time.

I think I tried with both cv and the CiviCRM Upgrade page (/civicrm/upgrade).

Now after fixing the dates I am unable to upgrade the database because the database is in a partially upgraded state. I get the following error with CV.

Found CiviCRM database version 5.57.alpha1.upgrade.

Found CiviCRM code version 5.57.3.

In UpgradeDbCommand.php line 80:

Cannot resume upgrade: The log file (/root/.cv/upgrade/dcda99f3a7060a8eeb8c255df45c3907.dat) is missing. Consider a regular upgrade (without --retry or --skip).

I have tried both --skip and --retry and I get the same message.

I have not removed any files from the /root/.cv/upgrade/ directory and this is the only CiviCRM install I have on this server. There is another dat file in the directory but I do not think it is the right one as it appears to shown a successful upgrade.

Reverting back to a database before attempting the upgrade is not a viable option.

Is there anything I can do? I appreciate any help with this.


1 Answer 1


You can try UPDATE civicrm_domain SET version='5.56.0'; in mysql and then run the upgrade normally. Sometimes this causes different problems because some steps are not rerunnable, but I don't think that will happen between 5.56 and 5.57.

  • Thank you, thank you!! This worked well. Commented Feb 14, 2023 at 0:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.