I haven't been able to get Backup Database working on my local environments. I have the same error on two different sites. It doesn't matter if I try the download option or the local save option.

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

Exception: Include-tables and exclude-tables should be arrays in Ifsnop\Mysqldump\Mysqldump->__construct() (line 174 of /Volumes/Macintosh HD 2/WEBSITE_FOLDER/vendor/ifsnop/mysqldump-php/src/Ifsnop/Mysqldump/Mysqldump.php).

Drupal\backup_db\BackupDatabaseClient->dump() (Line: 43)
Drupal\backup_db\Adapter\BackupDatabaseRemoteAdapter->export() (Line: 91)
Drupal\backup_db\Form\BackupDatabaseForm->submitForm(Array, Object)
call_user_func_array(Array, Array) (Line: 111)
Drupal\Core\Form\FormSubmitter->executeSubmitHandlers(Array, Object) (Line: 51)
Drupal\Core\Form\FormSubmitter->doSubmitForm(Array, Object) (Line: 585)
Drupal\Core\Form\FormBuilder->processForm('backup_db_export', Array, Object) (Line: 314)
Drupal\Core\Form\FormBuilder->buildForm('backup_db_export', Object) (Line: 74)
Drupal\Core\Controller\FormController->getContentResult(Object, Object)
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 574)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 124)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
call_user_func_array(Object, Array) (Line: 144)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 64)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 57)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 99)
Drupal\page_cache\StackMiddleware\PageCache->pass(Object, 1, 1) (Line: 78)
Drupal\page_cache\StackMiddleware\PageCache->handle(Object, 1, 1) (Line: 47)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 50)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 23)
Stack\StackedHttpKernel->handle(Object, 1, 1) (Line: 656)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)

I've installed using composer require drupal/backup_db

I've set the private file path in my settings.shared.php and updated my

I can see the mysqldump-php in my vendor folder.

My Status Report is all clear.

What am I missing?

Comments

Spanners created an issue. See original summary.

spanners’s picture

Issue summary: View changes

  • swim committed b40bec6 on 8.x-1.x
    Issue #2909396: Amended the default values for include and exclude...

swim credited swim.

swim’s picture

Version: 8.x-1.2 » 8.x-1.x-dev
Related issues: +#2909347: No backups created

Hey Spanners, can you please test the latest dev version? The defaults for both options (include/exclude) have been updated.

justinchev’s picture

I was having the same issue:
Exception: Include-tables and exclude-tables should be arrays in Ifsnop\Mysqldump\Mysqldump->__construct() (line 174 of /Users/jondoe/www/drupal8-dev/vendor/ifsnop/mysqldump-php/src/Ifsnop/Mysqldump/Mysqldump.php).

I installed the latest dev version of the module and got the same error. I did find a way of fixing it though on Dev as well as 8.x-1.3. If you go to the 'tables' tab (/admin/config/backup_db/tables), and just hit 'Save configuration' button, then the export downloads as expected.

geoanders’s picture

Status: Active » Closed (cannot reproduce)