[HP-UX] ORA-01081: cannot start already-running ORACLE - shut it down first
Oracle启动的时候报了这个错误:ORA-01081: cannot start already-running ORACLE - shut it down firstipcs查看shared memory后,发现有oracle的shared memory[root@xxxxx002:/]# ipcs -mIPC status from /dev/kmem as of Tue Apr 5 22:58:59 2016T ID KEY &...
[HP-UX] ERROR: Function activate_volume_group
小机重启后,执行cmrunpkg -v -n XXXXX002 pkg_X3PROD的时候log中会出现如下错误:########### Node "XXXXX002": Package start failed at Mon Apr 4 22:28:39 EAT 2016 ###########/etc/cmcluster/pkg_X3PROD/pkg_X3PROD.cntl: OMMENT: not found.########### Node "XXXXX002": Starting package at Mon Apr...
[HP-UX] cmviewcl运行时提示cmviewcl : Cannot talk to all the nodes.
机器重启后,运行cmviewcl后出现了如下错误:[root@xxxxx016:/]# cmviewclcmviewcl : Cannot talk to all the nodes.Cluster does not appear to be upCLUSTER STATUS cluster3 unknown NODE ...
[Developer] Oracle send mail procedure(2)
CREATE OR REPLACE PACKAGE demo_base64 IS FUNCTION encode(r IN RAW) RETURN VARCHAR2; end; CREATE OR REPLACE PACKAGE BODY demo_base64 IS TYPE vc2_table IS TABLE OF VARCHAR2(1) INDEX BY BINARY_INTEGER; map vc2_table; PROCEDURE ...
8.Monitor oracle alert.log file and sendmail
自己写的每隔一分钟检测alert.log文件是否有错误,如果有错误,则mail出来。第一次写,有很多地方没有考虑到。以后多加改善[mon@oracle6 source]$ more mon_alert_log #!/bin/bashalertlog=/u01/oracle/diag/rdbms/xxxxxdb/xxxxxdb/trace/alert_xxxxxdb.log #alert file locationda...
[Shell] monitor oracle alert.log file and sendmail
自己写的每隔一分钟检测alert.log文件是否有错误,如果有错误,则mail出来。第一次写,有很多地方没有考虑到。以后多加改善[mon@oracle6 source]$ more mon_alert_log #!/bin/bashalertlog=/u01/oracle/diag/rdbms/xxxxxdb/xxxxxdb/trace/alert_xxxxxdb.log #alert file locationda...
[Shell] awk 判断列的大小例子
这个是chinaunix论坛上看到的问题,也测试一下.有原始文件[/tmp/test]# cat tt10N1 5 6 8 4 1 2 1 &...
[Shell] awk NR,FNR,NF
NR: 已经读出的记录数FNR:当前文件的记录数NF:当前记录中的字段(列,域)个数[/tmp/test]# cat tt150 IT China 800 ...
[Developer] Oracle sendmail procedure(1)(转载)
CREATE OR REPLACE PROCEDURE send_mail( p_recipient VARCHAR2, -- 邮件接收人 p_subject VARCHAR2, -- 邮件标题 p_message VARCHAR2 -- 邮件正文 ) IS ...
[Oracle] ORA-24247: network access denied by access control list(ACL)
利用utl_smtp发送邮件的时候,会出现如下错误,具体方法如下:ORA-20001: The send mail was error ORA-24247: network access denied by access control list(ACL)BEGIN DBMS_NETWORK_ACL_ADMIN.CREATE_ACL ( acl => 'email_server_permissions.xml', descript...
[Shell] shell中的内部变量
1.BASH二进制执行文件的位置,版本[root@oracle6 /]# echo $BASH/bin/bash[root@oracle6 /]# echo $BASH_VERSION4.1.2(1)-release2.home目录[root@oracle6 /]# echo $HOME/root3.$? : shell command的返回值[root@oracle6 /]# ping 172.16.20.31 这个ip能ping通--- 17...
7.monitor oracle database listener & instance status
monitor oracle database listener & instance status[mon@oracle source]$ crontab -l* * * * * /home/mon/source/mon_db >> /home/mon/log/mon_db.log[mon@oracle source]$ more mon_db #!/bin/bashexport ORACLE_BASE=/u01/oracleexport ORACLE_HOME=$ORACLE_BASE/product/11.2.0.4/dbhome_1export ORAC...
[Shell] monitor oracle database listener & instance status
monitor oracle database listener & instance status[mon@oracle source]$ crontab -l* * * * * /home/mon/source/mon_db >> /home/mon/log/mon_db.log[mon@oracle source]$ more mon_db #!/bin/bashexport ORACLE_BASE=/u01/oracleexport ORACLE_HOME=$ORACLE_BASE/product/11.2.0.4/dbhome_1export ORAC...
[Shell] Shell 生成 HTML脚本,可显示表格
Shell 生成 HTML脚本生成的格式不好看,以后要多改进.[mon@oracle6 source]$ more gen_html #!/bin/bash datetime=`date +"%Y/%m/%d %H:%M:%S"`DATA=/home/mon/source/config/mon_host_stat.dataMAILLIST=tolilong@163.com,bruce_lilong@163.comCOUNT=4MAILLIST=tolilong@163.comHTMLFILE=/home/mon/d...
[Oracle] Clustering Factor
1.Clustering Factor is a measure of the orderedness of an index in comparison to the table that is based upon It is used as an indicator for computing the estimated cost of the table lookup following an index access.2.The Clustering Factor records the number of data blocks that will be acces...
[Shell] awk sub,gsub
sub 只替换每行的第一个匹配字符gsub会替换当前行的所有匹配字符[/tmp/test]# more tt150 IT China 800 10 ACC...
[Shell] awk FS,OFS,RS,ORS
FS :是列分隔符,默认是空格OFS:是输出列的分隔符RS :是行分隔符,默认是空格ORS:是输出行的分隔符[/]# echo "a b c d" | awk '{print $1}'a[/]# echo "a b c d" | awk '{print $0}' a b c d[/]# echo "a:b:c:d" | awk '{print $1}'a:b:c:d[/]# echo "a:b:c:d" | awk 'BEGIN{FS=":"}{print $1}'a[/]# echo...
[Shell] 统计字符串出现的次数和排序(cut,sort,uniq)
对tt3文本中出现的url进行统计并排序[/tmp/test]# cat tt3http://www.baidu.com/index.htmlhttp://www.google.com/index.htmlhttp://www.baidu.com/index.htmlhttp://www.google.com/index.htmlhttp://www.163.com/index.htmlhttp://www.baidu.com/index.htmlhttp://www.sina.com/index.html[/tmp/test]# cat tt3...
[Shell] Sort排序的例子
source data[/tmp/test]# more tt150 IT China 800 10 ACCOUNTING ...
[Shell] Shell 生成 HTML脚本
Shell 生成 HTML脚本生成的格式不好看,以后要多改进.[mon@oracle6 source]$ more gen_html #!/bin/bash datetime=`date +"%Y/%m/%d %H:%M:%S"`DATA=/home/mon/source/config/mon_host_stat.dataMAILLIST=tolilong@163.com,bruce_lilong@163.comCOUNT=4MAILLIST=tolilong@163.comHTMLFILE=/home/mon/da...