I have logged in as system user.
So I have two plugable databases
1) PDB$SEED
2) PDBORCL
Now I want to alter session and need to set the container to pdborcl . But it is giving me error like below.
SQL> ALTER SESSION SET CONTAINER = pdborcl;
ERROR:
ORA-65024: Pluggable database PDBORCL is not open.
Note: I also changed my tsnames.ora file like below
# tnsnames.ora Network Configuration File: D:\app\SgMadankar\virtual\product\12.2.0\dbhome_1\network\admin\tnsnames.ora
# Generated by Oracle configuration tools.
LISTENER_ORCL =
(ADDRESS = (PROTOCOL = TCP)(HOST = LOCALHOST)(PORT = 1521))
ORACLR_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
)
(CONNECT_DATA =
(SID = CLRExtProc)
(PRESENTATION = RO)
)
)
ORCL =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = LOCALHOST)(PORT = 1521))
(CONNECT_DATA =
(SERVICE = DEDICATED)
(SERVICE_NAME = orcl)
)
)
PDBORCL =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = pdborcl)
)
)
1- You need to connect with a user with SYSDBA privilege, SYS would be good.
2- You need to open your pluggable database.
SQL> ALTER PLUGGABLE DATABASE ALL OPEN;
Related
When I try to connect I get error:
I disabled firewall, started the OracleServiceXE, but still get error.
When I use command lsnrctl status, I get:
lsnrctl start:
My tnsnames.ora file looks like that:
# tnsnames.ora Network Configuration File: C:\app\Coi\product\18.0.0\dbhomeXE\NETWORK\ADMIN\tnsnames.ora
# Generated by Oracle configuration tools.
XE =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.0.0)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = XE)
)
)
LISTENER_XE =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.0.8)(PORT = 1521))
ORACLR_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
)
(CONNECT_DATA =
(SID = CLRExtProc)
(PRESENTATION = RO)
)
I'm trying to make a simple distributed database with Oracle Database 11g. I've created 2 virtual machines, both windows 7 and I've set up static ip for everyone and then I've modified the listener.ora. For exmaple the listener.ora for first VM looks like this:
I've check from my PC with ping to see if I get a reply and it works.
Then I've modified the tnsnames.ora from my PC as shown:
LISTENER_ORCL =
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
ORACLR_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
)
(CONNECT_DATA =
(SID = CLRExtProc)
(PRESENTATION = RO)
)
)
ORCL =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = orcl)
)
)
SERVER1 =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.75.131)(PORT = 1521))
(CONNECT_DATA =
(SID = XE)
)
)
SERVER2 =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.75.130)(PORT = 1521))
(CONNECT_DATA =
(SID = XE)
)
)
When I try to create a connection with hostname: 192.168.75.131(first VM) I'm getting the follow error: Status : Failure -Test failed: ORA-01017: invalid username/password; logon denied.
The username and password are correct.
Try to connect utilizing sqlplus on Server1 - the devops way - repeatable
C:\>set LOCAL=192.168.75.131/XE
C:\>sqlplus system/system_password
SQL>connect admin/admin_password
You can also try:
C:\>set LOCAL=localhost/XE
C:\>sqlplus system/system_password
SQL>connect admin/admin_password
Best of luck!
Is your database set to use case-sensitive passwords?
That could be the issue.
I am getting this error when trying to connect to freshly installed Oracle Enterprise from either SQL Developer or Net Manager. I did try every solution that I could find with no luck.
I am trying to connect with a system account and I am able to log in with sqlplus, so I know that my credentials are correct.
listener.ora
SID_LIST_LISTENER =
(SID_LIST =
(SID_DESC =
(PROGRAM = extproc)
(ENVS = "EXTPROC_DLLS=ONLY:C:\Oracle\OracleUser\product\12.1.0\dbhome_2\bin\oraclr12.dll")
(SID_NAME = CLRExtProc)
(ORACLE_HOME = C:\Oracle\OracleUser\product\12.1.0\dbhome_2)
)
)
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
)
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
)
)
ADR_BASE_LISTENER = C:\Oracle\OracleUser\product\12.1.0\dbhome_2\log
tnsnames.ora
LISTENER_ORCL =
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
ORACLR_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
)
(CONNECT_DATA =
(SID = CLRExtProc)
(PRESENTATION = RO)
)
)
ORCL =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = orcl)
)
)
error inside the ...\product\12.1.0\dbhome_2\log\diag\tnslsnr\iper410a\listener\trace\listener.log
24-APR-2016 19:10:33 * (CONNECT_DATA=(CID=(PROGRAM=null)(HOST=__jdbc__)(USER=null))(SERVICE_NAME=orcl)) * (ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=1195)) * establish * orcl * 12514
TNS-12514: TNS:listener does not currently know of service requested in connect descriptor
24-APR-2016 19:10:40 * (CONNECT_DATA=(CID=(PROGRAM=SQL Developer)(HOST=__jdbc__)(USER=my_windows_login))(SERVICE_NAME=orcl)) * (ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=1198)) * establish * orcl * 12514
TNS-12514: TNS:listener does not currently know of service requested in connect descriptor
It confuses me that instead of 'system' Oracle account, the error is listing my windows login account (my_windows_login).
Please advise!
It seems you have two oracle homes.
Check the output of cmd -> tnsping orcl command. You can see which oracle directory is being used.
Then you can check Environment Variables -> System Variable -> Path and reorder Oracle Home directories. This worked in my case.
I am trying connect the oracle database using SQL Developer tools but It showing me:
IO ERRORS: Network adapter Could Not Established The Connection
I Started the OracleXETNSListner service from service.msc: it's running.
I also used the lsnrctl start command, which couldn't start the listener either.
And one more thing: I used sqlplus command prompt: it works fine (also gets connected database)
Thanks in advance...
this is my Tnsname.ora file
my tnsname file located at C:\oraclexe\app\oracle\product\11.2.0\server\network\ADMIN\tnsnames.ora
XE =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = HP-PC)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = XE)
)
)
EXTPROC_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
)
(CONNECT_DATA =
(SID = PLSExtProc)
(PRESENTATION = RO)
)
)
ORACLR_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
)
(CONNECT_DATA =
(SID = CLRExtProc)
(PRESENTATION = RO)
)
)
I am not able to connect Oracle 11g in Windows 7. Could somebody please help me.
Below is the error message that I am getting :
SQL> connect system
Enter password:
ERROR:
ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
Process ID: 0
Session ID: 0 Serial number: 0
My tnsnames.ora file :
XE =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(ORACLE_SID = XE)
(SERVICE_NAME = XE)
)
)
EXTPROC_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
)
(CONNECT_DATA =
(SID = PLSExtProc)
(PRESENTATION = RO)
)
)
ORACLR_CONNECTION_DATA =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1))
)
(CONNECT_DATA =
(SID = CLRExtProc)
(PRESENTATION = RO)
)
)
I have started the listener service but still getting same error. Could somebody please help me in resolving this issue.
You need to start the oracle instance first.
set up oracle_home and oracle_sid.
export ORACLE_HOME=/u01/app/oracle/product/11.2/dbhome_1/ (choose per env)
export ORACLE_SID=dev
$ lsnrctl start
$ sqlplus '/ as sysdba'
SQL> startup