cancel
Showing results for 
Search instead for 
Did you mean: 

TNS-12541: TNS:no listener Error

Former Member
0 Kudos

Hi,

We have changed our IP address to one of our SAP system but unable to start SAP after the change IP activity.

I am getting an error when trying to start our SAP system.

Below are the steps I have done to start the SAP system.

I am suspecting that the error is due to the ports used in Steps 4 and 5 (in Bold BLUE font)

Please advise. Thank you.

1 - Execute startsap

                    Message log:     No SQL*Net V2 connect to SID available.

                                  Check that the listener is running: "lsnrctl status".

                                                      Start the listener as user oraedr: "lsnrctl start".

                                  /usr/sap/SID/SYS/exe/run/startdb: Terminating with error code 14

                                                  DB startup failed

2 - Run lsnrctl start

                    Message log:           TNS-01106: Listener using listener name LISTENER has already been started

3 - Execute sqlplus

          Message log:      sqlplus /nolog

                                   SQL*Plus: Release 10.2.0.2.0 - Production on Mon Jan 21 13:04:12 2013

                                    Copyright (c) 1982, 2005, Oracle.  All Rights Reserved.

                                    SQL> connect / as sysdba

                                    Connected.

 

4 - Check startdb.log

                    Message log:           Used parameter files:

                                   /usr/sap/SID/SYS/profile/oracle/sqlnet.ora

                                                   Used TNSNAMES adapter to resolve the alias

                                   Attempting to contact (DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (COMMUNITY = SAP.WORLD) (PROTOCOL = TCP)                                    (HOST = MYHOST) (PORT = 1527)))                                                             (CONNECT_DATA = (SID = SID) (GLOBAL_NAME = SID.WORLD)))

                                                       TNS-12535: TNS:operation timed out

                                                       V2 connect is not available. Terminating

                                                       /usr/sap/SID/SYS/exe/run/startdb: Terminating with error code 14

5 - Execute tnsping myIP

                    Message log:           Used parameter files:

                                                       /usr/sap/SID/SYS/profile/oracle/sqlnet.ora

                                                       Used HOSTNAME adapter to resolve the alias

                                                       Attempting to contact (DESCRIPTION=(CONNECT_DATA=(SERVICE_NAME=myIP))(ADDRESS=(PROTOCOL=TCP)(HOST=myIP)(PORT=1521)))

                                                       TNS-12541: TNS:no listener

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

You can refer below url for IP Address change.

http://scn.sap.com/thread/777972

With Regards,

V Srinivasan

Former Member
0 Kudos

Hi Srinivasan,

We're able to change the IP add of our server but we're unable to get the SAP system running because of the error.

former_member188883
Active Contributor
0 Kudos

Hi Marvin,

You need to check whether this command works ping Myhost ( without IP address) and see what IP it shows

Regards,

Deepak Kori

Former Member
0 Kudos

Hi Deepak,

When I ping MyHost, it returned with the old IP address and not the new IP.

This is a network issue right? Thanks.

Former Member
0 Kudos

Hi Deepak,

Below is what it showed me.

MyHost:orasid 12> ping MyHost

PING MyHost: (131.122.123.10): 56 data bytes

----MyHost PING Statistics----

385 packets transmitted, 0 packets received, 100% packet loss

former_member188883
Active Contributor
0 Kudos

Hi Marvin,

Yes. It is indeed a network hostname resolution issue. Either you may check again whether /etc/hosts files are maintained correctly. Remove instances of old IP addresses.

Ensure that DNS entries are updated correctly with the new IP addresses.

Once this is done , you may check tnsping <SID> and see the results.

Regards,

Deepak Kori

Former Member
0 Kudos

Hi Marvin,

Try to flush your server DNS and see it picks the new IP address. 

$ sudo /etc/init.d/nscd restart

OR

# service nscd restart

Former Member
0 Kudos

Hi Deepak,

Thanks for coming up with the solution of removing the old IP in /etc/hosts file. I was able to get the SAP system up and running again.

To all those who have extended their efforts to resolve this issue, thank you very much for your assistance. I appreciate all your efforts to help and share knowledge to everyone in need.

Answers (1)

Answers (1)

former_member188883
Active Contributor
0 Kudos

Hi Marvin,

You need to adjust the new IP in listener.ora file location in oracle home as well as /sapmnt/<SID>/profile/oracle locations.

Regards,

Deepak Kori

Former Member
0 Kudos

Hi Deepak Kori,

Thanks for the response.

Can you check what needs to adjust here?

sidadm 54> cat listener.ora

################

# Filename......: listener.ora

# Created.......: created by SAP AG, R/3 Rel. >= 6.10

# Name..........:

# Date..........:

# @(#) $Id: //bc/700-1_REL/src/ins/SAPINST/impl/tpls/ora/ind/LISTENER.ORA#4 $

################

ADMIN_RESTRICTIONS_LISTENER = on

