侧边栏壁纸
博主头像
与晚风述往事博主等级

万般皆下品,唯有读书高。

  • 累计撰写 149 篇文章
  • 累计创建 29 个标签
  • 累计收到 7 条评论

目 录CONTENT

文章目录

V$INSTANCE动态性能视图

与晚风述往事
2021-11-29 / 0 评论 / 0 点赞 / 184 阅读 / 2,987 字 / 正在检测是否收录...
温馨提示:
本文最后更新于 2021-11-29,若内容或图片失效,请留言反馈。部分素材来自网络,若不小心影响到您的利益,请联系我们删除。

介绍

V$INSTANCE视图提供了查询实例相关状态的方法。

视图详情

下面列表信息来源于Oracle 11G官方文档,本人仅做简单翻译,方便下次查询。

字段名 字段类型 描述 备注
INSTANCE_NUMBER NUMBER Instance number used for instance registration (corresponds to the INSTANCE_NUMBER initialization parameter) 用于实例注册的实例编号
INSTANCE_NAME VARCHAR2(16) Name of the instance 实例名称
HOST_NAME VARCHAR2(64) Name of the host machine 操作系统的主机名
VERSION VARCHAR2(17) Database version 数据库的版本号
STARTUP_TIME DATE Time when the instance was started 实例启动时的时间 此时间是实例创建时的,而不是什么时候启动的
STATUS VARCHAR2(12) Status of the instance:
STARTED - After STARTUP NOMOUNT
MOUNTED - After STARTUP MOUNT or ALTER DATABASE CLOSE
OPEN - After STARTUP or ALTER DATABASE OPEN
OPEN MIGRATE - After ALTER DATABASE OPEN { UPGRADE | DOWNGRADE }
实例的状态:
STARTED - 执行STARTUP NOMOUNT命令后
MOUNTED - 执行STARTUP MOUNT或者ALTER DATABASE CLOSE命令后
OPEN - 执行STARTUP 或者ALTER DATABASE OPEN命令后
OPEN MIGRATE - 执行ALTER DATABASE OPEN {UPGRADE | DOWNGRADE}命令后
PARALLEL VARCHAR2(3) Indicates whether the instance is mounted in cluster database mode (YES) or not (NO) 数据库是否是集群,YES表示是集群,NO表示非集群
THREAD# NUMBER Redo thread opened by the instance 实例打开的重做进程
ARCHIVER VARCHAR2(7) Automatic archiving status:
STOPPED
STARTED
FAILED - Archiver failed to archive a log last time but will try again within 5 minutes
自动归档的状态:
停止
启动
失败 - 归档失败,5分钟内再次尝试归档
LOG_SWITCH_WAIT VARCHAR2(15) Event that log switching is waiting for:
ARCHIVE LOG
CLEAR LOG
CHECKPOINT
NULL - ALTER SYSTEM SWITCH LOGFILE is hung but there is room in the current online redo log
日志切换正在等待的事件:
归档日志
清除日志
检查点
NULL - ALTER SYSTEM SWITCH LOGFILE挂起,但是目前在线重做日志中有空间
LOGINS VARCHAR2(10) Indicates whether the instance is in unrestricted mode, allowing logins by all users (ALLOWED, or in restricted mode, allowing logins by database administrators only (RESTRICTED) 实例是否是受限模式,ALLOWED允许所有用户登录,RESTRICTED仅允许管理员(DBA)登录
SHUTDOWN_PENDING VARCHAR2(3) Indicates whether a shutdown is pending (YES) or not (NO) 实例是否关机待处理 暂时不太理解
DATABASE_STATUS VARCHAR2(17) Status of the database:
ACTIVE
SUSPENDED
INSTANCE RECOVERY
数据库的状态:
活动的
挂起的
实例恢复中
INSTANCE_ROLE VARCHAR2(18) Indicates whether the instance is an active instance (PRIMARY_INSTANCE) or an inactive secondary instance (SECONDARY_INSTANCE), or UNKNOWN if the instance has been started but not mounted 实例的角色,PRIMARY_INSTANCE表示主实例,SECONDARY_INSTANCE表示辅生实例。
ACTIVE_STATE VARCHAR2(9) Quiesce state of the instance:
NORMAL - Database is in a normal state.
QUIESCING - ALTER SYSTEM QUIESCE RESTRICTED has been issued: no new user transactions, queries, or PL/SQL statements are processed in this instance. User transactions, queries, or PL/SQL statements issued before the ALTER SYSTEM QUIESCE RESTRICTED statement are unaffected. DBA transactions, queries, or PL/SQL statements are also unaffected.
QUIESCED - ALTER SYSTEM QUIESCE RESTRICTED has been issued: no user transactions, queries, or PL/SQL statements are processed. DBA transactions, queries, or PL/SQL statements are unaffected. User transactions, queries, or PL/ SQL statements issued after the ALTER SYSTEM QUIESCE RESTRICTED statement are not processed.
实例的静默状态:
NORMAL - 数据库处于正常状态
QUIESCING - 执行ALTER SYSTEM QUIESCE RESTRICTED命令中,此实例中不再处理新的用户事务,查询或PL/SQL语句(执行命令前和DBA的事务、查询和PL/SQL不受影响)
QUIESCED - 数据库已处于静止状态,此实例中的所有用户事务,查询和PL/SQL语句暂时停止运行(DBA事务、查询和PL/SQL不受影响)
RAC环境执行ALTER SYSTEM QUIESCE RESTRICTED命令后,所有实例都会进行暂时。
BLOCKED VARCHAR2(3) Indicates whether all services are blocked (YES) or not (NO) 所有服务是否被阻止,YES表示阻止,NO表示不阻止 暂时不太理解
0

评论区