Oracle not available error in linux

Oracle database : ORA.01034:ORACLE not available

I installed oracle 12c r2 in ubuntu 18.04 and when I enter SqlPlus and execute a query it gives me error. To install the oracle I followed these two guides: 1- https://tutorialforlinux.com/2018/05/09/how-to-install-oracle-12c-r2-database-on-ubuntu-18-04-bionic-64bit-easy-guide/ 2- https://etc.to/confluence/pages/viewpage.action?pageId=20480023 The error that gives me is the following:

ERROR at line 1: ORA-01034:ORACLE not available Process ID:0 Session ID: Serial numbre:0 
Connectinc to (ADDRESS=(PROTOCOL=tcp)(HOST)(PORT=1521)) TNS-12541:TNS: no listener tns-12560 TNS:protocol adapter error TNS-00511: No listener Linux error:111: Connection refused 

Can anybody help me?Thanks!! MORE INFO now when I put lsnrctl status I get this, but in sqlplus the failure of above still appears

LSNRCTL for Linux: Version 12.2.0.1.0 - Production on 19-OCT-2018 01:53:18 Copyright (c) 1991, 2016, Oracle. All rights reserved. Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521)) STATUS of the LISTENER ------------------------ Alias LISTENER Version TNSLSNR for Linux: Version 12.2.0.1.0 - Production Start Date 19-OCT-2018 01:52:14 Uptime 0 days 0 hr. 1 min. 5 sec Trace Level off Security ON: Local OS Authentication SNMP OFF Listener Log File /u01/app/oracle/diag/tnslsnr/andoni-VirtualBox/listener/alert/log.xml Listening Endpoints Summary. (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=andoni-VirtualBox)(PORT=1521))) The listener supports no services The command completed successfully 
 Enter user-name: sys as sysdba Enter password: Connected to an idle instance. SQL> startup ORA-01078: failure in processing system parameters LRM-00109: could not open parameter file '/u01/app/oracle/product/12/dbhome_1/dbs/initSID.ora' SQL> 

Источник

Ошибка после установки на Ubuntu ORA-27101: shared memory realm does not exist

потому, что при простой замене имени каталога /dev/shm у меня пропал интернет. Просто так удалять системные файлы, боязно. Теперь не могу удалить /dev/shm , т.к. он занят.

Читайте также:  Сочетание клавиш команда терминал linux

Не совсем понял, как отключение от интернета повлияло на переименование /dev/shm ? И там не переименование, а пересоздание, хотя и оно не нужно, достаточно перемотирование.

1 ответ 1

ORA-27101: shared memory realm does not exist

означает, что процесс (обычно Listener, sqlplus ) не может подсоединиться к System Global Area (SGA).

В основном это вызывают две причины:

    SGA действительно не существует, так как инстанция БД не стартовала. Стартуйте инстанцию БД под пользователeм oracle :

$ echo startup|sqlplus / as sysdba 
env | egrep -i "oracle_(sid|home)" 

Значения $ORACLE_SID + $ORACLE_HOME , которые были использованы при установке хранятся в /etc/oratab и устанавливаются так:

export ORACLE_SID=orcl; . oraenv 

Например, если попытаться установить вручную и при этом ошибиться:

$ echo exit|sqlplus -l user/pass Connected to: Oracle Database 11g Release 11.2.0.1.0 - Production $ ORACLE_HOME=$ORACLE_HOME/; test -d $ORACLE_HOME && echo "directory exists" # ------^ directory exists 

Всё хорошо, директория существует и sqlplus из неё будет вызываться, но незначащий слэш даст при подсчёте shmid другое значение:

$ echo exit|sqlplus -l user/pass ERROR: ORA-01034: ORACLE not available ORA-27101: shared memory realm does not exist Linux Error: 2: No such file or directory 

Источник

How to Resolve ORA-01034: ORACLE not available

ORA-01034 means that the command you want to perform cannot be done in a stop, idle or shutdown database. If you’re surprised by the error, maybe you should check the database status immediately. It maybe someone or something turn it off without notification.

Connect to Local Database

Let’s see a case. Tried to connect to the local database.

[oracle@test ~]$ sqlplus system
.
Enter password:
ERROR:
ORA-01034: ORACLE not available
ORA-27101: shared memory realm does not exist
Linux-x86_64 Error: 2: No such file or directory
Additional information: 4376
Additional information: -1649756641
Process ID: 0
Session ID: 0 Serial number: 0

