0

I uninstalled a few modules.

    ~/apps/drupal/htdocs/modules$ drush pm-uninstall relaxed
    The following extensions will be uninstalled: relaxed
    Do you really want to continue? (y/n): y
    relaxed was successfully uninstalled.                                                                                                      [ok]
    bitnami@ip-172-26-15-109:~/apps/drupal/htdocs/modules$ drush pm-uninstall replication
    The following extensions will be uninstalled: replication
    Do you really want to continue? (y/n): y
    replication was successfully uninstalled.                                                                                                  [ok]
    bitnami@ip-172-26-15-109:~/apps/drupal/htdocs/modules$ drush pm-uninstall multiversion
    The following extensions will be uninstalled: multiversion
    Do you really want to continue? (y/n): y
    multiversion was successfully uninstalled.
    bitnami@ip-172-26-15-109:~/apps/drupal/htdocs/modules$ drush pm-uninstall views_rest_feed
    The following extensions will be uninstalled: views_rest_feed
    Do you really want to continue? (y/n): y
    views_rest_feed was successfully uninstalled.

And now I see errors. I see following errors, how should I proceed with fixing them? Entity/field definitions Mismatched entity and/or field definitions The following changes were detected in the entity type and field definitions. Comment

The Comment entity type needs to be updated.

File

The File entity type needs to be updated.

Content

The Revision ID field needs to be installed.
The UUID field needs to be updated.

Shortcut link

The UUID field needs to be updated.

Taxonomy term

The Taxonomy term entity type needs to be updated.

User

The UUID field needs to be updated.

Custom menu link

The Custom menu link entity type needs to be updated.

    Running drush entity-updates gives
    The following updates are pending:

    comment entity type : 
      The Comment entity type needs to be updated.
    file entity type : 
      The File entity type needs to be updated.
    node entity type : 
      The Revision ID field needs to be installed.
      The UUID field needs to be updated.
    shortcut entity type : 
      The UUID field needs to be updated.
    taxonomy_term entity type : 
      The Taxonomy term entity type needs to be updated.
    user entity type : 
      The UUID field needs to be updated.
    menu_link_content entity type : 
      The Custom menu link entity type needs to be updated.



    Do you wish to run all pending updates? (y/n): y
    Drupal\Core\Entity\EntityStorageException: The SQL storage cannot change the schema for an existing entity type (comment) with data. in    [error]
    Drupal\Core\Entity\Sql\SqlContentEntityStorageSchema->onEntityTypeUpdate() (line 303 of
    /opt/bitnami/apps/drupal/htdocs/core/lib/Drupal/Core/Entity/Sql/SqlContentEntityStorageSchema.php).
    Failed: Drupal\Core\Entity\EntityStorageException: !message in                                                                             [error]
    Drupal\Core\Entity\Sql\SqlContentEntityStorageSchema->onEntityTypeUpdate() (line 303 of
    /opt/bitnami/apps/drupal/htdocs/core/lib/Drupal/Core/Entity/Sql/SqlContentEntityStorageSchema.php).
    Cache rebuild complete.                                                                                                                    [ok]
    Finished performing updates.    


    drush watchdog-show
     ID   Date          Type      Severity  Message                                                                                               
     147  22/Dec 15:57  php       error     Drupal\Core\Database\DatabaseExceptionWrapper: SQLSTATE[42S22]: Column not found: 1054 Unknown column 
                                            'base_table.vid' in 'field list': SELECT base_table.vid AS vid, base_table.nid AS nid                 

     146  22/Dec 15:57  php       error     Drupal\Core\Database\DatabaseExceptionWrapper: SQLSTATE[42S22]: Column not found: 1054 Unknown column 
                                            'base_table.vid' in 'field list': SELECT base_table.vid AS vid, base_table.nid AS nid                 

     145  22/Dec 15:57  cron      notice    Cron run completed.                                                                                   
     144  22/Dec 15:57  cron      notice    Execution of update_cron() took 9.97ms.                                                               
     143  22/Dec 15:57  cron      notice    Starting execution of update_cron(), execution of system_cron() took 15.01ms.                         
     142  22/Dec 15:57  cron      notice    Starting execution of system_cron(), execution of search_cron() took 4.15ms.                          
     141  22/Dec 15:57  cron      notice    Starting execution of search_cron(), execution of node_cron() took 30.37ms.                           
     140  22/Dec 15:57  cron      notice    Starting execution of node_cron(), execution of history_cron() took 1.82ms.                           
     139  22/Dec 15:57  cron      notice    Starting execution of history_cron(), execution of file_cron() took 11.11ms.                          
     138  22/Dec 15:57  cron      notice    Starting execution of file_cron(), execution of field_cron() took 3.38ms.

Also accessing http://ipaddress/admin/modules/uninstall gives

    The website encountered an unexpected error. Please try again later.

