2014/04/02

Published 4月 02, 2014 by

Oracle Listener 教學

Oracle Listener Status教學

Listener啟動/關閉
Listener啟動在不同的Port
Oracle Listener Help
Client TNS設定



查看Listener的狀態:
$lsnrctl status
listener start 執行指令 lsnrctl start [listener-name]
$lsnrctl start
or
$lsnrctl start LSNR

STOP Oracle Listener
$lsnrctl stop

Restart Oracle Listener
$lsnrctl reload


設置第二個 Listener:
用途:用在Cluster Server或同一台有二個Instance

一個Instance只可以對應到一個Listener

Listener的設定檔(DB Server),兩個Listener,:
LSNR11521 Port
LSNR21522 Port
同時只有一個LSNR可以啟動,因為對應到的isntance是同樣一個
單獨啟動LSNR21522 Port:
$lsnrctl start LSNR2

Client端的tns設定,port1522 port



Oracle Listener Help
1. View Available Listener Commands
■ start - Start the Oracle listener
■ stop - Stop the Oracle listener
■ status - Display the current status of the Oracle listener
■ services - Retrieve the listener services information
■ version - Display the oracle listener version information
■ reload - This will reload the oracle listener SID and parameter files. This is equivalent to lsnrctl stop and lsnrctl start.
■ save_config - This will save the current settings to the listener.ora file and also take a backup of the listener.ora file before overwriting it. If there are no changes, it will display the message "No changes to save for LISTENER"
■ trace - Enable the tracing at the listener level. The available options are 'trace OFF', 'trace USER', 'trace ADMIN' or 'trace SUPPORT'
■ spawn - Spawns a new with the program with the spawn_alias mentioned in the listener.ora file
■ change_password - Set the new password to the oracle listener (or) change the existing listener password.
■ show - Display log files and other relevant listener information.


Reference:
http://rickyju.pixnet.net/blog/post/28234578-oracle-%3A-listener-shutdown-and-startup-procedures