目录
一 什么是LGWR进程
二 操作示例
三 总结
首页 数据库 mysql教程 Oracle体系结构及备份(十五)bg-lgwr

Oracle体系结构及备份(十五)bg-lgwr

Jun 07, 2016 pm 03:08 PM
dba oracle 体系结构 备份

一 什么是LGWR进程 LGWR写的条件: 提交的时候 达到三分之一满 日志的大小达到1M 每隔三秒 在DBWn进程写之前 The log writer process writes redo logentries to disk. Redo log entries are generated in the redo log buffer of thesystem global area (SG

一 什么是LGWR进程

 

        LGWR写的条件:

        提交的时候

        达到三分之一满

        日志的大小达到1M

        每隔三秒

        在DBWn进程写之前

 Oracle体系结构及备份(十五)bg-lgwr


        The log writer process writes redo logentries to disk. Redo log entries are generated in the redo log buffer of thesystem global area (SGA). LGWR writes the redo log entries sequentially into aredo log file. If the database has a multiplexed redo log, then LGWR writes theredo log entries to a group of redo log files.

 

二 操作示例


[oracle@localhost 桌面]$ ps -ef | grep ora_ | grep lgw
oracle    6446     1  0 11:15 ?        00:00:00 ora_lgwr_orcl
[oracle@localhost 桌面]$ kill -9 6446
[oracle@localhost 桌面]$ ps -ef | grep ora_ | grep lgw
[oracle@localhost 桌面]$ ps -ef | grep ora_
oracle    6486  2720  0 11:17 pts/0    00:00:00 grep ora_
[oracle@localhost 桌面]$ sqlplus / as sysdba;

SQL*Plus: Release 10.2.0.1.0 - Production on Thu Jun 6 11:17:45 2013

Copyright (c) 1982, 2005, Oracle.  All rights reserved.

Connected to an idle instance.

SQL> startup
ORACLE instance started.

Total System Global Area  838860800 bytes
Fixed Size		    1222192 bytes
Variable Size		  788531664 bytes
Database Buffers	   46137344 bytes
Redo Buffers		    2969600 bytes
Database mounted.
Database opened.
SQL> show parameter log_buff;

NAME				     TYPE	 VALUE
------------------------------------ ----------- ------------------------------
log_buffer			     integer	 2923520
SQL> exit;
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
[oracle@localhost 桌面]$ ps -ef | grep ora_ | grep lgw
oracle    6499     1  0 11:17 ?        00:00:00 ora_lgwr_orcl
[oracle@localhost 桌面]$ ps -ef | grep ora_
oracle    6491     1  0 11:17 ?        00:00:00 ora_pmon_orcl
oracle    6493     1  0 11:17 ?        00:00:00 ora_psp0_orcl
oracle    6495     1  0 11:17 ?        00:00:00 ora_mman_orcl
oracle    6497     1  0 11:17 ?        00:00:00 ora_dbw0_orcl
oracle    6499     1  0 11:17 ?        00:00:00 ora_lgwr_orcl
oracle    6501     1  0 11:17 ?        00:00:00 ora_ckpt_orcl
oracle    6503     1  0 11:17 ?        00:00:00 ora_smon_orcl
oracle    6505     1  0 11:17 ?        00:00:00 ora_reco_orcl
oracle    6507     1  0 11:17 ?        00:00:00 ora_cjq0_orcl
oracle    6509     1  0 11:17 ?        00:00:00 ora_mmon_orcl
oracle    6511     1  0 11:17 ?        00:00:00 ora_mmnl_orcl
oracle    6513     1  0 11:17 ?        00:00:00 ora_d000_orcl
oracle    6515     1  0 11:17 ?        00:00:00 ora_s000_orcl
oracle    6519     1  0 11:17 ?        00:00:00 ora_qmnc_orcl
oracle    6525     1  0 11:18 ?        00:00:00 ora_j000_orcl
oracle    6527     1  0 11:18 ?        00:00:00 ora_q000_orcl
oracle    6529     1  0 11:18 ?        00:00:00 ora_q001_orcl
oracle    6535  2720  0 11:18 pts/0    00:00:00 grep ora_
登录后复制


三 总结

 

        1.LGWR,将重做日志有序地写入重做日志文件中。

        2.LGWR写的条件:提交的时候、达到三分之一满、日志的大小达到1M、每隔三秒、在DBWn进程写之前。

        3. Log buffer:通过LGWR进程写入到logfile中。

        4.Linux中同样使用ps命令查看进程。



<span><span>我的邮箱</span></span><span>:</span>wgbno27@163.com <span> <span>新浪微博</span></span><span>:</span>@Wentasy27
  <span>微信公众平台</span>:JustOracle(微信号:justoracle)
  <span>数据库技术交流群</span>:336882565(加群时验证 From CSDN XXX)
  <span>Oracle交流讨论组</span>:https://groups.google.com/d/forum/justoracle
  <span><strong>By Larry Wen</strong></span>
登录后复制


Oracle体系结构及备份(十五)bg-lgwr Oracle体系结构及备份(十五)bg-lgwr Oracle体系结构及备份(十五)bg-lgwr
@Wentasy
本站声明
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系admin@php.cn

热AI工具

Undresser.AI Undress

Undresser.AI Undress

人工智能驱动的应用程序,用于创建逼真的裸体照片

AI Clothes Remover

AI Clothes Remover

用于从照片中去除衣服的在线人工智能工具。

Undress AI Tool

Undress AI Tool

免费脱衣服图片

Clothoff.io

Clothoff.io

AI脱衣机

AI Hentai Generator

AI Hentai Generator

免费生成ai无尽的。

热工具

记事本++7.3.1

记事本++7.3.1

好用且免费的代码编辑器

SublimeText3汉化版

SublimeText3汉化版

中文版,非常好用

禅工作室 13.0.1

禅工作室 13.0.1

功能强大的PHP集成开发环境

Dreamweaver CS6

Dreamweaver CS6

视觉化网页开发工具

SublimeText3 Mac版

SublimeText3 Mac版

神级代码编辑软件(SublimeText3)

oracle如何查表空间大小 oracle如何查表空间大小 Apr 11, 2025 pm 08:15 PM

要查询 Oracle 表空间大小,请遵循以下步骤:确定表空间名称,方法是运行查询:SELECT tablespace_name FROM dba_tablespaces;查询表空间大小,方法是运行查询:SELECT sum(bytes) AS total_size, sum(bytes_free) AS available_space, sum(bytes) - sum(bytes_free) AS used_space FROM dba_data_files WHERE tablespace_

oracle如何查看实例名 oracle如何查看实例名 Apr 11, 2025 pm 08:18 PM

在 Oracle 中查看实例名的方法有三种:命令行中使用 "sqlplus" 和 "select instance_name from v$instance;" 命令。在 SQL*Plus 中使用 "show instance_name;" 命令。通过操作系统的任务管理器、Oracle Enterprise Manager 或检查环境变量 (Linux 上的 ORACLE_SID)。

oracle视图如何加密 oracle视图如何加密 Apr 11, 2025 pm 08:30 PM

Oracle 视图加密允许您加密视图中的数据,从而增强敏感信息安全性。步骤包括:1) 创建主加密密钥 (MEk);2) 创建加密视图,指定要加密的视图和 MEk;3) 授权用户访问加密视图。加密视图工作原理:当用户查询加密视图时,Oracle 使用 MEk 解密数据,确保只有授权用户可以访问可读数据。

