How can I check all oracle versions and platforms that installed on windows machine from a command line or byscript ?
Till now I was using tnsping and check for the output but it only show the first version according to the path environment variable.
Is there a way to get this info from the registry and without actually connect to DB ?
Simplest method is to run command prompt and type sqlplus
it will show you the oracle version without actually logging into it.
Example: Run -> cmd
Microsoft Windows [Version 6.1.7601]
Copyright (c) 2009 Microsoft Corporation. All rights reserved.
C:\Users\xyz>sqlplus
SQL*Plus: Release 11.2.0.1.0 Production on Wed Jan 1 16:46:40 2014
Copyright (c) 1982, 2010, Oracle. All rights reserved.
Enter user-name:
You'll want to query the Oracle Inventory.
For every Oracle installation, there is an entry in the "Oracle inventory". By default, the Oracle inventory is located under "C:\Program Files\Oracle\Inventory". However, this location can be changed.
In the Registry, the location of the Oracle inventory is in "HKEY_LOCAL_MACHINE/SOFTWARE/ORACLE", where you'll find the key "inst_loc". There, you'll find an XML file containing all installed versions (inventory.xml). See the Oracle documentation for an example.
Go here and open with Notepad:
C:\Program Files (x86)\Oracle\Inventory\ContentsXML
C:\Program Files\Oracle\Inventory\ContentsXML
Open File:
inventory.xml
<?xml version="1.0" standalone="yes" ?>
<!-- Copyright (c) 1999, 2006, Oracle. All rights reserved. -->
<!-- Do not modify the contents of this file by hand. -->
<INVENTORY>
<VERSION_INFO>
<SAVED_WITH>11.1.0.6.0</SAVED_WITH>
<MINIMUM_VER>2.1.0.6.0</MINIMUM_VER>
</VERSION_INFO>
<HOME_LIST>
<HOME NAME="OraClient11g_home1" LOC="D:\Oracle\product\11.1.0\client_1" TYPE="O" IDX="1"/>
</HOME_LIST>
</INVENTORY>
Related
None of my browser are working whenever I query in browser I get the message "ORACLE DATABASE 10g EXPRESS EDITION LICENSE AGREEMENT". What to do?
I too faced same issue and fixed the issue by following these steps. Please have a try.
From Start | Run open a command window. Assuming your environmental variables are set correctly start with the following:
C:\>sqlplus /nolog
SQL*Plus: Release 10.2.0.1.0 - Production on Tue Aug 26 10:40:44 2008
Copyright (c) 1982, 2005, Oracle. All rights reserved.
SQL> connect
Enter user-name: system
Enter password: <enter password if will not be visible>
Connected.
SQL> Exec DBMS_XDB.SETHTTPPORT(3010); [Assuming you want to have HTTP going to this port]
PL/SQL procedure successfully completed.
SQL>quit
Now restart the PC and check.
I am trying to run SQL*Plus to start my database but I keep getting errors:
oracle#ictd23:~$ sqlplus /nolog
SQL*Plus: Release 11.2.0.1.0 Production on Mon Oct 26 15:52:37 2015
Copyright (c) 1982, 2009, Oracle. All rights reserved.
SQL> startup
ORA-12547: TNS:lost contact
oracle#ictd23:~$ sqlplus system#orcl
SQL*Plus: Release 11.2.0.1.0 Production on Mon Oct 26 16:02:14 2015
Copyright (c) 1982, 2009, Oracle. All rights reserved.
Enter password:
ERROR:
ORA-12541: TNS:no listener
When I try to start the listener I also get an error:
oracle#ictd23:~$ lsnrctl start
lsnrctl: command not found.
Can anyone help with this problem?
Most probably lsnrctl command is not in the PATH (either because your shell environment is not set for oracle), try command as below
$ $ORACLE_HOME/bin/lsnrctl start
Or set the environment using coraenv or oraenv scripts and check if $ORACLE_HOME/bin is present in your PATH
# For cshell
% source /usr/local/bin/coraenv
% lsrnctl start
# For other shell (eg. bash/sh/k-shell)
$ . /usr/local/bin/oraenv
$ lsnrctl start
See that ORACLE_SID and ORACLE_HOME are set properly. You can set using the below eg:
ORACLE_HOME=/home/oracle/app/oracle/product/11.2.0/dbhome_1;
export ORACLE_HOME
ORACLE_SID=oracle;
export ORACLE_SID
I have received some data in Oracle DMP format that I am trying to use imp to import into an Oracle database.
I am running the command:
imp <user>/<pass>#<tns> FILE=SI_DESIGN_SETS_12Mar2015.dmp
I get the result:
Import: Release 11.2.0.1.0 - Production on Fri Mar 20 11:59:37 2015
Copyright (c) 1982, 2009, Oracle and/or its affiliates. All rights reserved.
IMP-00058: ORACLE error 1031 encountered
ORA-01031: insufficient privilegesUsername:
Running this command with other dmp files has worked in the past. Any ideas on how to get past this error?
In case anyone is wondering, I managed to get them to regenerate them and bizarrely adding "FEEDBACK=1000" to the import command actually made some of the old ones work!
I am attempting to connect to an Oracle 11.2.0.2 64 bit database from a Win 7 and Win 8.1 machine with the Oracle 11.2.0.4 32 bit client. I can successfully ping the server and TNSPing the listener on both machines. But when I try to log into SQLPLus using system and my password I receive ORA-12560 TNS:Protocol Adapter Error. I can log into SQLPlus on the server. Any ideas? DB has been restarted as well as the listener. ORACLE_SID is set. I'm stuck...
If I'm following what you're seeing, it sounds like you just want to set the LOCAL enviroment variable on your Windows boxes to the TNS alias; then you don't have to supply that as you try to connect.
This is with the 12c instant client but the effect is the same with the 11g client. Specifying an alias as the connect strings works (the ORA-01017 is still coming from the DB):
c:\Program Files\instantclient_12_1>sqlplus -l x/y#abcd
SQL*Plus: Release 12.1.0.2.0 Production on Mon Feb 23 17:12:34 2015
Copyright (c) 1982, 2014, Oracle. All rights reserved.
ERROR:
ORA-01017: invalid username/password; logon denied
Connecting without the alias gets your ORA-12560:
c:\Program Files\instantclient_12_1>sqlplus -l x/y
SQL*Plus: Release 12.1.0.2.0 Production on Mon Feb 23 17:11:58 2015
Copyright (c) 1982, 2014, Oracle. All rights reserved.
ERROR:
ORA-12560: TNS:protocol adapter error
But if I set LOCAL then I can connect as if I had specified the alias:
c:\Program Files\instantclient_12_1>set LOCAL=abcd
c:\Program Files\instantclient_12_1>sqlplus -l x/y
SQL*Plus: Release 12.1.0.2.0 Production on Mon Feb 23 17:14:23 2015
Copyright (c) 1982, 2014, Oracle. All rights reserved.
ERROR:
ORA-01017: invalid username/password; logon denied
You don't need to have ORACLE_SID set as that is only used for bequeath connections where the client and server are on the same box.
when i try to connect our programme with oracle with this command
sqlplus crbt/crbt#crbt_new here crbt is the username and crbt_new is the password.
it is giving error this
SQL*Plus: Release 9.2.0.4.0 - Production on Tue Jan 4 10:32:42 2011
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
ERROR:ORA-12541: TNS:no listener
So please tell me where this is wrong
Below are the possibilities for this:
1) Listener might be down
2) When database is not up, 'TNS: no listener' error appears
3) If the TNS entries are not correct.
Ex: The TNS entry of crbt_new database might have the port number mentioned as 1531, but in real the Database would be listening on port 1521