2016��7��8��
�������ݿ�ͣ����Դ������������ͨ�û���½plsql��ORA-01033�?sys�û����ܹ����½�ġ�
���������������ݿ��ǿ��������ġ�
����Ҫǿ�����ǣ���ݿ��������Ĺ�����������״̬�ģ�umount mount open���״̬��
������Ǵ��?������ȻҪ������Լ������������Ӧ�ĵ���
����һ���������ַ���
�鿴��ݿ�״̬
SQL> select status, database_status from v$instance;
STATUS DATABASE_STATUS
------------ -----------------
STARTED ACTIVE
SQL> select open_mode from v$database;
select open_mode from v$database
*
ERROR at line 1:
ORA-01507: database not mounted
Here we can see the instance is started but database is not mounted.
Now mount the database, if this succeeds then there is no problem.
�鿴����ݿû�б����أ�Ҫ����
SQL> alter database mount;
Database altered.
SQL> select status, database_status from v$instance;
STATUS DATABASE_STATUS
------------ -----------------
MOUNTED ACTIVE
�ɹ����ء��������Ѿ��ǹ���״̬�Ͳ���Ҫ������
SQL> select open_mode from v$database;
OPEN_MODE
----------
MOUNTED
Database is mounted successfully but when you try to connect, you still get the same ORA-01033 error:
��Ȼ�����ˣ����ǻ�û�д���open״̬�����ǻᱨ��ġ�
������Ǵ���ݿ�
SQL> alter database open;
Database altered.
ALTER PLUGGABLE DATABASE ALL OPEN;
SQL> select status, database_status from v$instance;
STATUS DATABASE_STATUS
------------ -----------------
OPEN ACTIVE
�鿴һ�£��Ѿ���open״̬�ˡ�
SQL> select open_mode from v$database;
OPEN_MODE
----------
READ WRITE
��������
SQL>shutdown immediate ֹͣ����
SQL>startup
�������������쳣�÷�����
������:
SQL>shutdown immediate ֹͣ����
SQL>startup �������۲�����ʱ��������ļ����ر��?����ס��������ļ����
SQL>shutdown immediate �ٴ�ֹͣ����
SQL>startup mount
SQL> recover datafile 2 �ָ����������ļ�
SQL>shutdown immediate �ٴ�ֹͣ����
SQL>startup �������˴���