Oracle安装失败如何卸载 Oracle安装失败如何卸载 Apr 11, 2025 pm 08:24 PM

Oracle 安装失败的卸载方法:关闭 Oracle 服务,删除 Oracle 程序文件和注册表项,卸载 Oracle 环境变量,重新启动计算机。若卸载失败,可使用 Oracle 通用卸载工具手动卸载。

oracle游标关闭怎么解决 oracle游标关闭怎么解决 Apr 11, 2025 pm 10:18 PM

解决 Oracle 游标关闭问题的方法包括:使用 CLOSE 语句显式关闭游标。在 FOR UPDATE 子句中声明游标,使其在作用域结束后自动关闭。在 USING 子句中声明游标,使其在关联的 PL/SQL 变量关闭时自动关闭。使用异常处理确保在任何异常情况下关闭游标。使用连接池自动关闭游标。禁用自动提交,延迟游标关闭。

oracle无效数字如何排查 oracle无效数字如何排查 Apr 11, 2025 pm 08:27 PM

Oracle 无效数字错误可能由数据类型不匹配、数字溢出、数据转换错误或数据损坏引起。排查步骤包括检查数据类型、检测数字溢出、检查数据转换、排查数据损坏,并探索其他可能的解决方案,如配置 NLS_NUMERIC_CHARACTERS 参数和启用数据验证日志记录。

oracle怎么循环创建游标 oracle怎么循环创建游标 Apr 12, 2025 am 06:18 AM

Oracle 中,FOR LOOP 循环可动态创建游标, 步骤为:1. 定义游标类型;2. 创建循环;3. 动态创建游标;4. 执行游标;5. 关闭游标。示例:可循环创建游标,显示前 10 名员工姓名和工资。

oracle如何设置用户 oracle如何设置用户 Apr 11, 2025 pm 08:21 PM

在 Oracle 中创建用户需遵循以下步骤:使用 CREATE USER 语句创建新用户。使用 GRANT 语句授予必要权限。可选:使用 RESOURCE 语句设置配额。配置其他选项,如默认角色和临时表空间。

See all articles