1. 概述

Specify the number of days of snapshots to choose from


Entering the number of days (n) will result in the most recent (n) days of snapshots being listed. Pressing <return> without specifying a number lists all completed snapshots. Enter value for num_days: 2 Listing the last 2 days of Completed Snapshots Snap Instance DB Name Snap Id Snap Started Level ------------ ------------ --------- ------------------ ----- orcl ORCL 4759 29 Mar 2028 17:04 1 现象:查看snapshot生成历史,发现很长一段时间都没有生成snapshot 这是一个开发数据库,经过和开发沟通,由于业务测试经常修改操作服务器系统时间。 原因分析:由于修改操作系统时间,在修改成正确的时间后,snapshot 无法自动生成 2. 解决办法 2.1 查看所有的snapshot SQL> select snap_id,dbid from dba_hist_snapshot order by 1; SNAP_ID DBID ---------- ---------- 4752 1373768042 4753 1373768042 4754 1373768042 4755 1373768042 4756 1373768042 4757 1373768042 4758 1373768042 2.2 删掉所有的已经存在的snapshot dbms_workload_repository.drop_snapshot_range(low_snap_id=>4752,high_snap_id=>4758,dbid=> 1373768042); 2.3 手工创建新的snapshot exec dbms_workload_repository.create_snapshot(); 2.4 修改自动收集snapshot的周期测试 收集间隔时间改为30 分钟一次。并且保留5天时间 exec dbms_workload_repository.modify_snapshot_settings(interval=>30, retention=>5*24*60); 2.5 查看收集周期 SQL> select * from dba_hist_wr_control; DBID SNAP_INTERVAL RETENTION TOPNSQL ---------- --------------------------------------------------------------------------- --------------------------------------------------------------------------- ---------- 1373768042 +00000 00:30:00.0 +00008 00:00:00.0 DEFAULT 2.6 查看新生成的snapshot SQL> select snap_id,dbid,BEGIN_INTERVAL_TIME from dba_hist_snapshot; SNAP_ID DBID BEGIN_INTERVAL_TIME ---------- ---------- --------------------------------------------------------------------------- 4759 1373768042 29-MAR-17 04.51.37.190 PM 4760 1373768042 29-MAR-17 05.04.47.970 PM 2.7 正常生成AWR报告 SQL> @ $ORACLE_HOME/rdbms/admin/awrrpti.sql Specify the Report Type ~~~~~~~~~~~~~~~~~~~~~~~ Would you like an HTML report, or a plain text report? Enter 'html' for an HTML report, or 'text' for plain text Defaults to 'html' Enter value for report_type: Type Specified: html Instances in this Workload Repository schema ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ DB Id Inst Num DB Name Instance Host ------------ -------- ------------ ------------ ------------ * 1373768042 1 ORCL orcl ceshi Enter value for dbid: 1373768042 Using 1373768042 for database Id Enter value for inst_num: 1 Using 1 for instance number Specify the number of days of snapshots to choose from

Entering the number of days (n) will result in the most recent

(n) days of snapshots being listed. Pressing without

specifying a number lists all completed snapshots.

Enter value for num_days: 2

Listing the last 2 days of Completed Snapshots

Snap

Instance DB Name Snap Id Snap Started Level


orcl ORCL 4759 29 Mar 2017 17:04 1

          4760 29 Mar 2017 17:13 1

Specify the Begin and End Snapshot Ids


Enter value for begin_snap:

snapshot相关的更多相关文章

  1. 解析Ceph: Snapshot

    经常有开发者在邮件列表中会问到Ceph Snapshot的实现方式,受限于目前有限的实现文档和复杂的代码结构和代码量,弄清楚Ceph Snapshot并不是一件容易的事.正好最近在重构Ceph存储引擎 ...

  2. HBase Snapshot原理和实现

    HBase 从0.95开始引入了Snapshot,可以对table进行Snapshot,也可以Restore到Snapshot.Snapshot可以在线做,也可以离线做.Snapshot的实现不涉及到 ...

  3. HBase原理 – 分布式系统中snapshot是怎么玩的?(转载)

    snapshot(快照)基础原理 snapshot是很多存储系统和数据库系统都支持的功能.一个snapshot是一个全部文件系统.或者某个目录在某一时刻的镜像.实现数据文件镜像最简单粗暴的方式是加锁拷 ...

  4. leveldb源码分析--SSTable之Compaction

    对于compaction是leveldb中体量最大的一部分,也应该是最为复杂的部分,为了便于理解我们首先从一些基本的概念开始.下面是一些从doc/impl.html中翻译和整理的内容: Level 0 ...

  5. HBase的Snapshots功能介绍

    HBase的Snapshots功能介绍 hbase的snapshot功能还是挺有用的,本文翻译自cloudera的一篇博客,希望对想了解snapshot 的朋友有点作用,如果翻译得不好的地方,请查看原 ...

  6. Ubuntu12.10 下搭建基于KVM-QEMU的虚拟机环境(十三)

    今天我们实验libvirt提供的快照功能,快照可以用于系统恢复,防止安装了某些软件或中病毒等情况导致系统损毁的情况. 一.快照类型 1)        磁盘快照 内部的:快照驻留在原来的镜像文件内部 ...

  7. k8s API sample

    Declarative API k8s: cluster-api Introduction to Kubernetes Cluster-API Project Declarative Manageme ...

  8. 解析CEPH: 存储引擎实现之一 filestore

    Ceph作为一个高可用和强一致性的软件定义存储实现,去使用它非常重要的就是了解其内部的IO路径和存储实现.这篇文章主要介绍在IO路径中最底层的ObjectStore的实现之一FileStore. Ob ...

  9. ubuntu14.04 desktop 32-bit kvm装windows xp

    经过这几天来的折腾,总算是在ubuntu14.04用kvm装上了xp, 看不少的的贴,也绕了不少的圈,总的来说,非常感谢CSDN上的"上善若水75",看着他写的一个分类" ...

随机推荐

  1. KEIL中常见问题

    1:..\Obj\phone.axf: Error: L6218E: Undefined symbol err (referred from gprs.o). 函数中定义的外部变量,找不到其源 即在g ...

  2. scp命令在linux间传送文件的方法

    当两台LINUX主机之间要互传文件时可使用SCP命令来实现,建立信任关系之后可不输入密码. 把你的本地主机用户的ssh公匙文件复制到远程主机用户的~/.ssh/authorized_keys文件中  ...

  3. AP聚类算法

    一.算法简介 Affinity Propagation聚类算法简称AP,是一个在07年发表在Science上的聚类算法.它实际属于message-passing algorithms的一种.算法的基本 ...

  4. compile vi from source code

    1.install ncurses library (vi  depend on ncurses library) ./configure --prefix=/usr --with-termlib m ...

  5. linux性能分析工具之火焰图

    一.环境 1.1 jello@jello:~$ uname -a Linux jello 4.4.0-98-generic #121-Ubuntu SMP Tue Oct 10 14:24:03 UT ...

  6. 【命令】Redis常用命令整理

    doc 环境下使用命令:       keys 命令         ?    匹配一个字符         *    匹配任意个(包括0个)字符         []    匹配括号间的任一个字符, ...

  7. java 关于wait,notify和notifyAll

    public synchronized void hurt() { //... this.wait(); //... } public synchronized void recover() { // ...

  8. Could NOT find SDL_image (missing:SDL_IMAGE_LIBRARIES SDL_IMAGE_INCLUDE_DIRS)

    sudo apt-get install libsdl-image1.2-dev

  9. 语言小知识-Java ArrayList类 深度解析

    · 问题 1:ArrayList 的 size 和 capacity 怎么理解? 如果把 ArrayList 看作一个杯子的话,capacity 就是杯子的容积,也就是代表杯子能装多少东西,而 siz ...

  10. HDU 6090 Rikka with Graph

    Rikka with Graph 思路: 官方题解: 代码: #include<bits/stdc++.h> using namespace std; #define ll long lo ...