Architecture & Connection

 

 

oracle server - instance (sga, background process)

                      - database (control file, data file, redo log file)

grannle : 细粒度, 指 SGA 逻辑上分配的最小单位, 一般是 16M, 只有 SGA 小于 128M 时, 这个细粒度才是 4M.

1. server process :  when a user logs on to the oracle server , a process is created on the computer running the oracle server . ( 输入完用户名密码 ) (dedicated / shared )

2. session : A session is a specific connection of a user to an Oracle server . the session starts when the user is validated by the oracle server , and  it ends when the user

                      logs out or when there is an bonormal termination .

3. server process 与 session 区别 : 首先 session 是逻辑概念, 表示一个会话, 并不直接体现在进程中,  它可以借助 server process 体现在进程中, 一个server process

                                                                    可以对应多个session ( 即 多个 session 共用一个 server process )

4. database file : (1) data file (2)control file (3)on line redo log file (4) parameter file 存储一些参数关于instance的 (5) password file 存储谁有权限开启关闭数据库 ,

                               (6) Archived  redolog file 存储 offline copies of the redo log files

5. memory structure : SGA ( Allocated at instance startup ) PGA ( Allocated when the server process startup ) PGA 不属于 instance

6. shared pool (SGA) : is used to store the most recently executed SQL statments ( library cache ) and the most recently used data definitions (data dictionary cache).

    library cache : SQL area 和 PL/SQL area.

    data dictionary cache : (table, columns, users, privilege)

7. database buffer cache (SGA) : stores copies of data blocks ( disk ) that have been retrieved from the data files .

8. redo log buffer cache (SGA) : records all changes made to the database data blocks . ( primary purpose is recovery )

9. large pool ( opional ) (SGA) : only shared server , 用来存储区分session 等内容.


10 . dedicated server include (PGA) : 
        pga 是一块内存区域, 就跟 SGA 一样,但是同时,它是私有的,只能是对应的 server process 访问

        sort area : userd for any sorts that may be required to process the SQL statement

        Session information : includes user privileges and performance statistics for the session

        Cursor state : Indicates the stage in the processing of the SQL statements that are currently used by the session

        Stack space : contains other session variables

        一些上面说的内容存储在SGA中(如果是shared server ) , 如果有large pool 存储在 large pool中, 否则存储在 share pool中

 

 11. backgroud process ( optional ) :

        RECO : Recovever

        QMNn : Advanced Queuing

         ARCn : Archiver

         LCKn : RAC Lock Manager -- Instance Locks

         LMON : RAC DLM Monitor -- Global Locks

         LMDn : RAC DLM Monitor -- Remote Locks

         CJQ0 : Snapshot Refresh

          Dnnn : Dispatcher

          Snnn : Shared Server

          Pnnn : Parallel Query Slaves

           本次不讨论, 向后补充

        一个非常重要的process ( optional ) Archiver ( ARCn ) : is crucial to recovering a database after the loss of a disk . It automatically archives the online

        redo log before the log can be reused .

        如果选择了 NoArchivelog mode : 为了恢复时数据的完整性, LGWR does not overwrite a redo log group until the checkpoint for that group is complete , 要等待CKPT

        完成以后, LGWR才会重写该 redo log file . ( 等待啊。。等待 ) ( 推荐使用 Archivelog mode )

        这理解错了,即便是使用Archvelog mod模式,也要等待,只不过在覆盖之前,会先将该日志文件备份一遍。

 12. backgroud process ( main )

          DBWn : database writer ,

         

           LGWR : Log Writer .

        

           SMON : system monitor

       

           if the oracle instance fails, any information in the SGA that has not been written to disk is lost, the backgroud process SMON automatically performs instance

           recovery when the database is reopened . (1) 继续执行那些已经在redo log file中执行, 但是实际由于instance failer而没有写入datablock的内容

           (2)opening the database so that users can log on . (3) Rolling back uncommited transactions 以上是按照顺序执行

主要是为了 instance recovery

当 instance recovery 发生时,

1. 前滚, 参考 redo log file, 将已经 commit 的事务重做, 写到磁盘上.

2. 打开 database (所有没有被改动的数据都可以被访问)

3. 回滚 那些没有 commit 的事务, 要被撤销.

            PMON : process monitor The background process PMON cleans up after failed processes  在以下情况 :

                           Rolling back the user's current transaction

                           Releasing all currently held table or row locks

                           Freeing other resources currently reserved by the user

                           Restarts dead dispatchers


当一个用户的进程死掉了, 那么 pmon 就派上用处了.

1. rolling back 这个用户的提交的 tranaction

2. 释放相关的所有的锁.

3. 释放其他相关的资源.

4. 重启 dead dispatchers.           

Checkpoint ( CKPT ) : 检查点是指 DBWn 将所有的修改的 database buffers 中的内容( 包括脏的和干净的 ) 写入 data file时, 触发的一个事件(event )

             使用 Checkpoint的原因 : 1 由于oracle采用的是的算法(LRU) 就是最后被使用原则, 所以那些经常被使用的数据就会一直在内存中存在, 如果没有CKPT, 它们就不会被

                                                          写到磁盘中. 2因为检查点,所有的数据库修改的内容都要写到datafile, 这就有个好处, 就是当需要恢复的时候, 上一个检查点以前的内容不必

                                                          考虑, 因为它们必然都已经写到了 data file了.

             检查点的动作 :  Checkpoint number into the data file headers .

                                         Checkpoint number, log sequence number, archived log names, and system change numbers into thecontrol file.

              CKPT does not write data blocks to disk or redo blocks to the online redo logs .


