Oracle数据库启动时,经历了三个过程:(用命名如下)startup nomount;alter database mount; alter database open;当然数据库关
Oracle数据库启动时,经历了三个过程:(用命名如下)
startup nomount;
alter database mount; alter database open;
当然数据库关闭时也是经历了三个相反的过程:
alter database close;
alter database dismount;
shutdown;(shutdown 后面跟了四个参数:normal;immediate;transactional;abort)
四种方式关闭数据库的比较:
(NO YES)
关闭方式 A I T N
允许新的连接 N N N N
等待活动会话终止 N N N Y
等待活动事务终止 N N
强制进行checkpoint,关闭所有文件 N Y Y Y
分析第一个过程startup nomount:
这个过程数据库首先到参数文件(pfile/spfile)中读取数据库的设置,创建实例.
数据库所在的操作系统版本:
[oracle@localhost ~]$ lsb_release -a
LSB Version: :core-3.1-ia32:core-3.1-noarch:graphics-3.1-ia32:graphics-3.1-noarch
Distributor ID: EnterpriseEnterpriseServer
Description: Enterprise Linux Enterprise Linux Server release 5.5 (Carthage)
Release: 5.5
Codename: Carthage
数据库版本:
SQL> SELECT * FROM v$version where rownum=1;
BANNER
--------------------------------------------------------------------------------
Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
因为spfile是二进制文件,不能直接读取,在linux中,可以用命令String转储出来:
[oracle@localhost dbs]$ strings spfileorcl3939.ora
orcl3939.__db_cache_size=54525952
orcl3939.__java_pool_size=4194304
orcl3939.__large_pool_size=4194304
orcl3939.__oracle_base='/u01/app/oracle'#ORACLE_BASE set from environment
orcl3939.__pga_aggregate_target=171966464
orcl3939.__sga_target=251658240
orcl3939.__shared_io_pool_size=0
orcl3939.__shared_pool_size=176160768
orcl3939.__streams_pool_size=4194304
*.audit_file_dest='/u01/app/oracle/admin/orcl3939/adump'
*.audit_trail='db'
*.compatible='11.2.0.0.0'
*.control_files='/u01/app/o
racle/oradata/orcl3939/control01.ctl','/u01/app/oracle/flash_recovery_area/orcl3939/control02.ctl','/u01/app/oracle/oradata/orcl3939/control03.ctl'
*.db_block_size=8192
*.db_domain='localdomain'
*.db_name='orcl3939'
*.db_recovery_file_dest='/u01/app/oracle/flash_recovery_area'
*.db_recovery_file_dest_size=4039114752
*.diagnostic_dest='/u01/app/oracle'
*.dispatchers='(PROTOCOL=TCP) (SERVICE=orcl3939XDB)'
*.instance_name='ORCL3939'
*.local_listener='(ADDRESS=(PROTOCOL=TCP)(HOST = local
host.localdomain)(PORT = 1521))'
*.memory_target=423624704
*.open_cursors=300
*.processes=150
*.remote_login_passwordfile='EXCLUSIVE'
*.service_names='a,b,c,d'
*.trace_enabled=TRUE
*.undo_tablespace='UNDOTBS1'
spfile文件中你可以看到数据库在nomount时做了些什么,根据参数文件的内容,创建了instance,分配了相应的内存区域,启动了相应的后台进程。
我们再看告警日志文件(alert_.log):读取了参数文件,启动了实例
Starting up:
Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options.
Using parameter settings in server-side spfile /u01/app/oracle/product/11.2.0/dbhome_1/dbs/spfileorcl3939.ora
System parameters with non-default values:
processes = 150
memory_target = 404M
control_files = "/u01/app/oracle/oradata/orcl3939/control01.ctl"
control_files = "/u01/app/oracle/flash_recovery_area/orcl3939/control02.ctl"
control_files = "/u01/app/oracle/oradata/orcl3939/control03.ctl"
db_block_size = 8192
compatible = "11.2.0.0.0"
db_recovery_file_dest = "/u01/app/oracle/flash_recovery_area"
db_recovery_file_dest_size= 3852M
undo_tablespace = "UNDOTBS1"
remote_login_passwordfile= "EXCLUSIVE"
db_domain = "localdomain"
instance_name = "ORCL3939"
service_names = "a,b,c,d"
dispatchers = "(PROTOCOL=TCP) (SERVICE=orcl3939XDB)"
local_listener = "(ADDRESS=(PROTOCOL=TCP)(HOST = localhost.localdomain)(PORT = 1521))"
audit_file_dest = "/u01/app/oracle/admin/orcl3939/adump"
audit_trail = "DB"
db_name = "orcl3939"
open_cursors = 300
diagnostic_dest = "/u01/app/oracle"
trace_enabled = TRUE
Thu Apr 02 14:59:41 2015
PMON started with pid=2, OS id=5989
Thu Apr 02 14:59:41 2015
VKTM started with pid=3, OS id=5991 at elevated priority
VKTM running at (10)millisec precision with DBRM quantum (100)ms
Thu Apr 02 14:59:41 2015
GEN0 started with pid=4, OS id=5995
Thu Apr 02 14:59:41 2015
DIAG started with pid=5, OS id=5997
Thu Apr 02 14:59:41 2015
DBRM started with pid=6, OS id=5999
Thu Apr 02 14:59:41 2015
PSP0 started with pid=7, OS id=6001
Thu Apr 02 14:59:41 2015
DIA0 started with pid=8, OS id=6003
Thu Apr 02 14:59:41 2015
MMAN started with pid=9, OS id=6005
Thu Apr 02 14:59:41 2015
DBW0 started with pid=10, OS id=6007
Thu Apr 02 14:59:41 2015
LGWR started with pid=11, OS id=6009
Thu Apr 02 14:59:41 2015
CKPT started with pid=12, OS id=6011
Thu Apr 02 14:59:41 2015
SMON started with pid=13, OS id=6013
Thu Apr 02 14:59:41 2015
RECO started with pid=14, OS id=6015
Thu Apr 02 14:59:41 2015
MMON started with pid=15, OS id=6017
Thu Apr 02 14:59:41 2015
MMNL started with pid=16, OS id=6019
starting up 1 dispatcher(s) for network address '(ADDRESS=(PARTIAL=YES)(PROTOCOL=TCP))'...
starting up 1 shared server(s) ...
ORACLE_BASE from environment = /u01/app/oracle