LISTENER =

  (ADDRESS_LIST =

        (ADDRESS =

          (PROTOCOL = IPC)

          (KEY = SID.WORLD)

        )

        (ADDRESS=

          (PROTOCOL = IPC)

          (KEY = SID)

        )

        (ADDRESS =

          (COMMUNITY = SAP.WORLD)

          (PROTOCOL = TCP)

          (HOST = MYHOST)

          (PORT = 1527)

        )

  )

STARTUP_WAIT_TIME_LISTENER = 0

CONNECT_TIMEOUT_LISTENER = 10

TRACE_LEVEL_LISTENER = OFF

SID_LIST_LISTENER =

  (SID_LIST =

    (SID_DESC =

      (SID_NAME = SID)

      (ORACLE_HOME = /oracle/SID/102_64)

    )

    (SID_DESC =

      (SID_NAME = SID)

      (ORACLE_HOME = /oracle/SID/102_64)

    )

  )

former_member188883
Active Contributor
0 Kudos

Hi Marvin,

The listener.ora file looks ok and requires no change since you are using hostname.

Just check the entries in /etc/hosts file whether correct entry has been maintained

<new ip number> hostname.

Ensure that when you use ping hostname it resolves to the new ip address you have changed to.

If possible share the entries from your /etc/hosts file.

Regards,

Deepak Kori

Former Member
0 Kudos

Hi Deepak,

To answer your comments above:

Just check the entries in /etc/hosts file whether correct entry has been maintained

      - Yes I already have added the new ip to /etc/hosts file

Ensure that when you use ping hostname it resolves to the new ip address you have changed to.

          - i have used nslookup MyHost

          - nslookup new IP

          - both resulted to Unknown server name, can't find MyHost: No response form server

Am I doing it right?

Please advise. Thank you.

Former Member
0 Kudos

You need to check TNSNAMES.ORA file also as <sid>adm user.

Regards,

Roman

Former Member
0 Kudos

Hi Marvin,

Check the entries in the tnsnames.ora file at the location  /usr/sap/SID/SYS/profile/oracle/  .

Also check the entries in listener.ora file if it exists in this path and adjust it as well.

Also check the tnsnames.ora file at /oracle/SID/102_64/network/admin. Make sure the port mentioned in these files match . (either 1521 or 1527)

Regards

Amit

former_member188883
Active Contributor
0 Kudos

Hi Marvin,

Could you check ping Myhost ? What is the result

Regards,

Deepak Kori

Former Member
0 Kudos

Hi Amit,

The tnsnames does exist in /usr/sap/SID/SYS/profile/oracle/ but the listener.ora doesnt exist.

Listener.ora does exist in /oracle/SID/102_64/network/admin as well as tnsnames.ora.

Both are present in that directory.

Then the tnsnames.ora has port 1527.

Also please note that the server has 2 SAP systems installed.

If I start listener from one system, the other will not start.

Below is the error log.

Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=SID.WORLD)))

Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=SID)))

Error listening on: (ADDRESS=(COMMUNITY=SAP.WORLD)(PROTOCOL=TCP)(HOST=MyHost)(PORT=1527))

TNS-12542: TNS:address already in use

TNS-12560: TNS:protocol adapter error

  TNS-00512: Address already in use

   IBM/AIX RISC System/6000 Error: 67: Address already in use

Listener failed to start. See the error message(s) above...

Former Member
0 Kudos

Hi Deepak,

I was able to ping MyHost from cmd prompt by pinging the ip address

Former Member
0 Kudos

Hi Roman,

The file has this.. Isn't this correct?

-rw-r--r--    1 orasid   dba             506 Oct 05 2010  tnsnames.ora

Former Member
0 Kudos

>> The tnsnames does exist in /usr/sap/SID/SYS/profile/oracle/ but the listener.ora doesnt exist.

In this folder only tnsnames.ora and sqlnet.ora files are required.

For info about several oracle listener services on one server please read Note 562403 - FAQ: Oracle Net, p.13 Do I require a dedicated listener for each database instance?

Regards,

Roman


Former Member
0 Kudos

OK ,If there are two SAP instances running on this database .Try to start the listener with the ora<sid> user. Since there is only one database instance ,you only need one listener.

lsnrctl stop

lsnrctl start

lsnrctl status

Now check that the tnsnames.ora and listener.ora file has same port (1527 or 1521) in /oracle/SID/102_64/network/admin.

Secondly for both the SAP instances check that the tnsnames.ora in /usr/sap/SID/SYS/profile/oracle/ also has the same port.

Start the database.

Do a tnsping <DBSID> as user ora<sid> .Check the outcome.It should connect first.

Then as the user <sid>adm (for both SAP instances)  fire the command R3trans -d before starting the SAP system.This will check the database connectivity. Check the errors in file trans.log in the same directory.

Paste the error logs here if any .Also attach the tnsnames.ora and listener.ora file.

Thanks

Amit