IT_Revisions vorgabe, Listener passwort setzen.
-- Listener starten, Security ist noch off.
LSNRCTL> start
Starting /opt/oracle/product/9.2.0.6/bin/tnslsnr: please wait...
TNSLSNR for Solaris: Version 9.2.0.6.0 - Production
System parameter file is /opt/oracle/admin/network/listener.ora
Log messages written to /opt/oracle/product/9.2.0.6/network/log/listener.log
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=DEFXXXF2)(PORT=1515)))
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=ASB6551T)))
Connecting to (ADDRESS=(PROTOCOL=TCP)(Host=DEFXXXF2)(Port=1515))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Solaris: Version 9.2.0.6.0 - Production
Start Date 10-SEP-2007 14:23:58
Uptime 0 days 0 hr. 0 min. 0 sec
Trace Level off
Security OFF
SNMP OFF
Listener Parameter File /opt/oracle/admin/network/listener.ora
Listener Log File /opt/oracle/product/9.2.0.6/network/log/listener.log
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=DEFXXXF2)(PORT=1515)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=ASB6551T)))
Services Summary...
Service "ASB6551T" has 1 instance(s).
Instance "ASB6551T", status UNKNOWN, has 1 handler(s) for this service...
The command completed successfully
LSNRCTL> set password
Password: gogo
The command completed successfully
-- Listener Password ändern, was ich vorher mit set password gesetzt habe.
LSNRCTL> change_password
Old password: gogo
New password: master
Reenter new password: master
Connecting to (ADDRESS=(PROTOCOL=TCP)(Host=DEFXXXF2)(Port=1515))
Password changed for LISTENER
The command completed successfully
-- passwort wird benötigt.
LSNRCTL> status
Connecting to (ADDRESS=(PROTOCOL=TCP)(Host=DEFXXXF2)(Port=1515))
TNS-01169: The listener has not recognized the password
LSNRCTL> set password
Password: master
The command completed successfully
-- Erst jetzt geht es
LSNRCTL> status
Connecting to (ADDRESS=(PROTOCOL=TCP)(Host=DEFXXXF2)(Port=1515))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Solaris: Version 9.2.0.6.0 - Production
Start Date 10-SEP-2007 14:23:58
Uptime 0 days 0 hr. 6 min. 26 sec
Trace Level off
Security ON
SNMP OFF
Listener Parameter File /opt/oracle/admin/network/listener.ora
Listener Log File /opt/oracle/product/9.2.0.6/network/log/listener.log
-- durch sichern des Passwords wir eine neue listener.ora erstellt.
LSNRCTL> save_config
Connecting to (ADDRESS=(PROTOCOL=TCP)(Host=DEFXXXF2)(Port=1515))
Saved LISTENER configuration parameters.
Listener Parameter File /opt/oracle/admin/network/listener.ora
Old Parameter File /opt/oracle/admin/network/listener.bak
The command completed successfully
root@DEFXXXf2 # ls -la
total 16
lrwxrwxrwx 1 root root 54 Sep 10 14:13 listener.bak ->
/opt/oracle/product/9.2.0.6/network/admin/listener.ora
-rw-r--r-- 1 oracle dba 3762 Sep 10 14:31 listener.ora
lrwxrwxrwx 1 root root 54 Sep 10 14:13 tnsnames.ora ->
/opt/oracle/product/9.2.0.6/network/admin/tnsnames.ora
-- save_config fügt neuen eintrag in die listener Datei.
root@DEFXXXf2 # more listener.ora
…….
……
#----ADDED BY TNSLSNR 10-SEP-2007 14:31:18---
PASSWORDS_LISTENER = B44DB282C54F4AE2
#--------------------------------------------
-- Keine eingabe mehr, ohne Password zu setzen.
DEFXXXf2@oracle[ASB6551T]: lsnrctl
LSNRCTL> status
Connecting to (ADDRESS=(PROTOCOL=TCP)(Host=DEFXXXF2)(Port=1515))
TNS-01169: The listener has not recognized the password'
LSNRCTL> set password
Password: master
The command completed successfully
LSNRCTL> status
Connecting to (ADDRESS=(PROTOCOL=TCP)(Host=DEFXXXF2)(Port=1515))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Solaris: Version 9.2.0.6.0 - Production
Start Date 10-SEP-2007 14:23:58
Uptime 0 days 0 hr. 12 min. 6 sec
Trace Level off
Security ON
SNMP OFF
Listener Parameter File /opt/oracle/admin/network/listener.ora
Listener Log File /opt/oracle/product/9.2.0.6/network/log/listener.log
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=DEFXXXF2)(PORT=1515)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=ASB6551T)))
Services Summary...
Service "ASB6551T" has 1 instance(s).
Instance "ASB6551T", status UNKNOWN, has 1 handler(s) for this service...
Service "ASB6551T.agis" has 1 instance(s).
Instance "ASB6551T", status READY, has 1 handler(s) for this service...
The command completed successfully
LSNRCTL>
-- Noch eine kleine Hilfe falls man das password vergessen hat.
You forgot your password.
If the password is in cleartext, look for entry PASSWORDS_<listener_name>
in "listener.ora". If it's encrypted, then you have to kill the tnslsnr process
using kill -9. Then remove the line PASSWORDS_<listener_name> from the listener
.ora file. Start the listener and set the password using the instructions above.
Oracle Note 92602.1 How to password protect your listener
-- Listener STOP / START Script
FFZDA4@oracle[SCC01T]: more ora_listener
#!/bin/ksh # # # Listener Stop, da ein Password hinterlegt ist # Vorgabe von der Revision (GB) # # TNS_ADMIN="/opt/oracle/admin/network" case "$1" in start) if [ -f ${TNS_ADMIN}/listener.ora ]; then echo "Starting Oracle Listener ..." PW=$(grep -i passwords_listener $TNS_ADMIN/listener.ora | cut -d= -f2) lsnrctl <<EOF set password $PW start #status EOF fi ;; stop) if [ -f ${TNS_ADMIN}/listener.ora ]; then echo "Finished Oracle Listener." PW=$(grep -i passwords_listener $TNS_ADMIN/listener.ora | cut -d= -f2) lsnrctl <<EOF set password $PW stop #status EOF fi ;; esac