ndb_restore With Foreign Keys Fails: "Failed to Create Foreign Key myfk Parent t3.PRIMARY Child t4.PRIMARY: 721: Schema Object With Given Name Already Exists" (Doc ID 1925644.1)

Last updated on NOVEMBER 23, 2015

Applies to:

MySQL Cluster - Version 7.3 to 7.3 [Release 7.3]
Information in this document applies to any platform.

Symptoms

With a backup of a database where there are two or more foreign keys that have the same name but are on different tables, restoring the backup using ndb_restore --restore_meta will fail with the following error:

Failed to create foreign key myfk parent t3.PRIMARY child t4.PRIMARY: 721: Schema object with given name already exists

 

As the MySQL Cluster Manager (MCM) restore cluster command uses ndb_restore --restore_meta, restoring a backup through MCM is also affected.

 

The issue can be reproduced with the following steps:

  1. Create the schema:

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms