Advertisement
Guest User

Untitled

a guest
May 29th, 2017
331
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 9.08 KB | None | 0 0
  1. # my global config
  2. global:
  3. scrape_interval: 15s # By default, scrape targets every 15 seconds.
  4. evaluation_interval: 15s # By default, scrape targets every 15 seconds.
  5. # scrape_timeout is set to the global default (10s).
  6.  
  7. # Attach these labels to any time series or alerts when communicating with
  8. # external systems (federation, remote storage, Alertmanager).
  9. external_labels:
  10. monitor: 'tirn'
  11.  
  12. # Load rules once and periodically evaluate them according to the global 'evaluation_interval'.
  13. rule_files:
  14. - 'alerts.rules'
  15. # - "first.rules"
  16. # - "second.rules"
  17.  
  18. # Remote write configuration (for Graphite, OpenTSDB, or InfluxDB).
  19. remote_write:
  20. - url: "http://localhost:9201/write"
  21.  
  22. # Remote read configuration (for InfluxDB only at the moment).
  23. remote_read:
  24. - url: "http://localhost:9201/read"
  25.  
  26. # Definitions of targets to scrape
  27. scrape_configs:
  28.  
  29. - job_name: 'prometheus'
  30. static_configs:
  31. - targets: ['localhost:9090']
  32. labels:
  33. instance: 'tirn'
  34.  
  35. - job_name: 'node_exporter'
  36. basic_auth:
  37. username: "XXXXXXXXXXXX"
  38. password: "XXXXXXXXXXX"
  39. static_configs:
  40. - targets:
  41. - 'node.prometheus.tharan.simonszu.de'
  42. - 'openwrt:9100'
  43. - 'localhost:9100'
  44. - 'calad:9100'
  45. - 'estolad:9100'
  46. - 'nostor:9100'
  47. - 'dath:9100'
  48. relabel_configs:
  49. # Extract hostname and use it as instance name
  50. - source_labels: [__address__]
  51. regex: ([^:]+)(:9100)?
  52. target_label: instance
  53. replacement: ${1}
  54. # Completely replace instance name for tharan
  55. - source_labels: [__address__]
  56. regex: node\.prometheus\.tharan\.simonszu\.de
  57. target_label: instance
  58. replacement: tharan
  59. # Change instance name from localhost to tirn
  60. - source_labels: [instance]
  61. regex: localhost
  62. target_label: instance
  63. replacement: tirn
  64.  
  65. - job_name: 'ping'
  66. metrics_path: /probe
  67. params:
  68. module: [ping]
  69. static_configs:
  70. - targets:
  71. - openwrt
  72. - freifunk
  73. - estolad
  74. - gigaset
  75. - firetv
  76. - tirn
  77. - calad
  78. - fritzbox
  79. - yamaha
  80. - hue
  81. - nostor
  82. - chromecast
  83. - atlasprobe
  84. - homematic
  85. - simonszu.de
  86. - sw-simon
  87. - sw-frauke
  88. - sw-tv
  89. - sw-schrank
  90. - sw-main
  91. - dath
  92. - wlan
  93. relabel_configs:
  94. # Set the target's address as the target-GET-parameter for the blackbox exporter
  95. - source_labels: [__address__]
  96. regex: (.*)
  97. target_label: __param_target
  98. replacement: ${1}
  99. # Set the target's address as the instance name
  100. - source_labels: [__address__]
  101. regex: (.*)
  102. target_label: instance
  103. replacement: ${1}
  104. # Rename instance for simonszu.de to tharan
  105. - source_labels: [instance]
  106. regex: simonszu\.de
  107. target_label: instance
  108. replacement: tharan
  109. # Set the scrape address to the blackbox exporter
  110. - source_labels: []
  111. regex: .*
  112. target_label: __address__
  113. replacement: 127.0.0.1:9115
  114.  
  115. - job_name: 'http'
  116. metrics_path: /probe
  117. params:
  118. module: [http]
  119. static_configs:
  120. - targets:
  121. - openwrt
  122. - gigaset
  123. - fritzbox
  124. - yamaha
  125. - sw-simon
  126. - sw-frauke
  127. - sw-tv
  128. - sw-schrank
  129. - sw-main
  130. relabel_configs:
  131. # Set the target's address as the target-GET-parameter for the blackbox exporter
  132. - source_labels: [__address__]
  133. regex: (.*)
  134. target_label: __param_target
  135. replacement: ${1}
  136. # Set the target's address as the instance name
  137. - source_labels: [__address__]
  138. regex: (.*)
  139. target_label: instance
  140. replacement: ${1}
  141. - source_labels: [instance]
  142. regex: simonszu\.de
  143. target_label: instance
  144. replacement: tharan
  145. # Set the scrape address to the blackbox exporter
  146. - source_labels: []
  147. regex: .*
  148. target_label: __address__
  149. replacement: 127.0.0.1:9115
  150.  
  151. - job_name: 'ssh'
  152. metrics_path: /probe
  153. params:
  154. module: [ssh]
  155. static_configs:
  156. - targets:
  157. - openwrt
  158. - freifunk
  159. - estolad
  160. - calad
  161. - tirn
  162. - simonszu.de
  163. - nostor
  164. - dath
  165. relabel_configs:
  166. # Set the target's address as the target-GET-parameter for the blackbox exporter
  167. - source_labels: [__address__]
  168. regex: (.*)
  169. target_label: __param_target
  170. replacement: ${1}:22
  171. # Set the target's address as the instance name
  172. - source_labels: [__address__]
  173. regex: (.*)
  174. target_label: instance
  175. replacement: ${1}
  176. # Rename instance for simonszu.de to tharan
  177. - source_labels: [instance]
  178. regex: simonszu\.de
  179. target_label: instance
  180. replacement: tharan
  181. # Set the scrape address to the blackbox exporter
  182. - source_labels: []
  183. regex: .*
  184. target_label: __address__
  185. replacement: 127.0.0.1:9115
  186.  
  187. - job_name: 'xmpp'
  188. metrics_path: /probe
  189. params:
  190. module: [xmpp]
  191. static_configs:
  192. - targets:
  193. - simonszu.de
  194. relabel_configs:
  195. # Set the target's address as the target-GET-parameter for the blackbox exporter
  196. - source_labels: [__address__]
  197. regex: (.*)
  198. target_label: __param_target
  199. replacement: ${1}:5222
  200. # Set the target's address as the instance name
  201. - source_labels: [__address__]
  202. regex: (.*)
  203. target_label: instance
  204. replacement: ${1}
  205. # Rename instance for simonszu.de to tharan
  206. - source_labels: [instance]
  207. regex: simonszu\.de
  208. target_label: instance
  209. replacement: tharan
  210. # Set the scrape address to the blackbox exporter
  211. - source_labels: []
  212. regex: .*
  213. target_label: __address__
  214. replacement: 127.0.0.1:9115
  215.  
  216. - job_name: 'smtp'
  217. metrics_path: /probe
  218. params:
  219. module: [smtp]
  220. static_configs:
  221. - targets:
  222. - simonszu.de
  223. relabel_configs:
  224. # Set the target's address as the target-GET-parameter for the blackbox exporter
  225. - source_labels: [__address__]
  226. regex: (.*)
  227. target_label: __param_target
  228. replacement: ${1}:25
  229. # Set the target's address as the instance name
  230. - source_labels: [__address__]
  231. regex: (.*)
  232. target_label: instance
  233. replacement: ${1}
  234. # Rename instance for simonszu.de to tharan
  235. - source_labels: [instance]
  236. regex: simonszu\.de
  237. target_label: instance
  238. replacement: tharan
  239. # Set the scrape address to the blackbox exporter
  240. - source_labels: []
  241. regex: .*
  242. target_label: __address__
  243. replacement: 127.0.0.1:9115
  244.  
  245. - job_name: 'znc'
  246. metrics_path: /probe
  247. params:
  248. module: [znc]
  249. static_configs:
  250. - targets:
  251. - simonszu.de
  252. relabel_configs:
  253. # Set the target's address as the target-GET-parameter for the blackbox exporter
  254. - source_labels: [__address__]
  255. regex: (.*)
  256. target_label: __param_target
  257. replacement: ${1}:31337
  258. # Set the target's address as the instance name
  259. - source_labels: [__address__]
  260. regex: (.*)
  261. target_label: instance
  262. replacement: ${1}
  263. # Rename instance for simonszu.de to tharan
  264. - source_labels: [instance]
  265. regex: simonszu\.de
  266. target_label: instance
  267. replacement: tharan
  268. # Set the scrape address to the blackbox exporter
  269. - source_labels: []
  270. regex: .*
  271. target_label: __address__
  272. replacement: 127.0.0.1:9115
  273.  
  274. - job_name: 'nginx'
  275. basic_auth:
  276. username: "XXXXXXXXXXX"
  277. password: "XXXXXXXXXXXXX"
  278. static_configs:
  279. - targets:
  280. - 'nginx.prometheus.tharan.simonszu.de'
  281. - 'estolad:9145'
  282. relabel_configs:
  283. # Extract hostname and use it as instance name
  284. - source_labels: [__address__]
  285. regex: ([^:]+)(:9100)?
  286. target_label: instance
  287. replacement: ${1}
  288. # Completely replace instance name for tharan
  289. - source_labels: [__address__]
  290. regex: nginx\.prometheus\.tharan\.simonszu\.de
  291. target_label: instance
  292. replacement: tharan
  293.  
  294. - job_name: 'mysql'
  295. basic_auth:
  296. username: "XXXXXXXXXXX"
  297. password: "XXXXXXXXXXX"
  298. static_configs:
  299. - targets:
  300. - 'mysql.prometheus.tharan.simonszu.de'
  301. - 'estolad:9104'
  302. relabel_configs:
  303. # Extract hostname and use it as instance name
  304. - source_labels: [__address__]
  305. regex: ([^:]+)(:9104)?
  306. target_label: instance
  307. replacement: ${1}
  308. # Completely replace instance name for tharan
  309. - source_labels: [__address__]
  310. regex: mysql\.prometheus\.tharan\.simonszu\.de
  311. target_label: instance
  312. replacement: tharan
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement