i have two systems (SYS1, SYS2(stand alone)), on both is running an oracle 19c database. i want to create a plugable database from SYS1 and want to plug in the SYS2 database.
i create the pluggable db in read only modus with the sql developer generated script:
BEGIN
EXECUTE IMMEDIATE 'ALTER PLUGGABLE DATABASE "SYS1DB" CLOSE IMMEDIATE';
EXECUTE IMMEDIATE 'ALTER PLUGGABLE DATABASE "SYS1DB" OPEN READ ONLY';
EXECUTE IMMEDIATE 'CREATE PLUGGABLE DATABASE "SYS2DB" FROM "SYS1DB"
STORAGE UNLIMITED TEMPFILE REUSE
FILE_NAME_CONVERT=NONE';
EXECUTE IMMEDIATE 'ALTER PLUGGABLE DATABASE "SYS1DB" CLOSE IMMEDIATE';
EXECUTE IMMEDIATE 'ALTER PLUGGABLE DATABASE "SYS1DB" OPEN READ WRITE';
END;
i copy the files (xml,pdb) via USB Stick (because of the stand alone) to my SYS2.
in my SYS2 system i want to plug in the files with:
CREATE PLUGGABLE DATABASE "NEW_PDB" USING 'SYS2DB.XML'
SOURCE_FILE_NAME_CONVERT=NONE
NOCOPY
STORAGE UNLIMITED TEMPFILE REUSE;
then i get this error:
ORA-65139: Mismatch Between XML Metadata File And Data File "path/to/file"
for value afn (125 in the plug XML file, 18 in the data file)
*Cause Either the XML metadata file or the data file was corrupt
*Action Verify that the XML file and the data file are consistent as of the point when the unplug was done and retry the operation
when i fix all the afn values in my xml file (for testing reasons), i get this error:
ORA-65139: Mismatch Between XML Metadata File And Data File "path/to/file" for value createscnbas (455193957 in the plug XML file, 455205365 in the data file)
i also tried to plugin the files in my SYS1 database, and this works without erros.
i also created in my SYS2 Database pluggable files, and plugin them again in my SYS2 database, this works also.
why i get these errors, i dont change files content, when i copy the files from SYS1 to SYS2.