标签 监控 下的文章

Dynatrace PerformGo上海峰会掠影

Dynatrace Perform 是IT领域监控行业的领军公司,当然商业授权价格也不菲,三个人监控全球几十家份公司的所有机器,这个还是有比较牛叉;

现在很多公司都爱炒AI,风口上嘛...

以下是抓拍

IMG_20190919_081342.jpg

IMG_20190919_081346.jpg

IMG_20190919_081352.jpg

IMG_20190919_082255.jpg

IMG_20190919_085925.jpg

IMG_20190919_091713.jpg

IMG_20190919_091844.jpg

IMG_20190919_092113.jpg

IMG_20190919_093430.jpg

IMG_20190919_093536.jpg

IMG_20190919_093747.jpg

IMG_20190919_093924.jpg

IMG_20190919_094020.jpg

IMG_20190919_094201.jpg

IMG_20190919_094426.jpg

IMG_20190919_100500.jpg

IMG_20190919_100456.jpg

IMG_20190919_100431.jpg

IMG_20190919_100331.jpg

IMG_20190919_095106.jpg

IMG_20190919_094957.jpg

IMG_20190919_094911.jpg

IMG_20190919_094734.jpg

IMG_20190919_094613.jpg

IMG_20190919_102317.jpg

IMG_20190919_102131.jpg

IMG_20190919_101901.jpg

IMG_20190919_101643.jpg

IMG_20190919_101453.jpg

IMG_20190919_101234.jpg

IMG_20190919_101144.jpg

IMG_20190919_100942.jpg

IMG_20190919_100859.jpg

IMG_20190919_123349.jpg

IMG_20190919_120526.jpg

IMG_20190919_120523.jpg

IMG_20190919_120253.jpg

IMG_20190919_120145.jpg

IMG_20190919_120145.jpg

IMG_20190919_120027.jpg

IMG_20190919_112400.jpg

IMG_20190919_111104.gif

IMG_20190919_111001.gif

IMG_20190919_110726.jpg

IMG_20190919_110207.jpg

IMG_20190919_103200.jpg

IMG_20190919_102416.jpg

IMG_20190919_145718.jpg
最后来一张红帽的小礼物

Zabbix3.4.11使用Orabbix插件监控Oracle 11g R2

Orabbix简介
Orabbix是设计用来为zabbix监控Oracle的数据库的插件,它提供多层次的监控,包括可用性和服务器性能的指标。
Orabbix监控的内容:

  1、数据库版本
  2、归档日志与生产趋势
  3、触发器,表/过程命中率
  4、逻辑IO性能
  5、物理IO性能
  6、PGA
  7、SGA
  8、共享池
  9、Session
  10、数据库大小

安装步骤如下:
1、JAVA环境配置
若是没有java 需要安装JDK环境:
jdk官方下载地址 http://download.oracle.com/otn/java/jdk/7u80-b15/jdk-7u80-linux-x64.tar.gz

mkdir /usr/lib/jvm/
tar -xvf jdk-7u80-linux-x64.tar.gz -C /usr/lib/jvm/
echo "export JAVA_HOME=/usr/lib/jvm/jdk1.7.0_80" >>  /etc/profile
source /etc/profile
echo "export JRE_HOME=${JAVA_HOME}/jre" >>  /etc/profile
source /etc/profile
echo "export CLASSPATH=.:${JAVA_HOME}/lib:${JRE_HOME}/lib" >>  /etc/profile
echo "export PATH=${JAVA_HOME}/bin:$PATH" >>  /etc/profile
source /etc/profile
sudo update-alternatives --install /usr/bin/java java /usr/lib/jvm/jdk1.7.0_80/bin/java 300
sudo update-alternatives --install /usr/bin/javac javac /usr/lib/jvm/jdk1.7.0_80/bin/javac 300

安装完毕查看版本:

[root@dbnode1 opt]# java -version
java version "1.7.0_80"
Java(TM) SE Runtime Environment (build 1.7.0_80-b15)
Java HotSpot(TM) 64-Bit Server VM (build 24.80-b11, mixed mode)

2、Orabbix插件的下载安装
http://www.smartmarmot.com/product/orabbix/download/
也可以直接搜索下载,目前最新版本为1.2.3

创建一个目录作为orabbix的源地址:
mkdir -p /usr/local/orabbix
解压缩插件:
unzip -n orabbix-1.2.3.zip -d /usr/local/orabbix/

3、更改配置文件:

cd /usr/local/orabbix/
cp conf/config.props.sample conf/config.props
添加系统启动脚本:
cp init.d/orabbix /etc/init.d/orabbix
并修改路径:
vim /etc/init.d/orabbix
orabbix=/usr/local/orabbix