Apache error log shows

    [Thu Dec 22 15:06:52.683333 2016] [core:notice] [pid 13291:tid 139826185398080] AH00094: Command line: '/opt/bitnami/apache2/bin/httpd.bin -f /opt/bitnami/apache2/conf/httpd.conf'
    [Thu Dec 22 15:06:58.953491 2016] [proxy_fcgi:error] [pid 13300:tid 139825856366336] [client 123.201.127.176:49572] AH01071: Got error 'PHP message: PHP Fatal error:  Call to a member function id() on null in /opt/bitnami/apps/drupal/htdocs/modules/multiversion/src/WorkspaceCacheContext.php on line 44\n'
    [Thu Dec 22 15:12:39.540744 2016] [proxy_fcgi:error] [pid 13299:tid 139825386374912] [client 123.201.127.176:49808] AH01071: Got error 'PHP message: Uncaught PHP Exception Drupal\\Core\\Database\\DatabaseExceptionWrapper: "SQLSTATE[42S22]: Column not found: 1054 Unknown column 'revision.revision_id' in 'field list': SELECT revision.revision_id AS revision_id, revision.langcode AS langcode, revision.revision_log AS revision_log, base.id AS id, base.type AS type, base.uuid AS uuid, CASE base.revision_id WHEN revision.revision_id THEN 1 ELSE 0 END AS isDefaultRevision\nFROM \n{block_content} base\nINNER JOIN {block_content_revision} revision ON revision.revision_id = base.revision_id; Array\n(\n)\n" at /opt/bitnami/apps/drupal/htdocs/core/lib/Drupal/Core/Database/Connection.php line 671\n'
    [Thu Dec 22 15:14:41.556451 2016] [proxy_fcgi:error] [pid 13299:tid 139825428338432] [client 123.201.127.176:49828] AH01071: Got error 'PHP message: Uncaught PHP Exception Drupal\\Core\\Database\\DatabaseExceptionWrapper: "SQLSTATE[42S22]: Column not found: 1054 Unknown column 'revision.revision_id' in 'field list': SELECT revision.revision_id AS revision_id, revision.langcode AS langcode, revision.revision_log AS revision_log, base.id AS id, base.type AS type, base.uuid AS uuid, CASE base.revision_id WHEN revision.revision_id THEN 1 ELSE 0 END AS isDefaultRevision\nFROM \n{block_content} base\nINNER JOIN {block_content_revision} revision ON revision.revision_id = base.revision_id; Array\n(\n)\n" at /opt/bitnami/apps/drupal/htdocs/core/lib/Drupal/Core/Database/Connection.php line 671\n'

Have run drush cr The errors remain in admin/reports/status

After reinstalling multiversion, above report status errors are fixed. I get an error when I create an article Following is apache log

    Thu Dec 22 18:20:11.742576 2016] [proxy_fcgi:error] [pid 13299:tid 139825604585216] [client 42.109.14.45:43240] AH01071: Got error 'PHP message: Uncaught PHP Exception Drupal\\Core\\Entity\\EntityStorageException: "SQLSTATE[HY000]: General error: 1364 Field 'vid' doesn't have a default value: INSERT INTO {node_revision} (nid, langcode, revision_timestamp, revision_uid, revision_log) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2, :db_insert_placeholder_3, :db_insert_placeholder_4); Array\n(\n    [:db_insert_placeholder_0] => 1\n    [:db_insert_placeholder_1] => en\n    [:db_insert_placeholder_2] => 1482430811\n    [:db_insert_placeholder_3] => 1\n    [:db_insert_placeholder_4] => \n)\n" at /opt/bitnami/apps/drupal/htdocs/modules/multiversion/src/Entity/Storage/ContentEntityStorageTrait.php line 152\n', referer: http://52.91.79.10/node/add/article

Have run sudo drush entity-updates again, I get the following

           No entity schema updates required                                                                                                          [success]
    Cache rebuild complete.                                                                                                                    [ok]
    Finished performing updates.                                                                                                               [ok]

Running drush updb gives the following sudo drush updb No database updates required [success]

I am using AWS lightsail bitnami drupal instance.

  • Try to clear your cache. drush cr – Ashish Deynap Dec 22 '16 at 17:18
  • Have run drush cr. The errors remain. Have edited my post. – Rupa Lahiri Dec 22 '16 at 17:37
  • the error is on uninstalling multiversion module. drupal.org/node/2720455 – Ashish Deynap Dec 22 '16 at 18:09
  • Now when I try to create an article, I get an error – Rupa Lahiri Dec 22 '16 at 18:22
  • did you run drush entity-updates – Kevin Dec 22 '16 at 18:41
1

The error is on uninstalling multiversion module.

The error that you got in the log was due to no values inserted to revision_log column in node_revision table.

It's advised that you install multiversion module right after installing your site (or before adding content).This module will convert all of the content entities on your site to be revisionable.

I suggest you to take a fresh new drupal setup to resolve this as you will again and again face such type of fatal errors.

  • Can I refresh a bitnami drupal setup? – Rupa Lahiri Dec 22 '16 at 18:50
  • I don't think so as Switching back storage handler involves a migration of existing content which needs work in current module alpha version. – Ashish Deynap Dec 22 '16 at 18:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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