修改 ORACLE_HOME/network/admin/目錄下面的tnsnames.ora和listener.ora文件
1、tnsnames.ora (修改紅色的地方即可)
LISTENER_ORCL = (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.212)(PORT = 1521))
ORACLR_CONNECTION_DATA = (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521)) ) (CONNECT_DATA = (SID = CLRExtProc) (PRESENTATION = RO) ) )
ORCL = (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521)) ) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = orcl) ) ) |
2、listener.ora(僅修改紅色部分即可)
SID_LIST_LISTENER = (SID_LIST = (SID_DESC = (SID_NAME = CLRExtProc) (ORACLE_HOME = C:\oracle\product\11.2.0\dbhome_1) (PROGRAM = extproc) (ENVS = "EXTPROC_DLLS=ONLY:C:\oracle\product\11.2.0\dbhome_1\bin\oraclr11.dll") ) )
LISTENER = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521)) (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.212)(PORT = 1521)) ) )
ADR_BASE_LISTENER = C:\oracle |
最后好記住重啟監(jiān)聽服務(wù):OracleOraDb11g_home1TNSListener
|