Error: When you attempt to connect to your Oracle DB instance, you’ll receive below error
—————————
ODBC 32Bit Test Program
—————————
SQLSTATE: S1000
Native Error Code:12541
Driver Message:[Oracle][ODBC][Ora]ORA-12541: TNS:no listener
Need Any suggestions to avoid error ?
—————————
Yes No
—————————
Cause and Troubleshooting:
Cause: The Oracle Instance is NOT running on the Oracle DB server.
login as: root
[email protected]’s password:
Last login: Wed Feb 19 15:35:19 2014 from 192.168.1.91
[root@OraProd01 ~]# lsnrctlLSNRCTL for Linux: Version 8.1.6.0.0 – Production on 19-FEB-2014 16:36:28
(c) Copyright 1998, 1999, Oracle Corporation. All rights reserved.
Welcome to LSNRCTL, type "help" for information.
LSNRCTL> status
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.2.101)(PORT=1521)) )
TNS-01103: Protocol specific component of the address is incorrectly specified
TNS-12541: TNS:no listener
TNS-12560: TNS:protocol adapter error
TNS-00511: No listener
Linux Error: 111: Connection refused
LSNRCTL> start
Starting /opt/oracle/product/8.1.6/bin/tnslsnr: please wait…TNSLSNR for Linux: Version 8.1.6.0.0 – Production
NL-00280: error creating log stream /opt/oracle/product/8.1.6/network/log/listener.log
NL-00278: cannot open log file
SNL-00016: snlfohd: error opening file
Linux Error: 13: Permission deniedLSNRCTL> exit
[root@OraProd01 ~]# ls -l /opt/oracle/product/8.1.6/network/log/listener.log
-rw-r–r– 1 oracle dba 2147483647 Feb 19 12:15 /opt/oracle/product/8.1.6/network/log/listener.log
[root@OraProd01 ~]# lsnrctl startLSNRCTL for Linux: Version 8.1.6.0.0 – Production on 19-FEB-2014 16:43:15
(c) Copyright 1998, 1999, Oracle Corporation. All rights reserved.
Starting /opt/oracle/product/8.1.6/bin/tnslsnr: please wait…
TNSLSNR for Linux: Version 8.1.6.0.0 – Production
NL-00280: error creating log stream /opt/oracle/product/8.1.6/network/log/listener.log
NL-00278: cannot open log file
SNL-00016: snlfohd: error opening file
Linux Error: 13: Permission denied[root@OraProd01 ~]#
Fix:
Fix the permissions or remove the reported log file, then start the TNS Listener service.
[root@OraProd01 ~]# mv /opt/oracle/product/8.1.6/network/log/listener.log /opt/oracle/product/8.1.6/network/log/listener-old.log
[root@OraProd01 ~]# ls -l /opt/oracle/product/8.1.6/network/log/listener.log
ls: /opt/oracle/product/8.1.6/network/log/listener.log: No such file or directory
[root@OraProd01 ~]# lsnrctl startLSNRCTL for Linux: Version 8.1.6.0.0 – Production on 19-FEB-2014 16:46:00
(c) Copyright 1998, 1999, Oracle Corporation. All rights reserved.
Starting /opt/oracle/product/8.1.6/bin/tnslsnr: please wait…
TNSLSNR for Linux: Version 8.1.6.0.0 – Production
System parameter file is /opt/oracle/product/8.1.6/network/admin/listener.ora
Log messages written to /opt/oracle/product/8.1.6/network/log/listener.log
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.2.101)(PORT=1521)))
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC)))Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.2.101)(PORT=1521)))
STATUS of the LISTENER
————————
Alias LISTENER
Version TNSLSNR for Linux: Version 8.1.6.0.0 – Production
Start Date 19-FEB-2014 16:46:00
Uptime 0 days 0 hr. 0 min. 0 sec
Trace Level off
Security OFF
SNMP OFF
Listener Parameter File /opt/oracle/product/8.1.6/network/admin/listener.ora
Listener Log File /opt/oracle/product/8.1.6/network/log/listener.log
Services Summary…
PLSExtProc has 1 service handler(s)
OraProd01 has 1 service handler(s)
The command completed successfully
[root@OraProd01 ~]#