给启动脚本加执行权限

chmod +x /usr/local/orabbix/run.sh
chmod +x /etc/init.d/orabbix

修改配置文件内如如下

cat /usr/local/orabbix/conf/config.props | grep -v "^$"|grep -v "^#"

ZabbixServerList=ZabbixServer1

ZabbixServer1.Address=192.168.3.209
ZabbixServer1.Port=10051


OrabbixDaemon.PidFile=./logs/orabbix.pid
OrabbixDaemon.Sleep=300
OrabbixDaemon.MaxThreadNumber=100

DatabaseList=dbnode1

DatabaseList.MaxActive=10
DatabaseList.MaxWait=100
DatabaseList.MaxIdle=1

dbnode1.Url=jdbc:oracle:thin:@192.168.2.110:1521:ORCL
dbnode1.User=zabbix
dbnode1.Password=xxxxxxxx
dbnode1.MaxActive=10
dbnode1.MaxWait=100
dbnode1.MaxIdle=1
dbnode1.QueryListFile=./conf/query.props

4、使用DBA账号登陆oracle控制台,创建zabbix用户并赋权

CREATE USER ZABBIX IDENTIFIED BY ZABBIX2018 DEFAULT TABLESPACE SYSTEM TEMPORARY TABLESPACE TEMP PROFILE DEFAULT ACCOUNT UNLOCK;

GRANT ALTER SESSION TO ZABBIX;
GRANT CREATE SESSION TO ZABBIX;
GRANT CONNECT TO ZABBIX;
GRANT RESOURCE TO ZABBIX;
ALTER USER ZABBIX DEFAULT ROLE ALL;
GRANT SELECT ON V_$INSTANCE TO ZABBIX;
GRANT SELECT ON DBA_USERS TO ZABBIX;
GRANT SELECT ON V_$LOG_HISTORY TO ZABBIX;
GRANT SELECT ON V_$PARAMETER TO ZABBIX;
GRANT SELECT ON SYS.DBA_AUDIT_SESSION TO ZABBIX;
GRANT SELECT ON V_$LOCK TO ZABBIX;
GRANT SELECT ON DBA_REGISTRY TO ZABBIX;
GRANT SELECT ON V_$LIBRARYCACHE TO ZABBIX;
GRANT SELECT ON V_$SYSSTAT TO ZABBIX;
GRANT SELECT ON V_$LATCH TO ZABBIX;
GRANT SELECT ON V_$PGASTAT TO ZABBIX;
GRANT SELECT ON V_$SGASTAT TO ZABBIX;
GRANT SELECT ON V_$LIBRARYCACHE TO ZABBIX;
GRANT SELECT ON V_$PROCESS TO ZABBIX;
GRANT SELECT ON DBA_DATA_FILES TO ZABBIX;
GRANT SELECT ON DBA_TEMP_FILES TO ZABBIX;
GRANT SELECT ON DBA_FREE_SPACE TO ZABBIX;
GRANT SELECT ON V_$SYSTEM_EVENT TO ZABBIX;
GRANT SELECT ANY TABLE TO ZABBIX;
GRANT SELECT ANY DICTIONARY TO ZABBIX;
GRANT UNLIMITED TABLESPACE TO ZABBIX;

以下授权需要使用sysdba账号登陆
GRANT SELECT ON V_$LOG_HISTORY TO ZABBIX;
GRANT SELECT ON SYS.DBA_AUDIT_SESSION TO ZABBIX;
GRANT SELECT ON V_$LIBRARYCACHE TO ZABBIX;
GRANT SELECT ON DBA_DATA_FILES TO ZABBIX;
GRANT SELECT ON DBA_TEMP_FILES TO ZABBIX;
GRANT SELECT ON DBA_FREE_SPACE TO ZABBIX;
GRANT SELECT ON V_$SYSTEM_EVENT TO ZABBIX;
GRANT SELECT ON V_$SESSION TO ZABBIX; 
exec dbms_network_acl_admin.create_acl(acl => 'resolve.xml',description => 'resolve acl', principal =>'ZABBIX', is_grant => true, privilege => 'resolve');
exec dbms_network_acl_admin.assign_acl(acl => 'resolve.xml', host =>'*');
COMMIT;

5、启动orabbix服务、加入开机启动:

/etc/init.d/orabbix start
chkconfig orabbix on

6、查看日志

