oracle 备份,表空间检查shell脚本代码
#!/bin/ksh
#****************************************************************************
#
# (C) Copyright CPIC. 2008
#
# File name: check_db_alert.sh
# Project: Database Alerts Check
#
# Parameter : app_name -- name of db application(=oracle_sid)
# ipaddress -- ip of the db server
#
# Creation Date: Aug 19, 2008
# Origin Author: Shangkun Peng
#
#
# Prerequisites:
# before using this shell script, directory $DAILY_CHECK must be created
# and this shell script should be put into it.
# for each application, environment file $DBENVFILE must be put into it.
# also, variables for auto ftp must be set
#
# Limitations:
# this shell script can be run at most once an hour
# additional job can be added but variable JOB_LIST must be modified
# and relative function must be coded too
#
#****************************************************************************
# record start date and time
echo "------------------------------------------------------------"
echo "database information collect started at:"; date
# check necessary parameter(s)
if [ $# -ne 2 ]
then
echo "ERROR: parameter(s) not supplied correctly"
echo "USAGE: check_db_alert.sh app_name ipaddress"
echo "WHERE:"
echo "app_name -- name of db application"
echo "ipaddress -- ip of the db server"
exit 1
fi
# -----------------------------------------------------------------------------------------------------------
# DEFINE VALUES FOR VARIABLES IN THIS SHELL
# general variables, can not be modified
APP_NAME=$1 # name of db application
IPADDRESS=$2 # ip of db server
DAILY_CHECK=/tmp/db_dailycheck # directory for information collection of db application
DBENVFILE=$APP_NAME".dbenv"&
相关文档:
Oracle中用Rowid查找和删除重复记录
平时工作中可能会碰到当试图对库表中的某一列或几列创建唯一索引时,系统提示 ORA-01452 :不能创建唯一索引,发现重复记录。
下面总结一下几种查找和删除重复记录的方法(以表CZ为例):
表CZ的结构如下:
SQL> desc cz
Name Null? Type
---------- ......
oracle分页???
在mysql中只要limit x,y就可以分页成功,那oracle 中是怎么做的呢?
=================================================
方法一:
SELECT id,rown
from (SELECT id, ROWNUM rown
&nb ......
Oracle
索引技术的应用与剖析
最
近这段时间,总是想写一些有关性能调优的文章。但是苦于没有一个实际的案例,本人又不愿空谈理论,因为这些理论随便在网上就能找到,而且基本上千篇一律,
因为理论上的那些东西就那么多,再怎么讲也不如一个实际案例生动。还好上天不负有心人,前些天让我碰到了一个实际的案例。这个 ......
玩Oracle也有2年的时间了, 零零散散的也整理一些资料。 东西一多了,就理不清楚。 所以结合张晓明的《大话Oracle RAC》的一些内容,和自己整理的一些笔记,对Oracle 的备份和恢复做了一个系统的整理。 也是自己对知识的一个巩固吧。
一. 准备知识
先来看一些准备知识,了解 ......