利用sql语句语句创建表空间时弄错了,就一时心急把创建的文件删除了。结果问题就出来了。sysdba可以登录,但是在使用中就出现ld
一、Oracle在aix上连接
1.su - oracle //进入oracle用户;
2.export ORACLE_SID=house //指定实例,多个实例的情况下;
3.sqlplus /nolog
4.conn /as sysdba
二、ora-01033:oracle initialization or shutdown in progress,经过分析研究终于解决了,,记下来。
首先:问题的产生原因,出现这个错误是因为我将\oracle\product\10.1.0\oradata\oral下的一个文件删除掉后出现的。
利用sql语句语句创建表空间时弄错了,就一时心急把创建的文件删除了。结果问题就出来了。sysdba可以登录,但是在使用中就出现“数据库未打开,仅允许在固定表/视图中查询”,而normal用户无法登录使用,出现ORA-01033: ORACLE initialization or shutdown in progress 的错误。
分析:这个错误的原因应该是Oracle在启动后,用户登录时是要将方案中原有配置信息装载进入,装载过程中配置中有文件未找到,所以就报出错误。
解决过程:
C:\Documents and Settings\DHai>sqlplus /nolog
SQL*Plus: Release 10.1.0.2.0 - Production on 星期一 9月 28 14:35:38 2009
Copyright (c) 1982, 2004, Oracle. All rights reserved.
SQL> connect sys/123 as sysdba;
已连接。
SQL> shutdown normal
ORA-01109: 数据库未打开
已经卸载数据库。
ORACLE 例程已经关闭。
SQL> startup mount;
ORACLE 例程已经启动。
Total System Global Area 171966464 bytes
Fixed Size 787988 bytes
Variable Size 145750508 bytes
Database Buffers 25165824 bytes
Redo Buffers 262144 bytes
数据库装载完毕。
SQL> alter database open;
alter database open
*
第 1 行出现错误:
ORA-01589: 要打开数据库则必须使用 RESETLOGS 或 NORESETLOGS 选项
SQL> alter database open resetlogs;
alter database open resetlogs
*
第 1 行出现错误:
ORA-01157: 无法标识/锁定数据文件 6 - 请参阅 DBWR 跟踪文件
ORA-01110: 数据文件 6: 'C:\ORACLE\PRODUCT\10.1.0\ORADATA\ORAL\FSCREDIT40'
SQL> alter database datafile 6 offline drop;
数据库已更改。
SQL> alter database open resetlogs;
数据库已更改。
SQL> alter database datafile 6 offline drop;
数据库已更改。
SQL> alter database open;
alter database open
*
第 1 行出现错误:
ORA-01531: 例程已打开数据库
SQL>shutdown normal
提示:数据库已经关闭
已经卸载数据库
ORACLE 例程已经关闭
SQL> startup mount;
ORACLE 例程已经启动。
Total System Global Area 171966464 bytes
Fixed Size 787988 bytes
Variable Size 145750508 bytes
Database Buffers 25165824 bytes
Redo Buffers 262144 bytes
数据库装载完毕。
到此,问题解决了。
=============================================
============================================
网上另外的文章
=====================================
============================
oracle一个问题的解决方法:Error:ORA-01033:ORACLE initialization or shutdown in progress2009-07-14 18:42从网上找了一些资料,最后加上自己的实践终于解决了
后来发现原因既然是:用系统清理工具把系统垃圾清理了一番,结果在打开oracle 数据库时出现了错误:
解决方法在DOS环境下sqlplus /NOLOGSQL>connect sys/sys as sysdbaSQL>shutdown normalSQL>startup mountSQL>alter database open;第 1 行出现错误:ORA-01157: 无法标识/锁定数据文件 6 - 请参阅 DBWR 跟踪文件ORA-01110: 数据文件 6: ''D:\ORACLE\ORADATA\ORAGWH\INDX01.DBF''出现这种问题时继续输入SQL> conn sys/sys as sysdba;已连接。SQL> alter database datafile 6 offline drop;直到用scott登陆为止SQL> conn scott/tiger然后接着输入即可SQL>shutdown normalSQL>startup
在输入上述命令的时候,可能会出现下面的问题:
ORA-00313: 无法打开日志组 1 (线程 1) 的成员
解决方法如下:
运行Oracle----Integrated Management Tools----SQLPlus WorkSheet
SQL> connect / as sysdba;
已连接。
SQL> shutdown immediate;
ORA-01109: 数据库未打开
已经卸载数据库。
ORACLE 例程已经关闭。
SQL> startup;
ORACLE 例程已经启动。
Total System Global Area 135338868 bytes
Fixed Size 453492 bytes
Variable Size 109051904 bytes
Database Buffers 25165824 bytes
Redo Buffers 667648 bytes
数据库装载完毕。
ORA-00313: 无法打开日志组 1 (线程 1) 的成员
ORA-00312: 联机日志 1 线程 1: 'C:\ORACLE\ORADATA\ORCL\REDO01.LOG'
查看C:\ORACLE\ORADATA\myoracle\REDO01.LOG还在,但是REDO02.LOG,REDO03.LOG被误删了.
赶紧换个例程OEMREP试试,结果还是一样的错误!
蒙了,难道要重装数据库不成?有什么办法可以解决这个问题呢?
解决办法:
SQL> shutdown immediate;
ORA-01109: 数据库未打开
已经卸载数据库。
SQL> startup mount;
ORACLE 例程已经启动。
SQL>select * from v$log;
GROUP# THREAD# SEQUENCE# BYTES MEMBERS ARC STATUS FIRST_CHANGE# FIRST_TIME
---------- ---------- ---------- ---------- ---------- --- ---------------- ------------- ----------
1 1 0 104857600 1 NO UNCURRENT 670680 05-12月-07
2 1 15 104857600 1 NO unactive 696119 06-12月-07
3 1 0 104857600 1 NO Unactive 650182 05-12月-07
已选择3行。
alter database clear unarchived logfile group 1; /*重建日志文件*/
数据库已经更改.
alter database clear unarchived logfile group 2;
数据库已经更改.
alter database clear unarchived logfile group 3;
数据库已经更改.
SQL>shutdown;
已经卸载数据库。
ORACLE 例程已经关闭。
SQL>startup;
ORACLE 例程已经启动。
Total System Global Area 135338868 bytes
Fixed Size 453492 bytes
Variable Size 109051904 bytes
Database Buffers 25165824 bytes
Redo Buffers 667648 bytes
数据库装载完毕。
数据库已经打开。
问题解决!
但是,在对myoracle 例程进行同样的操作后,也不知道是哪里出了问题,
SQL>startup;
ORACLE 例程已经启动。
Total System Global Area 135338868 bytes
Fixed Size 453492 bytes
Variable Size 109051904 bytes
Database Buffers 25165824 bytes
Redo Buffers 667648 bytes
数据库装载完毕。
ORA-03113: 通信通道的文件结束
在网上查找资料,出现这样的问题原因很多,一般是网络不通,或者是init.ora、C:\oracle\ora92\network\admin\sqlnet.ora或tnsnames.ora有问题.显然这些不适合我.我的两个例程,一个可以正常使用,另外一个有问题的!
在我关闭数据库后,重新打开,执行:
SQL>connect "/as sysdba";
SQL>select * from scott.emp;
ORA-27101 shared memory realm does not exist -
出现这个错误也有很多解释,一般要检查init.ora文件的内存配置是否有问题,但是在没有打开数据库的时候执行命令,也会出现这样的错误提示,我的属于后者,是由于没有挂载数据库造成的,这里提醒一下.
后来又乱琢磨了一回,还出现了错误:
ORA-24324: 未初始化服务句柄
ORA-01041: 内部错误,hostdef 扩展名不存在
这是越来越乱了,无奈之下,只好重头再来整理一遍,从重新配置日志文件开始,操作一样,但是奇迹出现了,错误消失了,也不提示通信通道文件结束了,数据库正常了,呵呵,但是很晕!
解决问题知识整理:
首先,执行下面的语句看看group1是不是current日志组
select * from v$log;
如果被删除的日志不是当前日志组的成员,比较简单
alter database clear logfile group 1;
如果你的库是非归档的,或许要用下面的语句
alter database clear unarchived logfile group 1;
如果是当前日志组损坏,但是数据库是正常关闭的,上面的办法也可以使用
如果日志组中有活动的事务,那么可能需要利用备份来恢复了:过程如下:
解决过程:Microsoft Windows XP [版本 5.1.2600](C) 版权所有 1985-2001 Microsoft Corp.
C:\Documents and Settings\5201314>sqlplus /nolog
SQL*Plus: Release 10.2.0.1.0 - Production on 星期六 5月 27 11:19:52 2006Copyright (c) 1982, 2005, Oracle. All rights
reserved.
SQL> conn sys/dd as sysdba
已连接。
SQL> startup mount
ORA-01081: 无法启动已在运行的 ORACLE - 请首先关闭它
SQL> recover database until time '2006-05-19 13:45:02'; /*恢复*/
/*(recover database until cancel;alter database resetlogs;重建日志文件),另外的写法,不知哪个对.*/
完成介质恢复。
SQL> alter database open resetlogs;
数据库已更改。
SQL> shutdown immediate;
数据库已经关闭。
已经卸载数据库。
ORACLE 例程已经关闭。
SQL> startup
ORACLE 例程已经启动。
Total System Global Area 205520896 bytes
Fixed Size 1248092 bytes
Variable Size 79692964 bytes
Database Buffers 117440512 bytes
Redo Buffers 7139328 bytes
数据库装载完毕。
数据库已经打开。
三、linux oracle 监视器
切换至安装oracle数据库的那个用户,一般为oracle(在root下是安装或是启动不了oracle的);
su oracle
然后启动监听器
lsnrctl start
会看到启动成功的界面;
lsnrctl stop
停止监听器命令.
可以修改oracle的ora文件,对数据库进行配置,在
/opt/oracle/product/9.2.0/network/admin