tail -f /usr/local/orabbix/logs 
 2018-07-17 11:36:36,662 [pool-1-thread-1] ERROR Orabbix - Error on DBEnquiry on query=archive on database=dbnode1 Error returned is java.lang.IllegalArgumentException: null value for key 'archive'
 2018-07-17 11:36:36,664 [pool-1-thread-1] WARN  Orabbix - Error while executing ->audit- on database ->dbnode1- Exception received ORA-00942: table or view does not exist

 2018-07-17 11:36:36,665 [pool-1-thread-1] WARN  Orabbix - Error while executing ->dbblockgets- on database ->dbnode1- Exception received ORA-00942: table or view does not exist

 2018-07-17 11:36:36,665 [pool-1-thread-1] ERROR Orabbix - Error on DBEnquiry on query=dbblockgets on database=dbnode1 Error returned is java.lang.IllegalArgumentException: null value for key 'dbblockgets
'
 2018-07-17 11:36:36,666 [pool-1-thread-1] WARN  Orabbix - Error while executing ->dbconsistentgets- on database ->dbnode1- Exception received ORA-00942: table or view does not exist

 2018-07-17 11:36:36,666 [pool-1-thread-1] ERROR Orabbix - Error on DBEnquiry on query=dbconsistentgets on database=dbnode1 Error returned is java.lang.IllegalArgumentException: null value for key 'dbcons
istentgets'
 2018-07-17 11:36:36,667 [pool-1-thread-1] WARN  Orabbix - Error while executing ->dbhitratio- on database ->dbnode1- Exception received ORA-00942: table or view does not exist

 2018-07-17 11:36:36,667 [pool-1-thread-1] ERROR Orabbix - Error on DBEnquiry on query=dbhitratio on database=dbnode1 Error returned is java.lang.IllegalArgumentException: null value for key 'dbhitratio'
 2018-07-17 11:36:36,668 [pool-1-thread-1] WARN  Orabbix - Error while executing ->dbphysicalread- on database ->dbnode1- Exception received ORA-00942: table or view does not exist

 2018-07-17 11:36:36,668 [pool-1-thread-1] ERROR Orabbix - Error on DBEnquiry on query=dbphysicalread on database=dbnode1 Error returned is java.lang.IllegalArgumentException: null value for key 'dbphysic
alread'
 2018-07-17 11:36:36,670 [pool-1-thread-1] WARN  Orabbix - Error while executing ->dbversion- on database ->dbnode1- Exception received ORA-00942: table or view does not exist

如果有以上类似的报错,基本都是zabbix用户权限不够导致,参考赋权;
正常log如下:

 2018-07-20 17:06:16,915 [pool-1-thread-47] INFO  Orabbix - Done with dbJob on database dbnode1 QueryList elapsed time 18537 ms
 2018-07-20 17:06:58,428 [pool-1-thread-48] INFO  Orabbix - Done with dbJob on database dbnode1 QueryList elapsed time 48 ms
 2018-07-20 17:08:16,967 [pool-1-thread-49] INFO  Orabbix - Done with dbJob on database dbnode1 QueryList elapsed time 18586 ms
 2018-07-20 17:08:58,418 [pool-1-thread-50] INFO  Orabbix - Done with dbJob on database dbnode1 QueryList elapsed time 35 ms
 2018-07-20 17:10:17,033 [pool-1-thread-51] INFO  Orabbix - Done with dbJob on database dbnode1 QueryList elapsed time 18648 ms
 2018-07-20 17:10:58,418 [pool-1-thread-52] INFO  Orabbix - Done with dbJob on database dbnode1 QueryList elapsed time 31 ms
 2018-07-20 17:12:17,225 [pool-1-thread-53] INFO  Orabbix - Done with dbJob on database dbnode1 QueryList elapsed time 18836 ms
 2018-07-20 17:12:58,426 [pool-1-thread-54] INFO  Orabbix - Done with dbJob on database dbnode1 QueryList elapsed time 35 ms
 2018-07-20 17:14:17,013 [pool-1-thread-55] INFO  Orabbix - Done with dbJob on database dbnode1 QueryList elapsed time 18621 ms
 2018-07-20 17:14:58,429 [pool-1-thread-56] INFO  Orabbix - Done with dbJob on database dbnode1 QueryList elapsed time 35 ms
 2018-07-20 17:16:17,087 [pool-1-thread-57] INFO  Orabbix - Done with dbJob on database dbnode1 QueryList elapsed time 18691 ms

