ORA-65025 when Renaming Global_Name in PDB

SQL>select * from global_name;

GLOBAL_NAME
--------------------------------------------------
OLDNAME

SQL>  alter pluggable database rename global_name to NEWNAME;
 alter pluggable database rename global_name to NEWNAME
                                                *
ERROR at line 1:
ORA-65045: pluggable database not in a restricted mode

SOLUTION

Open PDB in restricted mode, and close all other instances in RAC environment.

SQL> alter pluggable database OLDNAME open restricted;

Pluggable database altered.

SQL>alter pluggable database rename global_name to NEWNAME;

Pluggable database altered

SQL>select * from global_name;

GLOBAL_NAME
--------------------------------------------------
NEWNAME