check point 是为了确认一个标记, 即内存中的脏数据写到磁盘上的一个标记, 这样, 下次恢复时, 就可以从上一个 checkpoint 开始, 因为之前的数据全部都写到磁盘上了, 另外, 如果没有checkpoint 那么由于 buffercache 是最近最少被使用原则, 那么很可能存在这样的数据块, 它永远没有办法写到磁盘里.

checkpoint 写的流程 :

1. check point numbuer into datafile headers.

2. checkpint number log sequence number, archivelog name and system change number into the control file.

 

 13. Logical structure


       tablespaces -> segments -> extents -> blocks ( include )

备注1 :计算机进程连结 : 当是两台主机之间连接时,是通过物理网卡 eth0 来连接, tcp/ip 协议

              如果计算机内部的进程通信 : a . 是ipc 连接,即计算机内部进程之间直接的通信,是通过ipc直接连接。

                                                            b . 也是通过tcp/ip协议进行连接,是通过模拟的网卡 lo 进行的

备注2 : 连接

DML 操作语句的流程

1. 如果要修改的数据不在 databuffer cache 中, 那么 server process 在磁盘中找到该数据, 并拷贝一份到内存中.

2. server process 会给那些修改过的数据上锁, 回滚段内存中保存着修改前的数据, 这样, 如果操作失败, 也可回滚.

3. 改变这些数据为新的值.

4. 修改过的数据块, 在内存中标示为脏数据.

个人总结

本章的主要内容是: 各种概念的了解, 和对体系结构的把握.

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
### 回答1: Inception 架构是一种用于计算机视觉的神经网络架构,它通过使用不同尺寸的卷积核来捕捉图像中的不同级别特征。近年来,研究者们对 Inception 架构进行了重新思考,提出了许多改进版本,如 Inception-v2 和 Inception-v3。这些改进版本通过更深层次的网络结构、更高效的卷积层、更强大的正则化方法等来增强模型的性能。 ### 回答2: "重新思考计算机视觉中的Inception架构"是指对计算机视觉中的Inception架构进行反思和重新设计的过程。 在计算机视觉中,深度学习网络被广泛应用于图像分类、物体检测和语义分割等任务。Inception架构是一种流行的深度学习架构之一,它的特点是使用了一系列不同尺寸的卷积核和Inception模块,以提取不同尺度下的图像特征。 然而,随着计算机视觉任务的不断发展和挑战的出现,人们开始重新思考和改进Inception架构。对Inception架构的重新思考主要包括以下几个方面: 首先,针对Inception架构中的参数数量过多和计算复杂度高的问题,人们提出了一些改进方法。例如,通过降低Inception模块中卷积核的维度和参数数量,可以减少计算量,提高网络的训练和推理效率。 其次,人们提出了一些新的模块和网络结构,以解决Inception架构在某些任务上的性能限制。例如,ResNet和DenseNet等网络结构通过引入残差连接和稠密连接,解决了深度网络中的梯度消失和信息丢失问题。 此外,人们还关注如何将Inception架构与其他架构进行融合,以进一步提升计算机视觉任务的性能。例如,人们将Inception架构与注意力机制相结合,以提高目标检测和图像分割的准确性。 总之,"重新思考计算机视觉中的Inception架构"是一个不断演进的过程。通过反思和优化Inception架构,人们可以提高计算机视觉任务的性能、准确性和效率,推动计算机视觉领域的发展。 ### 回答3: 重新思考计算机视觉中的初始架构(rethinking the inception architecture for computer vision)是指对计算机视觉模型中的初始网络架构进行重新思考和改进。 计算机视觉是人工智能领域中的一个重要分支,它致力于让计算机能够像人一样理解和处理图像和视频。而计算机视觉模型的架构对于模型的性能和效果具有很大的影响。 Inception架构是一种经典的计算机视觉模型架构,最早由谷歌在2014年提出。它通过使用多尺度的卷积层和并行结构来提高模型的性能和效果。然而,随着技术的发展和需求的变化,原始的Inception架构可能存在一些限制和缺陷。 重新思考Inception架构意味着我们需要针对当前的计算机视觉任务和要求,重新设计和改进Inception架构。有几个方面可以考虑: 首先,我们可以通过引入更先进的卷积技术和结构来改善模型的性能。例如,可以使用Dilated Convolution(空洞卷积)来增加感受野,或者使用Depthwise Separable Convolution(分离卷积)来减少参数量和计算量。 其次,我们可以将其他经典和有效的架构和思想与Inception架构相结合,以进一步提升性能。例如,可以引入残差连接(Residual Connection)来加快训练速度和提高模型的泛化能力。 此外,我们还可以针对具体的计算机视觉任务,对Inception架构进行特定的优化。例如,对于目标检测任务,可以加入适应性池化层(Adaptive Pooling Layer)来获得更好的位置和尺度信息。 总之,重新思考Inception架构是一个不断改进和优化计算机视觉模型的过程。通过结合新的技术、思想和任务需求,我们可以进一步提高计算机视觉模型的性能和效果。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值