/usr/local/orabbix下面有个template目录,里面是zabbix模板,将这些模板copy到本地机器上,然后登陆zabbix,把模板导入进去,就可以配置机器了,zabbix是3.x以上版本的话直接导入不进去,只能先导入2.x版本,然后再导出,然后导入3.x
或者直接用修改后Zabbix3.x可以直接使用的模板
zabbix_oracle_orabbix.zip
导入,并添加对应模板即可,完成以后效果如下:
1.png
2.png
3.png
4.png
5.png
10.png
VIA: http://www.smartmarmot.com/wiki/index.php?title=Orabbix
https://blog.csdn.net/tianhua79658788/article/details/77969426

安装greenplum-cc-web-3.2.0监控工具

所有节点都提前部署好了greenplum-db数据库,且数据库及节点能启动正常并可访问,参考安装文档:https://unixso.com/PostgreSQL/GreenPlum.html
一、解压安装

unzip greenplum-cc-web-3.2.0-LINUX-x86_64.zip
./greenplum-cc-web-3.2.0-LINUX-x86_64.bin
安装过程中控制台提示一律yes

greenplum-cc-web默认安装在/usr/local/目录下
在/home/gpadmin/.bash_profile文件中增加

source /usr/local/greenplum-cc-web/gpcc_path.sh

赋予gpadmin用户权限:

chown -R gpadmin:gpadmin /usr/local/greenplum-cc-web-3.2.0
chown -R gpadmin:gpadmin /usr/local/greenplum-cc-web

给其他三台机器安装greenplum-cc-web

cat /usr/local/greenplum-db/gpconfig/dw234
smdw
sdw1
sdw2
gpccinstall -f /usr/local/greenplum-db/gpconfig/dw234

在/data/gpmaster/gpseg-1/pg_hba.conf中添加用户登录权限(如果不添加可能会导致不能创建gpcc实例)

host  all   all   ::1/128  trust

重启GP

gpstop -r

设置the Command Center Console

[gpadmin@dw01 ~]$ gpcmdr --setup

The instance name identifies the GPDB cluster this Greenplum Command Center web UI monitors and controls.
Instance names can contain letters, digits, and underscores and are not case sensitive.

Please enter the instance name
gpmon_ys

The display name is shown as the "server" in the web interface and does not need to be
a hostname.Display names can contain letters, digits, and underscores and ARE case sensitive.

Please enter the display name for this instance:(Press ENTER to use instance name)
gpmon_db

A GPCC instance can be set to manage and monitor a remote Greenplum Database.
Notice: remote mode will disable these functionalities:
1. Standby host for GPCC.
2. Workload Manager UI.

Is the master host for the Greenplum Database remote? Yy/Nn (default=N)
n

What port does the Greenplum Database use? (default=5432)


Enable kerberos login for this instance? Yy/Nn (default=N)
n

Creating instance schema in GPDB.  Please wait ...

The Greenplum Command Center runs a small web server for the UI and web API.
This web server by default runs on port 28080, but you may specify any available port.

What port would you like the new web server to use for this instance? (default=28080)


Users logging in to the Command Center must provide database user
credentials. In order to protect user names and passwords, it is recommended
that SSL be enabled.

Enable SSL for the Web API Yy/Nn (default=N)
n

Copy the instance to a standby master host Yy/Nn (default=Y)
y

What is the hostname of the standby master host?
smdw
standby is smdw
Done writing webserver configuration to  /usr/local/greenplum-cc-web/instances/gpmon_ys/webserver/conf/app.conf
Copying instance gpmon_ys to host smdw ...
=>Cleanup standby host's instance gpmon_ys if any ...
=>Copying the instance folder to standby host ...

Creating instance at /usr/local/greenplum-cc-web/instances/gpmon_ys

Greenplum Command Center UI configuration is now complete.

To change parameters of this instance, edit the configuration file
at /usr/local/greenplum-cc-web/instances/gpmon_ys/webserver/conf/app.conf

To configure multi-cluster view, edit the configuration file at /usr/local/greenplum-cc-web/instances/gpmon_ys/conf/clusters.conf

The web UI for this instance is located at http://dw01:28080

You can now start the web UI for this instance by running: gpcmdr --start gpmon_ys

启动实例

gpcmdr --start gpmon_ys
Starting instance gpmon_ys ...
Greenplum Command Center UI for instance 'gpmon_ys' - [RUNNING on PORT: 28080, pid 11984]

访问console,打开浏览器,在地址栏输入http://mastert[或者你主机的ip地址]:28080,如果出现以下界面,那么恭喜你,你的greenplum-cc-web全部安装成功!
web1.png
用户名是默认的gpmon
密码是安装Performance Monitor时的密码,登陆进去界面如下:
web2.png
web3.png
官方安装文档:
https://gpcc.docs.pivotal.io/320/gpcc/topics/setup-software.html

最新

分类

归档

评论

其它