|
|
ganglai采集数据
5 ^+ }) s( D- \3 ]需要配置ganglai的配置文件gmod.conf
# p0 q; {! x' g/ h" {+ T: D# l, J; h6 D' T# A$ [
deaf = no #服务端配置no,客户端配置yes
D$ F8 C' [$ a3 y2 J. |
0 h' Z1 M$ K" T找到下面配置:客户端和服务端一样。
/ y" P' ^& u, c* W udp_send_channel { #bind_hostname = yes # Highly recommended, soon to be default., l; h* A6 _" b! Z: j) n6 [
# This option tells gmond to use a source address! Y c+ V' B, H: L
# that resolves to the machine's hostname. Without2 `7 { B* Y9 ^5 x9 W/ s W( p
# this, the metrics may appear to come from any
0 Y% F; p& @* S' A" I # interface and the DNS names associated with
2 f, _* _% e4 W# A( a1 j # those IPs will be used to create the RRDs.
) y2 y1 ]/ d3 {6 T2 ?! ]% Q& C# mcast_join = 239.2.11.71
+ u3 c- _+ V& l/ U" a% \ host = clm.ganglia.server$ _% W6 T; K. [* j
port = 86498 l6 M9 ?7 i8 X0 [
# ttl = 1
$ ^. B1 _# l3 N- b* ]1 [}
9 o) S, W+ ?5 c* m+ D
( f! h7 M2 D N; d重启gmod.service服务' |, y: }. ^1 \7 e! Y' Y3 [- P
systemctl restart gmod.service
3 B! j' ^ s v( g. a( ], n
8 E# M6 B2 k$ T1 G添加需要添加语句:/ q; B/ c6 x/ D9 @
mysql> insert into`subnet_server_info_tab` (`SubnetId`, `RocksServerIP`, `RocksServerID`,`RocksServerPassword`, `GangliaServerIP`, `GangliaServerID`,`GangliaServerPassword`, `NagiosServerIP`, `NagiosServerID`,`NagiosServerPassword`, `AutoDetectFlag`, `LocalTable_ID_Ref`, `RocksLock`,`ganglia4bcec`) values('CIDC-R-01-IPSUB-00000323','','','','10.15.4.3','','','','','','','njpm','','');( I& T' \( I/ H0 n8 X& |
; f; m( Z7 h& tQuery OK, 1 row affected ) ~, w! b5 n) r- K
CIDC-R-01-IPSUB-00000323 #系统中配置的网络段地址
# ^* Y7 d; G. j% [ f# i 10.15.4.3 #为服务端的地址。
% o& V: m% F% L. D$ B接下来启动performance服务
1 ^. E h! T- z
% @5 v% Z; } z! l7 _* ?3 Y& M
' q8 a! }6 e( d$ r" `* U9 H) }# [4 G4 W1 H* h
' j3 ~- v4 P, o6 ?6 |+ G# cd /apps/svr/PerformancePM
6 q3 I) Y2 Q5 L: h. l# e#/apps/svr/PerformancePM/Performance/startup.sh
" k: b5 R. f7 E t3 g$ J5 _" t; E3 m& M. `0 K
# ps -ef |grep performance
1 M0 E1 z( L$ s3 y, a& Q! z4 p% R! T
|
|