Answers.Body: <p>It appears from <a href="https://stackoverflow.com/questions/25155777/operation-not-allowed-when-innodb-forced-recovery-0-sqlyog">this other StackExchange answer</a> that the MySQL on the new server may be set to read only. Try opening the my.cnf configuration file for MySQL and changing the setting.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-10-28T03:23:26.373Z
Answers.Text: Thanks, Joe Murray. Apparently a setting of `innodb_force_recovery = 1` in /etc/my.cnf causes tables that are innodb format to be read only. I'm trying to get the hosting box owner to change it. Please stand by.
Answers.UserDisplayName: Chris
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-10-29T13:40:46.253Z
Answers.Text: PS If a StackExchange answer addresses your question/problem, then it is good form to check it as accepted, and to up-vote it. But I get it that you don't yet know if this will solve the issue.
Answers.UserDisplayName: Joe Murray
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-10-26T21:31:39.910Z
Answers.LastActivityDate: 2015-10-29T13:38:20.627Z
Answers.LastEditDate: 2017-05-23T12:38:59.763Z
Answers.UserDisplayName: Joe Murray
Body: <p>Wordpress 4.3.1</p>
  
  <p>CiviCRM 4.5.5</p>
  
  <p>Old host: Apache 2.2.26 - PHP: 5.3.28 - MySQL: 5.1.73</p>
  
  <p>New host: Apache 2.2.29 - PHP: 5.3.29 - MySQL: 5.6.23</p>
  
  <p>My only export options on the old host are via phpMyAdmin or cpanel export on the old host. I basically get a data.sql.gz file. </p>
  
  <p>When I do this in ssh on the new host:</p>
  
  <pre><code>mysql -u username -p -h localhost DATA-BASE-NAME &lt; data.sql
  </code></pre>
  
  <p>I'm getting this error:</p>
  
  <pre><code>ERROR 1881 (HY000) at line 48: Operation not allowed when innodb_forced_recovery &gt; 0.
  </code></pre>
  
  <p>What can I do with my sql file or from the old host's phpMyAdmin so that the data import properly into the new host?</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2015-10-23T17:47:10.517Z
Comments.Text: Could you provide the SQL statement at line 48 of the file?
Comments.UserDisplayName: Joe Murray
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2015-10-23T20:50:10.903Z
Comments.Text: Thanks for your reply.  The line is too long for this venue. (5698 characters)   
  It starts:    
  `INSERT INTO `civicrm_acl` (`id`, `name`, `deny`, `entity_table`, `entity_id`, `operation`, `object_table`, `object_id`, `acl_table`, `acl_id`, `is_active`) VALUES (1,'Edit All Contacts',0,'civicrm_acl_role',1,'Edit','civicrm_saved_search',0,NULL,NULL,1),`
    
  and ends  
    
  `,(65,'Core ACL',0,'civicrm_acl_role',2,'All','view event info',NULL,NULL,NULL,1);`
Comments.UserDisplayName: Chris
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2015-10-23T20:55:47.807Z
Comments.Text: Line 47: `/*!40000 ALTER TABLE `civicrm_acl` DISABLE KEYS */;`
  
  Line 49: `/*!40000 ALTER TABLE `civicrm_acl` ENABLE KEYS */;`
Comments.UserDisplayName: Chris
Tags: <wordpress><mysql><error><migration>
Title: Migrating domain to new server. mysql migration Error 1881
ThreadText: # Migrating domain to new server. mysql migration Error 1881
  
  (Asked by: username_0 on 2015-10-23)
  
  Wordpress 4.3.1
  
  CiviCRM 4.5.5
  
  Old host: Apache 2.2.26 - PHP: 5.3.28 - MySQL: 5.1.73
  
  New host: Apache 2.2.29 - PHP: 5.3.29 - MySQL: 5.6.23
  
  My only export options on the old host are via phpMyAdmin or cpanel export on the old host. I basically get a data.sql.gz file.
  
  When I do this in ssh on the new host:
  
  ```
  mysql -u username -p -h localhost DATA-BASE-NAME < data.sql
  
  ```
  
  I'm getting this error:
  
  ```
  ERROR 1881 (HY000) at line 48: Operation not allowed when innodb_forced_recovery > 0.
  
  ```
  
  What can I do with my sql file or from the old host's phpMyAdmin so that the data import properly into the new host?
  
  **Tags:** wordpress, mysql, error, migration
  
  > **Comments:**
  > **username_1**: Could you provide the SQL statement at line 48 of the file?  
  > **username_0**: Thanks for your reply.  The line is too long for this venue. (5698 characters)    It starts:     `INSERT INTO `civicrm_acl` (`id`, `name`, `deny`, `entity_table`, `entity_id`, `operation`, `object_table`, `object_id`, `acl_table`, `acl_id`, `is_active`) VALUES (1,'Edit All Contacts',0,'civicrm_acl_role',1,'Edit','civicrm_saved_search',0,NULL,NULL,1),`    and ends      `,(65,'Core ACL',0,'civicrm_acl_role',2,'All','view event info',NULL,NULL,NULL,1);`  
  > **username_0**: Line 47: `/*!40000 ALTER TABLE `civicrm_acl` DISABLE KEYS */;`  Line 49: `/*!40000 ALTER TABLE `civicrm_acl` ENABLE KEYS */;`  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2015-10-26. Score: 0 | Accepted answer
  
  It appears from [this other StackExchange answer](https://stackoverflow.com/questions/25155777/operation-not-allowed-when-innodb-forced-recovery-0-sqlyog) that the MySQL on the new server may be set to read only. Try opening the my.cnf configuration file for MySQL and changing the setting.
  
  > **Comments:**
  > **username_0**: Thanks, username_1. Apparently a setting of `innodb_force_recovery = 1` in /etc/my.cnf causes tables that are innodb format to be read only. I'm trying to get the hosting box owner to change it. Please stand by.  
  > **username_1**: PS If a StackExchange answer addresses your question/problem, then it is good form to check it as accepted, and to up-vote it. But I get it that you don't yet know if this will solve the issue.  
  
  ---
  
  