日期:2014-05-16  浏览次数:20414 次

如何配置多个监听器不同端口
listener.ora配置如下
SID_LIST_LISTENER =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = PLSExtProc)
      (ORACLE_HOME = G:\10g\app\oracle\product\10.2.0\server)
      (PROGRAM = extproc)
    )
    (SID_DESC =
      (SID_NAME = crm)
      (ORACLE_HOME = G:\10g\app\oracle\product\10.2.0\server)
      (PROGRAM = crm)
    )
  )

LISTENER =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC_FOR_XE))
      (ADDRESS = (PROTOCOL = TCP)(HOST = cyl-PC)(PORT = 1521))
    )
  )
 
LISTENER2 =
  (DESCRIPTION_LIST =
  (DESCRIPTION =
  (ADDRESS = (PROTOCOL = TCP)(HOST = cyl-PC)(PORT = 1522))
  )
  )

SID_LIST_LISTENER2 =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = PLSExtProc)
      (ORACLE_HOME = G:\10g\app\oracle\product\10.2.0\server)
      (PROGRAM = extproc)
    )
  (SID_DESC =
  (GLOBAL_DBNAME = crm)
  (ORACLE_HOME = G:\10g\app\oracle\product\10.2.0\server)
  (SID_NAME = crm)
  )
  )  

tnsnames.ora配置如下
XE =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = cyl-PC)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = XE)
    )
  )
 
crm =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = cyl-PC)(PORT = 1522))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = crm)
    )
  ) 

EXTPROC_CONNECTION_DATA =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC_FOR_XE))
    )
    (CONNECT_DATA =
      (SID = PLSExtProc)
      (PRESENTATION = RO)
    )
  )

ORACLR_CONNECTION_DATA =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC_FOR_XE))
    )
    (CONNECT_DATA =
      (SID = CLRExtProc)
      (PRESENTATION = RO)
    )
  )
1 楼 nash01 2011-05-20  
前提要保证已经有一个sid的名字是crm的例程

可以用dbca创建这个crm例程