重庆思庄Oracle、KingBase、PostgreSQL、Redhat认证学习论坛

 找回密码
 注册

QQ登录

只需一步,快速开始

搜索
查看: 211|回复: 0
打印 上一主题 下一主题

[Oracle] ORA-02085: Database Link "LINK_NAME_HERE" ...

[复制链接]
跳转到指定楼层
楼主
发表于 2025-11-9 18:27:42 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
现象:
A database link that is created in a PDB where GLOBAL_NAMES=false can incorrectly throw
this error.  This is true even when a check of GLOBAL_NAMES in the PDB reveals it is set
to false.

While logged in to the PDB and select across the link yields:

select * from dual@linkname;

ORA-2085: database link %s connects to %s

The error is only thrown when the GLOBAL_NAMES parameter at the origin or source database is set to TRUE
and the following condition is met:

The origin or source database link name does NOT match the target
database DB_NAME.DB_DOMAIN or the value of the GLOBAL_NAME table.


See the following document for an explanation of this error and the relationship between GLOBAL_NAMES and a dblink.

Note: 210630.1 Database Links: Troubleshooting ORA-2085: database link %s connects to %s

A check of the CDB reveals that GLOBAL_NAMES is set to true.
A check of the PDB reveals that GLOBAL_NAMES is set to false.


改动:
This problem may arise suddenly if the CDB has been restarted.
Again, no apparent changes have occurred and this established dblink has been working
for some time.


This is not an issue that arises during a dblink creation.



原因:
This is a defect that impacts the 12.1.0.2 version of the PDB.

See the following published BUG:

Bug: 22267060 ORA-2085 IS RAISED EVEN SETTING GLOBAL_NAMES=FALSE

The problem might arise after the CDB is restarted.

Check show parameter at the CDB and you will see it is set to TRUE.
Check show parameter at the PDB and you will see it is set to FALSE.

However, the TRUE setting is being enforced at the PDB due to this defect.


处理方法:
Simply re-issuing the alter system set command to set GLOBAL_NAMES to false at the PDB will allow the link to work.

PDB>alter system set GLOBAL_NAMES=false;

Now dblink works.

分享到:  QQ好友和群QQ好友和群 QQ空间QQ空间 腾讯微博腾讯微博 腾讯朋友腾讯朋友
收藏收藏 支持支持 反对反对
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|手机版|小黑屋|重庆思庄Oracle、Redhat认证学习论坛 ( 渝ICP备12004239号-4 )

GMT+8, 2026-4-18 00:58 , Processed in 0.207165 second(s), 20 queries .

重庆思庄学习中心论坛-重庆思庄科技有限公司论坛

© 2001-2020

快速回复 返回顶部 返回列表