Читайте также:  Linux iscsi multipath настройка

Because the database is stop there’s no way to do authentication.

[oracle@test ~]$ sqlplus / as sysdba
.
SQL> alter database begin backup;
alter database begin backup
*
ERROR at line 1:
ORA-01034: ORACLE not available
Process ID: 0
Session ID: 0 Serial number: 0

Although we can connect to the database by OS authentication, we cannot perform any database operation.

The solution is to startup the database.

Data Guard

If you saw ORA-01034 in the alert log, don’t panic, it’s not generated from the database that you are currently running. It’s usually from the standby Database.

.
Tue Oct 13 14:35:08 2008
Errors in file /oracle/admin/ORCL1/bdump/orcl1_arc1_3295892.trc:
ORA-01034: ORACLE not available

In such case, the primary database tried to transport redo log to the standby database, but the standby database is stop for some reason. You need to check what’s going on.

Источник

ORA-01034: ORACLE not available

I tried to start the listener and do a dbstart, but it looks like it is still saying «Oracle Not available». Maybe the dbstart didn’t work. Any suggestions would help me.

[user@fedora16 bin]$ echo $ORACLE_HOME /home/user/app/user/product/11.2.0/dbhome_1 [user@fedora16 bin]$ echo $ORACLE_SID orcl [user@fedora16 bin]$ cat $ORACLE_HOME/network/admin/listener.ora # listener.ora Network Configuration File: /home/user/app/user/product/11.2.0/dbhome_1/network/admin/listener.ora # Generated by Oracle configuration tools. orcl = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521)) (ADDRESS = (PROTOCOL = TCP)(HOST = localhost)(PORT = 1521)) ) ) ADR_BASE_LISTENER = /home/user/app/user/product/11.2.0 [user@fedora16 bin]$ cat $ORACLE_HOME/network/admin/sqlnet.ora # sqlnet.ora Network Configuration File: /home/user/app/user/product/11.2.0/dbhome_1/network/admin/sqlnet.ora # Generated by Oracle configuration tools. NAMES.DIRECTORY_PATH= (TNSNAMES, EZCONNECT) ADR_BASE = /home/user/app/user/product/11.2.0 [user@fedora16 bin]$ dbstart $ORACLE_HOME [user@fedora16 ~]$ lsnrctl start orcl LSNRCTL for Linux: Version 11.2.0.1.0 - Production on 04-MAR-2012 09:04:19 Copyright (c) 1991, 2009, Oracle. All rights reserved. Starting /home/user/app/user/product/11.2.0/dbhome_1/bin/tnslsnr: please wait. TNSLSNR for Linux: Version 11.2.0.1.0 - Production System parameter file is /home/user/app/user/product/11.2.0/dbhome_1/network/admin/listener.ora Log messages written to /home/user/app/user/product/11.2.0/diag/tnslsnr/fedora16/orcl/alert/log.xml Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521))) Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=1521))) Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1521))) STATUS of the LISTENER ------------------------ Alias orcl Version TNSLSNR for Linux: Version 11.2.0.1.0 - Production Start Date 04-MAR-2012 09:04:19 Uptime 0 days 0 hr. 0 min. 0 sec Trace Level off Security ON: Local OS Authentication SNMP OFF Listener Parameter File /home/user/app/user/product/11.2.0/dbhome_1/network/admin/listener.ora Listener Log File /home/user/app/user/product/11.2.0/diag/tnslsnr/fedora16/orcl/alert/log.xml Listening Endpoints Summary. (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521))) (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=1521))) The listener supports no services The command completed successfully [user@fedora16 bin]$ ps -ef | grep '\(ora\|smon\|lsnr\)' user 2405 1 0 08:46 ? 00:00:00 /home/user/app/user/product/11.2.0/dbhome_1/bin/tnslsnr orcl -inherit user 2553 1611 0 08:49 pts/0 00:00:00 grep --color=auto \(ora\|smon\|lsnr\) [user@fedora16 bin]$ sqlplus SQL*Plus: Release 11.2.0.1.0 Production on Sun Mar 4 08:46:29 2012 Copyright (c) 1982, 2009, Oracle. All rights reserved. Enter user-name: scott Enter password: ERROR: ORA-01034: ORACLE not available ORA-27101: shared memory realm does not exist Linux-x86_64 Error: 2: No such file or directory Process ID: 0 Session ID: 0 Serial number: 0 

Источник

Оцените статью
Adblock
detector