本篇文章给大家带来了关于mysql的相关知识,其中主要介绍了关于索引优化器工作原理的相关内容,其中包括了MySQL Server的组成,MySQL优化器选择索引额原理以及SQL成本分析,最后通过 select 查询总结整个查询过程,下面一起来看一下,希望对大家有帮助。

sybase是基于客户/服务器体系结构的数据库,是一个开放的、高性能的、可编程的数据库,可使用事件驱动的触发器、多线索化等来提高性能。

visual foxpro数据库文件是管理数据库对象的系统文件。在VFP中,用户数据是存放在“.DBF”表文件中;VFP的数据库文件(“.DBC”)中不存放用户数据,它只起将属于某一数据库的 数据库表与视图、连接、存储过程等关联起来的作用。

数据库系统由4个部分构成:1、数据库,是指长期存储在计算机内的,有组织,可共享的数据的集合;2、硬件,是指构成计算机系统的各种物理设备,包括存储所需的外部设备;3、软件,包括操作系统、数据库管理系统及应用程序;4、人员,包括系统分析员和数据库设计人员、应用程序员(负责编写使用数据库的应用程序)、最终用户(利用接口或查询语言访问数据库)、数据库管理员(负责数据库的总体信息控制)。

microsoft sql server是Microsoft公司推出的关系型数据库管理系统,是一个全面的数据库平台,使用集成的商业智能(BI)工具提供了企业级的数据管理,具有使用方便可伸缩性好与相关软件集成程度高等优点。SQL Server数据库引擎为关系型数据和结构化数据提供了更安全可靠的存储功能,使用户可以构建和管理用于业务的高可用和高性能的数据应用程序。

结构层次是“数据库→数据表→记录→字段”;字段构成记录,记录构成数据表,数据表构成了数据库。数据库是一个完整的数据的记录的整体,一个数据库包含0到N个表,一个表包含0到N个字段,记录是表中的行。

go语言可以写数据库。Go语言和其他语言不同的地方是,Go官方没有提供数据库驱动,而是编写了开发数据库驱动的标准接口,开发者可以根据定义的接口来开发相应的数据库驱动;这样做的好处在于,只要是按照标准接口开发的代码,以后迁移数据库时,不需要做任何修改,极大方便了后期的架构调整。

mysql查询为什么会慢,关于这个问题,在实际开发经常会遇到,而面试中,也是个高频题。遇到这种问题,我们一般也会想到是因为索引。那除开索引之外,还有哪些因素会导致数据库查询变慢呢?


핫 AI 도구

Undresser.AI Undress
사실적인 누드 사진을 만들기 위한 AI 기반 앱

AI Clothes Remover
사진에서 옷을 제거하는 온라인 AI 도구입니다.

Undress AI Tool
무료로 이미지를 벗다

Clothoff.io
AI 옷 제거제

AI Hentai Generator
AI Hentai를 무료로 생성하십시오.

인기 기사

뜨거운 도구

MinGW - Windows용 미니멀리스트 GNU
이 프로젝트는 osdn.net/projects/mingw로 마이그레이션되는 중입니다. 계속해서 그곳에서 우리를 팔로우할 수 있습니다. MinGW: GCC(GNU Compiler Collection)의 기본 Windows 포트로, 기본 Windows 애플리케이션을 구축하기 위한 무료 배포 가능 가져오기 라이브러리 및 헤더 파일로 C99 기능을 지원하는 MSVC 런타임에 대한 확장이 포함되어 있습니다. 모든 MinGW 소프트웨어는 64비트 Windows 플랫폼에서 실행될 수 있습니다.

SublimeText3 영어 버전
권장 사항: Win 버전, 코드 프롬프트 지원!

에디트플러스 중국어 크랙 버전
작은 크기, 구문 강조, 코드 프롬프트 기능을 지원하지 않음

VSCode Windows 64비트 다운로드
Microsoft에서 출시한 강력한 무료 IDE 편집기

ZendStudio 13.5.1 맥
강력한 PHP 통합 개발 환경

뜨거운 주제



