Oracle sysdate 时间慢了!
最近发现一个问题,一个9i跑在redhat5的,居然 select sysdate from dual 出来的时间和实际时间差了几分钟,因为基于这个oracle的系统时间正确性还是有点要求的。所以只能 #date -s 2010-2-10 8:55:00 了,再#clock -w 写入COMS 注意修改时间得在root下。
在系统启动时,Linux操作系统将时间从CMOS中读到系统时间变量中,以后修改时间通过修改系统时间实现。为了保持系统时间与CMOS时间的一致
性,Linux每隔一段时间会将系统时间写入CMOS。
过了一个星期发现时间又慢了1分多。总不能三头两天的去修改时间吧,于是就想到了,计划任务和时间同步。
30 * * * * /usr/sbin/ntpdate ntp.sjtu.edu.cn >> /root/ntpdate.log
这个例子是30分同步一次时间太频繁了。
先在root下 crontab -e 来编辑新增一个 计划任务
编辑调用的是vi。
我们就新增一行
30 3 * * 0 /usr/sbin/ntpdate ntp.sjtu.edu.cn >> /root/ntpdate.log
(5个时间参数为)
0~59 表示分
1~23 表示小时
1~31 表示日
1~12 表示月份
0~6 表示星期(其中0表示星期日)
# ntpdate 210.72.145.44
# ntpdate 133.100.9.2
210.72.145.44是中国国家授时中心的官方服务器
133.100.9.2 来自:日本
配合扫黄截图就算了
相关文档:
Hey all,
Since there seems to be a fair bit of disinformation, and utter nonsense,
floating around since my talk at the Black Hat Federal security conference
the other day, I have decided to publish the following papers.
http://www.databasesecurity.com/HackingAurora.pdf
http://www.databasesec ......
ORACLE 数据库对象
——索引
q 索引是与表相关的一个可选结构
q 用以提高 SQL 语句执行的性能
q 减少磁盘I/O
q 使用 CREATE INDEX 语句创建索引
q &n ......
过程、函数
create or replace procedure p1
is
empname emp.ename%type;
begin
select ename into empname from emp where empno=7788;
dbms_output.put_line(empname);
end;
SQL> ed
SQL> /
Procedure created
SQL> exec p1;
......
搞oracle都会经常碰到rowid,本文是笔者根据网上各位的文章,加上自己学习中的体会,总结而成。
一.rowid简介
rowid就是唯一标志记录物理位置的一个id,在oracle 8版本以前,rowid由file#+block#+row#组成,占用6个bytes的空间,10 bit 的 file# ......
不错的资料,转过来,方便日后查看使用!!!
--监控索引是否使用
alter index &index_name monitoring usage;
alter index &index_name nomonitoring usage;
select * from v$object_usage where index_name =
&index_name;
--求数据文件的I/O分布
select
df.name,phyrds,phywrts,phyblkrd,phyblkwrt,sin ......