Sometimes God is love and you joke, yesterday very hard to configure the Oracle, can be used with PL/SQL Normal login, today suddenly lost. And the error is very strange, there is no hint of what error code. Enter the user name password, click Login after PL/SQL is not reflected, the direct card dead.
I was depressed, do not give hints how to solve the problem. It suddenly occurred to me that Oracle would certainly have a record of the logs. Check it out and there should be surprises.
Oracle Log Location: D:\app\NiuNiu\product\11.2.0\dbhome_1\database\oradim.log
Sure enough, two errors were found:
Tue June 23 15:32:41 2015
D:\app\NiuNiu\product\11.2.0\dbhome_1\bin\oradim.exe-startup-sid drp-usrpwd *-log Oradim.log-nocheck 0
Tue June 23 15:32:48 2015
ORA-00119:INVALID specification for system parameter Local_listener
Ora-00132:syntax error or unresolved network name ' LISTENER_DRP '
These two errors, such as those shown in the log: ORA-00119 and ORA-00132, may be caused by these two errors to cause PL/SQL not to log on properly. Find the source of the error, and solve both of these problems:
Scenario One: Check the Tnsname.ora file for this string, or add it as you wish.
LISTENER_DRP = (ADDRESS = (PROTOCOL = TCP)(HOST = Niu)(PORT = 1521))
where DRP sid,host your database as the host name.
Scenario Two: Tnsname.ora file there is no error in the case, there is also the possibility of this problem, can only take programme two.
Online to find a lot of information, the main meaning is to use SPFile to generate pfile, and then modify the Local_listener parameters, and then re-generate SPFile files, the steps are as follows:
1. Copy a pfile parameter file by SPFile (Note: pfile in Oracle refers to Init.ora files, such as the Pfile file created by the following command is "Initdrp.ora" ; spfile file is Spfiledrp.ora)
SQL> create pfile from spfile=‘D:\app\NiuNiu\product\11.2.0\dbhome_1\database\SPFILEDRP.ORA‘;
2, modify the Pfile parameter file (that is, modify the Init.ora file, that is, the Initdrp.ora file of this article)
After the first step, the $oracle_home/database directory generates file Init.ora, because my ORACLE instance name is DRP, so my pfile file is Initdrp.ora. Open the file in Notepad, locate the Local_listener line, and then modify its value to:
(ADDRESS_LIST=(Address=(Protocol=tcp) (Host=your_hostname)(Port=1521)))
Where the your_hostname is your host name.
3. Re-generate SPFile file Spfiledrp.ora
SQL> create spfile from pfile=‘D:\app\NiuNiu\product\11.2.0\dbhome_1\database\INITdrp.ORA‘;
4. Use the startup command to restart the database.
The entire process:
To learn to check the information in the Oracle error log, sometimes the error is not on the surface, we need to ask the bottom of the root.
Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.
"Oracle Error Collection": ORA-00119 & ORA-00132