InnoDBBufferPool reduces disk I/O by caching data and indexing pages, improving database performance. Its working principle includes: 1. Data reading: Read data from BufferPool; 2. Data writing: After modifying the data, write to BufferPool and refresh it to disk regularly; 3. Cache management: Use the LRU algorithm to manage cache pages; 4. Reading mechanism: Load adjacent data pages in advance. By sizing the BufferPool and using multiple instances, database performance can be optimized.

Compared with other programming languages, MySQL is mainly used to store and manage data, while other languages such as Python, Java, and C are used for logical processing and application development. MySQL is known for its high performance, scalability and cross-platform support, suitable for data management needs, while other languages have advantages in their respective fields such as data analytics, enterprise applications, and system programming.

MySQL is worth learning because it is a powerful open source database management system suitable for data storage, management and analysis. 1) MySQL is a relational database that uses SQL to operate data and is suitable for structured data management. 2) The SQL language is the key to interacting with MySQL and supports CRUD operations. 3) The working principle of MySQL includes client/server architecture, storage engine and query optimizer. 4) Basic usage includes creating databases and tables, and advanced usage involves joining tables using JOIN. 5) Common errors include syntax errors and permission issues, and debugging skills include checking syntax and using EXPLAIN commands. 6) Performance optimization involves the use of indexes, optimization of SQL statements and regular maintenance of databases.

