FarmOS 2.0.0-beta8.1 database update error

I’m running FarmOS using Docker and recently tried to upgrade from 2.0.0-beta4 directly to 2.0.0-beta8. The update failed to update the database properly. The following tables still need to be updated:

Asset

  • The Owners field needs to be installed.
    Consumer
  • The Client ID field needs to be updated.
    Log
  • The Laboratory field needs to be updated.

drush updb produces this error:

[notice] Update started: farm_lab_test_post_update_migrate_lab_terms

[error] SQLSTATE[42S22]: Column not found: 1054 Unknown column ‘lab_value’ in ‘field list’: SELECT entity_id, lab_value FROM log__lab WHERE deleted = 0; Array
(
)

[error] Update failed: farm_lab_test_post_update_migrate_lab_terms
[error] Update aborted by: farm_lab_test_post_update_migrate_lab_terms
[error] Finished performing updates.

What should I do to the db to get the update to work properly? Thanks for your help.

Robert

Hi @macarius - sorry to hear you ran into this error! Do you have a database snapshot/backup from before you started the upgrade? If so, roll back to that so you can be sure you’re starting clean. (This error shouldn’t leave you in a corrupted state, but always good to be start clean just to be safe.)

Are you using 2.0.0-beta8 or 2.0.0-beta8.1? The latter (beta8.1) fixed a bug in the laboratory field update logic, which could be what you ran into if you are using the former (beta8). The title of this topic says “8.1”, but you say “8” in the post, so I just want to be sure.

Mike,

Thanks for the quick response. I started the upgrade using the beta8 image and then tried it again with 8.1 image. Same error with both. I will roll back to my backup of beta4 and try again with 8.1. Thanks.

Robert

1 Like