要访问PDB,必须配置Oracle网络客户端,客户端可以直接连接创建的PDB。在创建PDB时,Oracle会创建一个与之对应的服务。通常,PDB的名字就是服务名。明白了这一点,我们既可以按照以前配置客户端的方法,配置PDB客户端。
[oracle@rac1 admin]$ cat tnsnames.ora
# tnsnames.ora Network Configuration File: /taryartar/12c/db_base/db_home/network/admin/tnsnames.ora
# Generated by Oracle configuration tools.
TCDB =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = rac1.taryartar.com)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = tcdb)
)
)
PDB1 =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.0.51)(PORT = 1521))
)
(CONNECT_DATA =
(SERVICE_NAME = pdb1)
)
)
TAR =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = rac1.taryartar.com)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = tar.taryartar.com)
)
)
Normal 0 7.8 磅 0 2 false false false MicrosoftInternetExplorer4来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/13804621/viewspace-767984/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/13804621/viewspace-767984/