MySQL is suitable for beginners to learn database skills. 1. Install MySQL server and client tools. 2. Understand basic SQL queries, such as SELECT. 3. Master data operations: create tables, insert, update, and delete data. 4. Learn advanced skills: subquery and window functions. 5. Debugging and optimization: Check syntax, use indexes, avoid SELECT*, and use LIMIT.

MySQL efficiently manages structured data through table structure and SQL query, and implements inter-table relationships through foreign keys. 1. Define the data format and type when creating a table. 2. Use foreign keys to establish relationships between tables. 3. Improve performance through indexing and query optimization. 4. Regularly backup and monitor databases to ensure data security and performance optimization.

MySQL is an open source relational database management system that is widely used in Web development. Its key features include: 1. Supports multiple storage engines, such as InnoDB and MyISAM, suitable for different scenarios; 2. Provides master-slave replication functions to facilitate load balancing and data backup; 3. Improve query efficiency through query optimization and index use.

SQL is used to interact with MySQL database to realize data addition, deletion, modification, inspection and database design. 1) SQL performs data operations through SELECT, INSERT, UPDATE, DELETE statements; 2) Use CREATE, ALTER, DROP statements for database design and management; 3) Complex queries and data analysis are implemented through SQL to improve business decision-making efficiency.

The basic operations of MySQL include creating databases, tables, and using SQL to perform CRUD operations on data. 1. Create a database: CREATEDATABASEmy_first_db; 2. Create a table: CREATETABLEbooks(idINTAUTO_INCREMENTPRIMARYKEY, titleVARCHAR(100)NOTNULL, authorVARCHAR(100)NOTNULL, published_yearINT); 3. Insert data: INSERTINTObooks(title, author, published_year)VA


Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SecLists
SecLists is the ultimate security tester's companion. It is a collection of various types of lists that are frequently used during security assessments, all in one place. SecLists helps make security testing more efficient and productive by conveniently providing all the lists a security tester might need. List types include usernames, passwords, URLs, fuzzing payloads, sensitive data patterns, web shells, and more. The tester can simply pull this repository onto a new test machine and he will have access to every type of list he needs.

PhpStorm Mac version
The latest (2018.2.1) professional PHP integrated development tool

Atom editor mac version download
The most popular open source editor

ZendStudio 13.5.1 Mac
Powerful PHP integrated development environment