osw使用手记

安装(下载oswg.zip包  Baseline version 2.0.4)
原理:This tool collects the following kinds of data using the resident host os utilities.
解压unzip oswg.zip 生成osw目录  修改权限 添加执行权限chmod -R 740 osw
验证iostat vmstat top 等工具是否安装  如果没有  查看rpm -qa|grep sysstat  procps  看sysstat或procps是否存在
查看OSWatcher.sh  有这么一段 可以判断其支持的平台
case $PLATFORM. in
  Linux)
    IOSTAT='iostat -x 1 3'
    VMSTAT='vmstat 1 3'
    TOP='eval top -b -n 1 | head -50'
    PSELF='ps -elf'
    MPSTAT='mpstat 1 3'
    MEMINFO='cat /proc/meminfo'
    SLABINFO='cat /proc/slabinfo'--/proc/slabinfo gives information about memory usage on the slab level
    ;;
  HP-UX|HI-UX)
    IOSTAT='iostat 1 3'
    VMSTAT='vmstat 1 3'
    TOP='top -d 1'
    PSELF='ps -elf'
    MPSTAT='sar -A -S 1 3' 
    ;;
  SunOS)
    IOSTAT='iostat -xn 1 3'
    VMSTAT='vmstat 1 3 '
    TOP='top -d1'
    PSELF='ps -elf'
    MPSTAT='mpstat 1 3'   
    ;;
  AIX)
    IOSTAT='iostat 1 3'
    VMSTAT='vmstat 1 3'
    TOP='top -Count 1'
    PSELF='ps -elf'
    MPSTAT='mpstat 1 3' 
    ;;
  OSF1)
    IOSTAT='iostat 1 3'
    VMSTAT='vmstat 1 3'
    TOP='top -d1'
    PSELF='ps -elf'
    MPSTAT='sar -S' 
    ;;
esac


STARTING OSW

startOSW.sh  可以带两个参数 否则选默认值
ARG1 = snapshot interval in seconds.--类型快照的间隔
ARG2 = the number of hours of archive data to store.--存储的期限

ex:
[oracle@rac1 osw]$ ./startOSW.sh
[oracle@rac1 osw]$
Info...You did not enter a value for snapshotInterval.
Info...Using default value = 30
Info...You did not enter a value for archiveInterval.
Info...Using default value = 48

Testing for discovery of OS Utilities...

VMSTAT found on your system.
IOSTAT found on your system.
MPSTAT found on your system.
NETSTAT found on your system.
TOP found on your system.

Discovery completed.

Starting OSWatcher V2.0.2  on Tue Nov 9 09:01:17 EST 2010
With SnapshotInterval = 30
With ArchiveInterval = 48

OSWatcher - Written by Carl Davis, Center of Expertise, Oracle Corporation

Starting Data Collection...

osw heartbeat:Tue Nov 9 09:01:17 EST 2010
osw heartbeat:Tue Nov 9 09:01:48 EST 2010
osw heartbeat:Tue Nov 9 09:02:19 EST 2010
osw heartbeat:Tue Nov 9 09:02:50 EST 2010
osw heartbeat:Tue Nov 9 09:03:20 EST 2010
osw heartbeat:Tue Nov 9 09:03:51 EST 2010
osw heartbeat:Tue Nov 9 09:04:22 EST 2010
osw heartbeat:Tue Nov 9 09:04:53 EST 2010
osw heartbeat:Tue Nov 9 09:05:23 EST 2010
Terminated --执行stopOSW.sh后 即终止

在osw目录下可以发现 新增了一个目录/u01/app/oracle/osw/archive
下面还有各个工具的查询结果
oswiostat  oswmeminfo  oswmpstat  oswnetstat  oswprvtnet  oswps  oswslabinfo  oswtop  oswvmstat


启动图形界面查看
java -jar OSWg.jar -i  /u01/app/oracle/osw/archive

 

 

 

 

 

 

 

 

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/21993926/viewspace-677956/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/21993926/viewspace-677956/

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值