Support

Admin Tools for WordPress

#41692 Akeeba Backup Failing

Posted in ‘Admin Tools for WordPress’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Environment Information

WordPress version
6.7.2
PHP version
8.3.16
Admin Tools version
1.6.7

Latest post by chris.gruener on Monday, 10 March 2025 13:21 CDT

chris.gruener

The data replacement operation has been halted because an error was detected.
The last error message was:

Duplicate entry '_wpforms_transient_wpforms_/home/xjzkhbnv/staging.gvcporphans...' for key 'option_name'

## /home/xjzkhbnv/staging.gvcporphans.org/installation/src/Framework/Database/Driver/Mysqli.php:311
#0 /home/xjzkhbnv/staging.gvcporphans.org/installation/src/Framework/Database/Driver/Mysqli.php(311): mysqli_query()
#1 [SITE_ROOT]/Engine/ReplacementEngine.php(378): Akeeba\BRS\Framework\Database\Driver\Mysqli->execute()
#2 [SITE_ROOT]/Model/Replacedata.php(565): Akeeba\BRS\Platform\Engine\ReplacementEngine->step()
#3 [SITE_ROOT]/Controller/Replacedata.php(95): Akeeba\BRS\Platform\Model\Replacedata->step()
#4 /home/xjzkhbnv/staging.gvcporphans.org/installation/src/Framework/Mvc/Controller.php(188): Akeeba\BRS\Platform\Controller\Replacedata->ajax()
#5 /home/xjzkhbnv/staging.gvcporphans.org/installation/src/Framework/Dispatcher/Dispatcher.php(61): Akeeba\BRS\Framework\Mvc\Controller->execute()
#6 /home/xjzkhbnv/staging.gvcporphans.org/installation/src/Framework/Application/AbstractApplication.php(82): Akeeba\BRS\Framework\Dispatcher\Dispatcher->dispatch()
#7 /home/xjzkhbnv/staging.gvcporphans.org/installation/index.php(103): Akeeba\BRS\Framework\Application\AbstractApplication->dispatch()
#8 {main}

I ran kickstart.php and the unpacking process started by then failed for reason of error in header information. I then clicked reload, and the unpacking process completed and I started the installation routine. I got all the way to replacing links to reflect the change in domain when the installation failed again with the error mentioned above.

nicholas
Akeeba Staff
Manager

Can you please tell me what was the table name prefix for the original site, and what it is on the restored site?

Nicholas K. Dionysopoulos

Lead Developer and Director

🇬🇷Greek: native 🇬🇧English: excellent 🇫🇷French: basic • 🕐 My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

chris.gruener

wp_gvcp1

Wish Crete was closer to California so there would be this time zone lag.

chris.gruener

Still getting that Data Rplacement Failed error.:

The data replacement operation has been halted because an error was detected.
The last error message was:

Duplicate entry '_wpforms_transient_wpforms_/website-root/staging.gvcporphans...' for key 'option_name'

## website-root/staging.gvcporphans.org/installation/src/Framework/Database/Driver/Mysqli.php:311 #0 website-root/staging.gvcporphans.org/installation/src/Framework/Database/Driver/Mysqli.php(311): mysqli_query() #1 [SITE_ROOT]/Engine/ReplacementEngine.php(378): Akeeba\BRS\Framework\Database\Driver\Mysqli->execute() #2 [SITE_ROOT]/Model/Replacedata.php(565): Akeeba\BRS\Platform\Engine\ReplacementEngine->step() #3 [SITE_ROOT]/Controller/Replacedata.php(95): Akeeba\BRS\Platform\Model\Replacedata->step() #4 website-root/staging.gvcporphans.org/installation/src/Framework/Mvc/Controller.php(188): Akeeba\BRS\Platform\Controller\Replacedata->ajax() #5 website-root/staging.gvcporphans.org/installation/src/Framework/Dispatcher/Dispatcher.php(61): Akeeba\BRS\Framework\Mvc\Controller->execute() #6 website-root/staging.gvcporphans.org/installation/src/Framework/Application/AbstractApplication.php(82): Akeeba\BRS\Framework\Dispatcher\Dispatcher->dispatch() #7 website-root/staging.gvcporphans.org/installation/index.php(103): Akeeba\BRS\Framework\Application\AbstractApplication->dispatch() #8 {main}

I deleted the debug.log files, cut the .jpa archive in half.

I restricted any scripts I created to just the live site so that they wouldn't interfere with Akeeba Backup.

Database prefix is wp_gvcp1. I was snoozing when I did this, it should have been wpgvcp_. Hope that isn't a critical problem.

I don't get this entry: Duplicate entry '_wpforms_transient_wpforms_/website-root/staging.gvcporphans...' for key 'option_name'

Is this a wpforms screw up?

nicholas
Akeeba Staff
Manager

Ultimately, this is a problem with the database. When we replace data we use the primary key of the table to tell the database which row to modify. The key of the #__options table is option_id. It wooers that one of the transients created by WPForms has an option_name which, upon replacement, becomes the same as another record's option_name but that record has a different option_id. Since option_name is a unique key it will cause a SQL error.

You wonder how that happened. Well, yes, this is ultimately a problem caused by WPForms. If it was using WordPress' transients feature the transient would've been cleared by WP itself upon logout and that would be the end of it. Instead, they are using their own transient which a. doesn't clear itself as it should and b. includes the domain name of the site in its option_name, meaning that upon data replacement it WILL create a duplicate option_name key.

(Aside: I asked you about the prefix because I wanted to make sure the site's prefix is not, for some weird reason, _wpforms which would've indeed caused a similar problem, albeit one far easier to catch and resolve. Anyway.)

If it's an option, delete all #__options records whose option_name starts with _wpforms_transient_ and take a new backup. This will fix the problem.

If that's not an option, not all is lost. We can still do that on the new site while the Replace Data page is open, before you start the replacement process. It will also work.

Nicholas K. Dionysopoulos

Lead Developer and Director

🇬🇷Greek: native 🇬🇧English: excellent 🇫🇷French: basic • 🕐 My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

chris.gruener

Thanks Nicholas, will do. This will be the last WordPress site I build,