This discussion is archived
1 2 Previous Next 19 Replies Latest reply: May 9, 2012 11:23 PM by gk RSS

remote instance access

gk Newbie
Currently Being Moderated
i have tried to connect db from client system ,

i able to connect if i give command like this

sqlplus user/pwd@xxx.xxx.xxx.xxx/sid name as sysdba for sys user.

i already entered into tnsnames.ora file in name like
ORCL=
(DESCRIPTION=
(ADDRESS=(PROTOCOL=TCP)(HOST=xxx.xxx.xxx.xxx)

(PORT=1521))
(CONNECT_DATA= (SID=orcl)
)
)

after i give command like

sqlplus user/pwd@orcl

its not connecting.

can u help me

share ur ideas....
  • 1. Re: remote instance access
    anand prakash - oracle Pro
    Currently Being Moderated
    sqlplus user/pwd@orcl
    its not connecting.>

    What is the oracle version. What is the error you get? What is the outout of

    tnsping orcl

    Anand
  • 2. Re: remote instance access
    hitgon Expert
    Currently Being Moderated
    Hi,

    please check that database is ping or not

    tnsping orcl

    share the contents of tnsnames.ora file

    Regards
    Hitgon
  • 3. Re: remote instance access
    JamesGordon Explorer
    Currently Being Moderated
    The first example is instant access style connect.
    The second will try and use the TNSNames files.
    As the other poster suggests, what is the output of tnsping orcl?
    What error message are you getting?
    TNSPing will show you what directory it is using to get the TNSNames and SQLNet files. Ensure that that directory is the same directory you have altered the TNSNames.ora file in.
  • 4. Re: remote instance access
    ThierryH. Pro
    Currently Being Moderated
    Hi,

    you are connecting to you database (in first example) using the Easy Connect method.
    The second will use the TNS entries where your problem must be....
    http://www.dba-oracle.com/oracle_news/2006_04_04_connect_using_easy_connect.htm

    Post your listener.ora (from server), sqlnet.ora and tnsnames.ora

    HTH,
    Thierry
  • 5. Re: remote instance access
    Fran Guru
    Currently Being Moderated
    what error do you have? user/password incorrect?

    If you are trying to connect from the machine hosting, it will never validate or verify the password of sys because it gets authenticated from OS User Group:

    SQL> conn sys/0000 as sysdba
    Conectado.
    SQL> conn sys/1234 as sysdba
    Conectado.
    SQL> conn sys/AAAA as sysdba
    Conectado.
    SQL> conn sys/AaAB as sysdba
    Conectado.
    SQL> conn sys/B123 as sysdba
    Conectado.
    SQL> conn sys/CBA1 as sysdba
    Conectado.

    This is why i think you can connect to the database.
  • 6. Re: remote instance access
    gk Newbie
    Currently Being Moderated
    i getting error like this....in that another problem is i already iinstalled oracle db 10g in one drive now i installed oracle developer in another drive
    tnsping orcl
    TNS Ping Utility for 32-bit Windows: Version 10.1.0.4.2 - Production on 07-MAY-2
    012 18:58:21

    Copyright (c) 1997, 2003, Oracle. All rights reserved.

    Used parameter files:
    G:\DevSuiteHome_1\network\admin\sqlnet.ora

    TNS-03505: Failed to resolve name



    i have oracle db on my system, if i ping that getting reply like below
    C:\Users\svss3>tnsping sidname

    TNS Ping Utility for 32-bit Windows: Version 10.1.0.4.2 - Production on 07-MAY-2
    012 18:59:47

    Copyright (c) 1997, 2003, Oracle. All rights reserved.

    Used parameter files:
    G:\DevSuiteHome_1\network\admin\sqlnet.ora


    Used TNSNAMES adapter to resolve the alias
    Attempting to contact (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = name)(P
    ORT = xxxx)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = sid)))
    OK (0 msec)
  • 7. Re: remote instance access
    anand prakash - oracle Pro
    Currently Being Moderated
    Hi,

    Seems like you don;t have ORCL entry in G:\DevSuiteHome_1\network\admin\tnsnames.ora file. Once you put it, do the tnsping and check --
    orcl =
           (DESCRIPTION =
             (ADDRESS_LIST =
               (ADDRESS = (PROTOCOL = TCP)(HOST = xxxxxxxxxxxx)(PORT = 1521))
             )
             (CONNECT_DATA =
               (SERVICE_NAME = orcl)
             )
           )
    Anand
  • 8. Re: remote instance access
    gk Newbie
    Currently Being Moderated
    hi thanks for ur information,its working now ,but ihave installed oracle db and developer suit also,for both these tnsname file is there.

    C:\Users\svss3>tnsping orcl

    TNS Ping Utility for 32-bit Windows: Version 10.1.0.4.2 - Production on 07-MAY-2
    012 19:34:14

    Copyright (c) 1997, 2003, Oracle. All rights reserved.

    Used parameter files:
    G:\DevSuiteHome_1\network\admin\sqlnet.ora

    TNS-03505: Failed to resolve name

    Above given path is used parameterfile is G:\DevSuiteHome_1\network\admin\sqlnet.ora
    is for developer suit one,

    but i enter the path for remote connections in oracle db tnsname file.

    its is necessary to entered all in developer tnsnames file whatever in db tnsname file..

    or how to change the setting...
  • 9. Re: remote instance access
    JamesGordon Explorer
    Currently Being Moderated
    When you install more than one Oracle product you tend to have more than one network/admin directory. Dependant upon the which Oracle home is first in the path, and it will normally put the last installed frst in the path, it will use that home for the TNSNames file.

    So if you install the client then dev tools into two seperate homes it will use G:\DevSuiteHome_1\network\admin\network\admin\tnsnames.ora and not c:\client\network\admin\tnsnames.ora.

    SO goto G:\DevSuiteHome_1\network\admin and edit the tnsnames.ora file there with the name of the database and then run tnsping again.

    What's the result now?
  • 10. Re: remote instance access
    gk Newbie
    Currently Being Moderated
    hi i did it,i went to g:\dev\....tnsname.ora i copied all tnsnames from db to g:\dev\....tnsname.ora and pasted it.now its working fine

    thanks ur reply for all;
  • 11. Re: remote instance access
    gk Newbie
    Currently Being Moderated
    hi all,

    Before i install the developer suit ,i can able to connect database like this

    SQL>connect /as sysdba

    but now i display error like

    SQL> connect /as sysdba
    ERROR:
    ORA-12560: TNS:protocol adapter error
    now i need give like this command then only it connect

    SQL>connect sys/oracle@agile2 as sysdba;
    connected.

    what i have to do to use first command use to connect .

    any suggestion
  • 12. Re: remote instance access
    JamesGordon Explorer
    Currently Being Moderated
    Ensure that the line in sqlnet.ora is uncommented to allow you to remotly connect as sysdba...

    SQLNET.AUTHENTICATION_SERVICES= (NTS)
  • 13. Re: remote instance access
    gk Newbie
    Currently Being Moderated
    yes SQLNET.AUTHENTICATION_SERVICES= (NTS)
  • 14. Re: remote instance access
    EdStevens Guru
    Currently Being Moderated
    gk wrote:
    hi all,

    Before i install the developer suit ,i can able to connect database like this

    SQL>connect /as sysdba

    but now i display error like

    SQL> connect /as sysdba
    ERROR:
    ORA-12560: TNS:protocol adapter error
    now i need give like this command then only it connect

    SQL>connect sys/oracle@agile2 as sysdba;
    connected.

    what i have to do to use first command use to connect .

    any suggestion
    what is the value of ORACLE_HOME and ORACLE_SID when this happens?
1 2 Previous Next

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points