您好,登录后才能下订单哦!
密码登录
登录注册
点击 登录注册 即表示同意《亿速云用户服务条款》
多实例监听的配置
三种情况:
1、一个监听在一个IP一个端口上监听多个实例
2、一个监听在一个IP不同端口上监听多个实例
3、多个监听监听多个实例
情况1:
listener.ora文件:
# listener.ora Network Configuration File: E:\app\product\11.2.0\dbhome_1\NETWORK\ADMIN\listener.ora # Generated by Oracle configuration tools. SID_LIST_ORCL = (SID_LIST = (SID_DESC = (GLOBAL_DBNAME = ORCL) (SID_NAME = ORCL) ) (SID_DESC = (GLOBAL_DBNAME = NHL) (SID_NAME = NHL) ) ) ORCL = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.152.131)(PORT = 1521)) ) (DESCRIPTION = (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC)) ) )
tnsnames.ora文件:
# tnsnames.ora Network Configuration File: E:\app\product\11.2.0\dbhome_1\network\admin\tnsnames.ora # Generated by Oracle configuration tools. NHL = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.152.131)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = NHL) ) ) ORCL = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.152.131)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = orcl) ) )
情况2:
listener.ora文件:
# listener.ora Network Configuration File: E:\app\product\11.2.0\dbhome_1\NETWORK\ADMIN\listener.ora # Generated by Oracle configuration tools. SID_LIST_ORCL = (SID_LIST = (SID_DESC = (GLOBAL_DBNAME = ORCL) (SID_NAME = ORCL) ) (SID_DESC = (GLOBAL_DBNAME = NHL) (SID_NAME = NHL) ) ) ORCL = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.152.131)(PORT = 1521)) ) (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.152.131)(PORT = 1522)) ) (DESCRIPTION = (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC)) ) )
tnsnames.ora文件:
# tnsnames.ora Network Configuration File: E:\app\product\11.2.0\dbhome_1\network\admin\tnsnames.ora # Generated by Oracle configuration tools. NHL = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.152.131)(PORT = 1522)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = NHL) ) ) ORCL = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.152.131)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = orcl) ) )
情况3:
listener.ora文件:
# listener.ora Network Configuration File: E:\app\product\11.2.0\dbhome_1\NETWORK\ADMIN\listener.ora # Generated by Oracle configuration tools. SID_LIST_ORCL = (SID_LIST = (SID_DESC = (GLOBAL_DBNAME = ORCL) (SID_NAME = ORCL) ) (SID_DESC = (GLOBAL_DBNAME = NHL) (SID_NAME = NHL) ) ) SID_LIST_TEST = (SID_LIST = (SID_DESC = (GLOBAL_DBNAME = TEST) (SID_NAME = TEST) ) ) ORCL = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.152.131)(PORT = 1521)) ) (DESCRIPTION = (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC)) ) ) TEST = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.152.131)(PORT = 1523)) )
tnsnames.ora文件:
# tnsnames.ora Network Configuration File: E:\app\product\11.2.0\dbhome_1\network\admin\tnsnames.ora # Generated by Oracle configuration tools. NHL = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.152.131)(PORT = 1522)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = NHL) ) ) ORCL = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.152.131)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = orcl) ) ) TEST = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.152.131)(PORT = 1523)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = test) ) )
改完配置并启动。
免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。