简体   繁体   中英

how to install oracle client 11g on windows?

i am very new to oracle need to practice in this,so i decided to install oracle 11g in my private machine using this link oacle home i tried to install this package it installed but,i can't access any more it ask username and password i did't give anything like tat while installing,it didn't ask like anything while installing too.

SQL*Plus: Release 11.2.0.1.0 Production on Sun Jan 27 13:24:15 2013

Copyright (c) 1982, 2010, Oracle.  All rights reserved.

Enter user-name: sysdba
Enter password:
ERROR:
ORA-12560: TNS:protocol adapter error


Enter user-name:

Try sqlplus / as sysdba . You don't need a password then.

Then do you have ORACLE_HOME variable defined? If you do, is it pointing to the correct folder where the database software for the running database is stored? What happens if you remove the variable ORACLE_HOME?

Do you have the environment variable ORACLE_SID set to the name of the database?

Log in to the database using the user name SYSTEM and connect as SYSDBA. Oracle Enterprise Manager displays the Database Home page.

Use the password that you specified for the SYSTEM account during the installation.

Note: You can also log in to the Database Control using the SYS, SYSTEM, or SYSMAN accounts, or you can grant login privileges to other database users. If you log in as SYS, then you must connect as SYSDBA.


Use the following statement to start SQL*Plus and log in as the SYS user, connecting as SYSDBA:

$ $ORACLE_HOME/bin/sqlplus 
SQL> CONNECT SYS as SYSDBA
Enter password: SYS_password

For example, to log on as SYSTEM enter:

$ $ORACLE_HOME/bin/sqlplus 
SQL> CONNECT SYSTEM
Enter password: password

If you are logging on as SYS, you must connect as SYSDBA:

$ $ORACLE_HOME/bin/sqlplus 
SQL> CONNECT SYS as SYSDBA
Enter password: SYS_password

References:

Check the following links first. Follow them on the server machine where you run oracle instance, you will get your oracle instance started.

ORA-12560: TNS:protocol adaptor error

http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::p11_question_id:431775600346873836

If there still exists any TNS related error, maybe you need to check the tnsnames.ora and listener.ora files under $ORACLE_HOME/network/admin.

When you connect to oracle, the client(eg sqlplus) will try to find the oracle instance run on the server machine. It will report a TNS related error when it cannot find the server.

To solve the problem, you need to config the tnsname.ora file under your installation directory(by default it's $ORACLE_HOME/network /admin) first.

The basic format of the tnsnames.ora file is:

net_service_name=
 (description=
 (address=(protocol_address_information))
 (connect_data=
 (service_name=service_name)))

A sample tnsnames.ora entry might look like the following:

ORA_INSTANCE=
  (description=
    (address_list=
      (address = (protocol = TCP)(host = yourmachine)(port = 1521))
    )
    (connect_data =
      (service_name=ora_sid)
    )
  )

After this configuration, you can try:

sqlplus /@ORA_INSTANCE as sysdba;

Then the oracle client you installed will find the ORA_INSTANCE based on your configuration in the tnsnames.ora file. If the oracle server is listening, your connection will be established. BTW, you may need to look at the listener.ora on server machine if there is any error remaining.

I attached the following parameters that are commonly used in tnsnames.ora:

description : This tnsnames.ora parameter acts as a container for a connect descriptor. It can be embedded under the description_list parameter in the tnsnames.ora file.

description_list : This tnsnames.ora parameter defines a list of connect descriptors for a particular net service name .

address : This tnsnames.ora parameter defines a single listener protocol address. It can be embedded under the address_list or description parameters in the tnsnames.ora file.

address_list : This tnsnames.ora parameter defines multiple listener protocol addresses. It is not necessary if only one listener protocol address is used. It can be embedded under the description or description_list parameters in the tnsnames.ora file.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM