]>
Commit | Line | Data |
---|---|---|
373d486f | 1 | # TODO: |
373d486f | 2 | # - lm_sensors subpackage |
373d486f | 3 | # - package contrib scripts as %doc |
8bf13ddb PG |
4 | # - put every plugin into subpackages |
5 | # - Current plugins status: | |
6 | # apache . . . . . . yes | |
7 | # apcups . . . . . . yes | |
95c10a4d | 8 | # apple_sensors . . . no (obvious) |
8bf13ddb PG |
9 | # ascent . . . . . . yes |
10 | # battery . . . . . . yes | |
11 | # cpu . . . . . . . . yes | |
12 | # cpufreq . . . . . . yes | |
13 | # csv . . . . . . . . yes | |
14 | # df . . . . . . . . yes | |
15 | # disk . . . . . . . yes | |
16 | # dns . . . . . . . . yes | |
17 | # email . . . . . . . yes | |
18 | # entropy . . . . . . yes | |
19 | # exec . . . . . . . yes | |
20 | # hddtemp . . . . . . yes | |
21 | # interface . . . . . yes | |
22 | # iptables . . . . . yes | |
87ba198e | 23 | # ipmi . . . . . . . yes |
95c10a4d | 24 | # ipvs . . . . . . . no (ip_vs.h not found - llh to be fixed) |
8bf13ddb | 25 | # irq . . . . . . . . yes |
95c10a4d | 26 | # libvirt . . . . . . no (requires library) |
8bf13ddb PG |
27 | # load . . . . . . . yes |
28 | # logfile . . . . . . yes | |
29 | # mbmon . . . . . . . yes | |
30 | # memcached . . . . . yes | |
31 | # memory . . . . . . yes | |
87ba198e | 32 | # multimeter . . . . no |
8bf13ddb PG |
33 | # mysql . . . . . . . yes |
34 | # netlink . . . . . . yes | |
35 | # network . . . . . . yes | |
36 | # nfs . . . . . . . . yes | |
37 | # nginx . . . . . . . yes | |
38 | # ntpd . . . . . . . yes | |
87ba198e | 39 | # nut . . . . . . . . yes |
95c10a4d | 40 | # perl . . . . . . . no (needs libperl) |
8bf13ddb PG |
41 | # ping . . . . . . . yes |
42 | # powerdns . . . . . yes | |
43 | # processes . . . . . yes | |
44 | # rrdtool . . . . . . yes | |
45 | # sensors . . . . . . yes | |
46 | # serial . . . . . . yes | |
47 | # snmp . . . . . . . yes | |
48 | # swap . . . . . . . yes | |
49 | # syslog . . . . . . yes | |
50 | # tail . . . . . . . yes | |
95c10a4d | 51 | # tape . . . . . . . no ? |
8bf13ddb PG |
52 | # tcpconns . . . . . yes |
53 | # teamspeak2 . . . . yes | |
54 | # unixsock . . . . . yes | |
55 | # users . . . . . . . yes | |
56 | # uuid . . . . . . . yes | |
57 | # vmem . . . . . . . yes | |
58 | # vserver . . . . . . yes | |
59 | # wireless . . . . . yes | |
60 | # xmms . . . . . . . yes | |
34fc103e JB |
61 | # |
62 | # Conditional build: | |
63 | %bcond_without dns # ??? | |
64 | %bcond_without ipmi # ipmi plugin package | |
65 | %bcond_without iptables # iptables plugin | |
66 | %bcond_with multimeter # multimeter plugin | |
67 | %bcond_without netlink # netlink plugin | |
68 | # | |
4b6e34c7 | 69 | #http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=358637 |
70 | %ifarch %{x8664} | |
71 | %undefine with_iptables | |
72 | %undefine with_netlink | |
73 | %endif | |
7df111b4 | 74 | Summary: Collects system information in RRD files |
322f1351 | 75 | Summary(pl.UTF-8): Zbieranie informacji o systemie w plikach RRD |
373d486f | 76 | Name: collectd |
0b998ec1 | 77 | Version: 4.5.0 |
25bc0190 | 78 | Release: 5.2 |
373d486f | 79 | License: GPL v2 |
81857fc6 | 80 | Group: Daemons |
f6984413 | 81 | Source0: http://collectd.org/files/%{name}-%{version}.tar.gz |
3dd74483 | 82 | # Source0-md5: f73dbadc8dca136b98c0f96567e0f78c |
f6984413 | 83 | Source1: %{name}.conf |
ec8f9a12 | 84 | Source2: %{name}.init |
96376a8d | 85 | Source3: %{name}-http.conf |
711f12a6 PG |
86 | Source10: %{name}-ascent.conf |
87 | Source11: %{name}-apache.conf | |
88 | Source12: %{name}-dns.conf | |
89 | Source13: %{name}-hddtemp.conf | |
90 | Source14: %{name}-ipmi.conf | |
91 | Source15: %{name}-mysql.conf | |
92 | Source16: %{name}-nginx.conf | |
93 | Source17: %{name}-notify_desktop.conf | |
94 | Source18: %{name}-notify_email.conf | |
95 | Source19: %{name}-nut.conf | |
96 | Source20: %{name}-ping.conf | |
97 | Source21: %{name}-postgresql.conf | |
98 | Source22: %{name}-powerdns.conf | |
99 | Source23: %{name}-rrdtool.conf | |
100 | Source24: %{name}-sensors.conf | |
101 | Source25: %{name}-snmp.conf | |
102 | Source26: %{name}-uuid.conf | |
103 | Source27: %{name}-xmms.conf | |
25bc0190 PG |
104 | Source28: %{name}-tcpconns.conf |
105 | Source29: %{name}-teamspeak2.conf | |
106 | Source30: %{name}-thermal.conf | |
107 | Source31: %{name}-unixsock.conf | |
108 | Source32: %{name}-users.conf | |
109 | Source33: %{name}-vmem.conf | |
110 | Source34: %{name}-vserver.conf | |
111 | Source35: %{name}-wireless.conf | |
f6984413 | 112 | URL: http://collectd.org/ |
e105712e | 113 | BuildRequires: OpenIPMI-devel |
373d486f AF |
114 | BuildRequires: autoconf |
115 | BuildRequires: automake | |
762d0c28 | 116 | BuildRequires: curl-devel |
1f0040e3 | 117 | BuildRequires: iptables-devel >= 1.4.1.1-4 |
0b998ec1 | 118 | BuildRequires: libesmtp-devel |
e105712e | 119 | BuildRequires: libnetlink-devel |
0b998ec1 | 120 | BuildRequires: libnotify-devel |
907cfb56 | 121 | BuildRequires: liboping-devel |
762d0c28 | 122 | BuildRequires: libpcap-devel |
8bf13ddb | 123 | BuildRequires: libstatgrab-devel >= 0.12 |
373d486f | 124 | BuildRequires: libtool |
3a1b5393 | 125 | BuildRequires: lm_sensors-devel |
762d0c28 | 126 | BuildRequires: mysql-devel |
87ba198e | 127 | BuildRequires: nut-devel |
18e77dbc | 128 | BuildRequires: perl-devel |
c7024cdb | 129 | BuildRequires: rpmbuild(macros) >= 1.268 |
762d0c28 | 130 | BuildRequires: rrdtool-devel |
4b6e34c7 | 131 | BuildRequires: net-snmp-devel |
8bf13ddb | 132 | BuildRequires: xmms-devel |
7df111b4 | 133 | Requires(post,preun): /sbin/chkconfig |
c7024cdb | 134 | Requires: rc-scripts |
373d486f AF |
135 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
136 | ||
9259a6ab PG |
137 | %define _pkglibdir /var/lib/%{name} |
138 | %define _webapps /etc/webapps | |
139 | %define _webapp %{name} | |
140 | %define _webappdir %{_webapps}/%{_webapp} | |
141 | %define _appdir %{_datadir}/%{_webapp} | |
142 | ||
373d486f | 143 | %description |
7df111b4 JB |
144 | collectd is a small daemon which collects system information every 10 |
145 | seconds and writes the results in an RRD-file. | |
146 | ||
147 | In contrast to most similar software, collectd is not a script but | |
148 | written in plain C for performance and portability. As a daemon it | |
149 | stays in memory, so there is no need to start up a heavy interpreter | |
150 | every time new values should be logged. This allows collectd to have a | |
151 | 10 second resolution while being nice to the system. | |
152 | ||
19cbcad3 | 153 | %description -l pl.UTF-8 |
c7024cdb ER |
154 | collectd to mały demon zbierający co 10 sekund informacje o systemie i |
155 | zapisujący wyniki do pliku RRD. | |
373d486f | 156 | |
19cbcad3 JR |
157 | W odróżnieniu od innych podobnych programów collectd nie jest |
158 | skryptem, lecz jest napisany w czystym C z myślą o wydajności i | |
159 | przenośności. Jako demon pozostaje w pamięci, więc nie ma potrzeby | |
c7024cdb ER |
160 | urychamiania ciężkiego interpretera za każdym razem, kiedy powinny być |
161 | zapisane nowe wartości. Dzięki temu collect może mieć rozdzielczość 10 | |
162 | sekund i nie obciążać zbytnio systemu. | |
373d486f | 163 | |
8bf13ddb PG |
164 | %package ascent |
165 | Summary: ascent-plugin for collectd | |
166 | Summary(pl_PL.UTF-8): Wtyczka ascent dla collectd | |
167 | Group: Daemons | |
168 | Requires: %{name} = %{version}-%{release} | |
169 | ||
170 | %description ascent | |
171 | ascent plugin for collectd. | |
172 | ||
18e77dbc | 173 | %package apache |
273ffc81 JB |
174 | Summary: apache-plugin for collectd |
175 | Summary(pl_PL.UTF-8): Wtyczka apache dla collectd | |
18e77dbc | 176 | Group: Daemons |
273ffc81 | 177 | Requires: %{name} = %{version}-%{release} |
18e77dbc | 178 | |
179 | %description apache | |
180 | This plugin collectd data provided by Apache's `mod_status'. | |
181 | ||
182 | %description apache -l pl.UTF-8 | |
273ffc81 JB |
183 | Wtyczka collectd zbierająca informacje udostępniane przez moduł |
184 | 'mod_status' Apacha. | |
18e77dbc | 185 | |
133ab397 | 186 | %package collection |
5fafedfc | 187 | Summary: Web script for collectiond |
188 | Summary(pl_PL.UTF-8): Web script for collectiond | |
189 | Group: Applications/WWW | |
190 | Requires: %{name} = %{version}-%{release} | |
191 | ||
133ab397 | 192 | %description collection |
5fafedfc | 193 | Web script for collectiond |
194 | ||
8bf13ddb PG |
195 | %package dns |
196 | Summary: dns-plugin for collectd | |
197 | Summary(pl_PL.UTF-8): Wtyczka dns dla collectd | |
198 | Group: Daemons | |
199 | Requires: %{name} = %{version}-%{release} | |
3a1b5393 | 200 | Requires: perl-rrdtool |
ef79d9ea | 201 | |
8bf13ddb PG |
202 | %description dns |
203 | dns plugin for collectd. | |
204 | ||
205 | %package hddtemp | |
206 | Summary: hddtemp-plugin for collectd | |
207 | Summary(pl_PL.UTF-8): Wtyczka hddtemp dla collectd | |
208 | Group: Daemons | |
209 | Requires: %{name} = %{version}-%{release} | |
210 | ||
211 | %description hddtemp | |
212 | hddtemp plugin for collectd. | |
213 | ||
87ba198e | 214 | %package ipmi |
215 | Summary: ipmi-plugin for collectd | |
216 | Summary(pl_PL.UTF-8): Wtyczka ipmi dla collectd | |
217 | Group: Daemons | |
218 | Requires: %{name} = %{version}-%{release} | |
219 | ||
220 | %description ipmi | |
221 | ipmi plugin for collectd. | |
222 | ||
34fc103e JB |
223 | %description ipmi -l pl.UTF-8 |
224 | Wtyczka ipmi dla collectd. | |
225 | ||
18e77dbc | 226 | %package mysql |
273ffc81 JB |
227 | Summary: mysql-plugin for collectd |
228 | Summary(pl_PL.UTF-8): Moduł mysql dla collectd. | |
18e77dbc | 229 | Group: Daemons |
273ffc81 | 230 | Requires: %{name} = %{version}-%{release} |
18e77dbc | 231 | |
232 | %description mysql | |
273ffc81 | 233 | MySQL querying plugin. This plugins provides data of issued commands, |
18e77dbc | 234 | called handlers and database traffic. |
235 | ||
236 | %description mysql -l pl.UTF-8 | |
273ffc81 JB |
237 | Moduł odpytujący MySQL. Wtyczka udostępnia dane o wydawanych |
238 | poleceniach, wywoływanych procedurach obsługi i ruchu bazodanowym. | |
18e77dbc | 239 | |
8bf13ddb PG |
240 | %package nginx |
241 | Summary: nginx-plugin for collectd | |
242 | Summary(pl_PL.UTF-8): Wtyczka nginx dla collectd | |
243 | Group: Daemons | |
244 | Requires: %{name} = %{version}-%{release} | |
245 | ||
246 | %description nginx | |
247 | nginx plugin for collectd. | |
248 | ||
7be39ce7 | 249 | %package notify_desktop |
250 | Summary: notify_desktop for collectd | |
251 | Summary(pl_PL.UTF-8): Wtyczka notify_desktop dla collectd | |
252 | Group: Daemons | |
253 | Requires: %{name} = %{version}-%{release} | |
254 | ||
255 | %description notify_desktop | |
256 | notify_desktop plugin for collectd. | |
257 | ||
b4b27e4a PG |
258 | %package notify_email |
259 | Summary: notify_email for collectd | |
260 | Summary(pl_PL.UTF-8): Wtyczka notify_email dla collectd | |
261 | Group: Daemons | |
262 | Requires: %{name} = %{version}-%{release} | |
263 | ||
264 | %description notify_email | |
265 | notify_email plugin for collectd. | |
266 | ||
267 | %package nut | |
268 | Summary: nut-plugin for collectd | |
269 | Summary(pl_PL.UTF-8): Wtyczka nut dla collectd | |
270 | Group: Daemons | |
271 | Requires: %{name} = %{version}-%{release} | |
272 | ||
273 | %description nut | |
274 | nut plugin for collectd. | |
275 | ||
907cfb56 PG |
276 | %package ping |
277 | Summary: ping-plugin for collectd | |
278 | Summary(pl_PL.UTF-8): Wtyczka ping dla collectd | |
279 | Group: Daemons | |
280 | Requires: %{name} = %{version}-%{release} | |
281 | ||
282 | %description ping | |
283 | ping plugin for collectd. | |
284 | ||
b4b27e4a PG |
285 | %package postgresql |
286 | Summary: mysql-plugin for collectd | |
287 | Summary(pl_PL.UTF-8): Moduł postgresql dla collectd. | |
288 | Group: Daemons | |
289 | Requires: %{name} = %{version}-%{release} | |
290 | ||
291 | %description postgresql | |
292 | PostgreSQL querying plugin. This plugins provides data of issued commands, | |
293 | called handlers and database traffic. | |
294 | ||
295 | %description postgresql -l pl.UTF-8 | |
296 | Moduł odpytujący PostgreSQL. Wtyczka udostępnia dane o wydawanych | |
297 | poleceniach, wywoływanych procedurach obsługi i ruchu bazodanowym. | |
298 | ||
4b6e34c7 | 299 | %package powerdns |
300 | Summary: powerdns-plugin for collectd | |
301 | Summary(pl_PL.UTF-8): Wtyczka powerdns dla collectd | |
302 | Group: Daemons | |
303 | Requires: %{name} = %{version}-%{release} | |
304 | ||
305 | %description powerdns | |
306 | powerdns plugin for collectd. | |
307 | ||
8bf13ddb PG |
308 | %package rrdtool |
309 | Summary: rrdtool-plugin for collectd | |
310 | Summary(pl_PL.UTF-8): Wtyczka rrdtool dla collectd | |
311 | Group: Daemons | |
312 | Requires: %{name} = %{version}-%{release} | |
313 | Requires: rrdtool | |
314 | ||
315 | %description rrdtool | |
316 | RRDTOOL plugin for collectd. | |
317 | ||
318 | %package sensors | |
319 | Summary: sensors-plugin for collectd | |
320 | Summary(pl_PL.UTF-8): Wtyczka sensors dla collectd | |
321 | Group: Daemons | |
322 | Requires: %{name} = %{version}-%{release} | |
323 | ||
324 | %description sensors | |
325 | This plugin collectd data provided by hardware sensors. | |
326 | ||
327 | %package snmp | |
328 | Summary: snmp-plugin for collectd | |
329 | Summary(pl_PL.UTF-8): Wtyczka snmp dla collectd | |
330 | Group: Daemons | |
331 | Requires: %{name} = %{version}-%{release} | |
332 | ||
333 | %description snmp | |
334 | snmp plugin for collectd. | |
335 | ||
336 | %package uuid | |
337 | Summary: uuid-plugin for collectd | |
338 | Summary(pl_PL.UTF-8): Wtyczka uuid dla collectd | |
339 | Group: Daemons | |
340 | Requires: %{name} = %{version}-%{release} | |
341 | ||
342 | %description uuid | |
343 | This plugin collectd UUID data. | |
344 | ||
345 | %package xmms | |
346 | Summary: xmms-plugin for collectd | |
347 | Summary(pl_PL.UTF-8): Wtyczka xmms dla collectd | |
348 | Group: Daemons | |
349 | Requires: %{name} = %{version}-%{release} | |
350 | Requires: xmms-libs | |
351 | ||
352 | %description xmms | |
353 | This plugin collectd data provided by XMMS. | |
354 | ||
373d486f AF |
355 | %prep |
356 | %setup -q | |
357 | ||
526f2b1b | 358 | cat >> collection.conf <<'EOF' |
359 | datadir: "/var/lib/collectd/" | |
360 | libdir: "/usr/lib/collectd/" | |
361 | EOF | |
362 | ||
373d486f AF |
363 | %build |
364 | %{__libtoolize} | |
365 | %{__aclocal} | |
366 | %{__autoconf} | |
367 | %{__autoheader} | |
368 | %{__automake} | |
4b6e34c7 | 369 | |
373d486f AF |
370 | %configure \ |
371 | --with-libstatgrab=/usr \ | |
372 | --with-lm-sensors=/usr \ | |
4b6e34c7 | 373 | --with-libmysql=/usr \ |
34fc103e JB |
374 | --%{?with_ipmi:en}%{!?with_ipmi:dis}able-ipmi \ |
375 | --%{?with_multimeter:en}%{!?with_multimeter:dis}able-multimeter \ | |
376 | --%{?with_dns:en}%{!?with_dns:dis}able-dns \ | |
377 | --%{?with_iptables:en}%{!?with_iptables:dis}able-iptables \ | |
95c10a4d PG |
378 | --%{?with_netlink:en}%{!?with_netlink:dis}able-netlink \ |
379 | --disable-ipvs | |
4b6e34c7 | 380 | |
381 | ||
87ba198e | 382 | %{__make} LDFLAGS="%{rpmldflags} -lstatgrab" \ |
383 | BUILD_WITH_OPENIPMI_CFLAGS="-I/usr/include" \ | |
384 | BUILD_WITH_OPENIPMI_LIBS="-L/usr/lib64 -lOpenIPMIutils -lOpenIPMIpthread" | |
373d486f AF |
385 | |
386 | %install | |
387 | rm -rf $RPM_BUILD_ROOT | |
711f12a6 | 388 | install -d $RPM_BUILD_ROOT{%{_var}/{log/,lib/%{name}},/etc/{rc.d/init.d/,collectd.d}} \ |
96376a8d | 389 | $RPM_BUILD_ROOT{%{_appdir}/cgi-bin,%{_webappdir},%{_pkglibdir}} |
373d486f AF |
390 | |
391 | %{__make} install \ | |
392 | DESTDIR=$RPM_BUILD_ROOT | |
81857fc6 | 393 | |
e105712e | 394 | touch $RPM_BUILD_ROOT%{_var}/log/collectd.log |
ff0d0ea0 | 395 | install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name} |
373d486f | 396 | |
96376a8d PG |
397 | # Web frontend: |
398 | install contrib/collection.conf $RPM_BUILD_ROOT%{_webappdir} | |
399 | install contrib/collection.cgi $RPM_BUILD_ROOT%{_appdir}/cgi-bin | |
400 | install %{SOURCE3} $RPM_BUILD_ROOT%{_webappdir}/apache.conf | |
401 | install %{SOURCE3} $RPM_BUILD_ROOT%{_webappdir}/httpd.conf | |
402 | ||
711f12a6 PG |
403 | ### Configs instalation ### |
404 | # Example config in sources: src/collectd.conf | |
405 | install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.conf | |
406 | install %{SOURCE10} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/ascent.conf | |
407 | install %{SOURCE11} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/apache.conf | |
408 | install %{SOURCE12} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/dns.conf | |
409 | install %{SOURCE13} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/hddtemp.conf | |
410 | install %{SOURCE14} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/ipmi.conf | |
411 | install %{SOURCE15} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/mysql.conf | |
412 | install %{SOURCE16} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/nginx.conf | |
413 | install %{SOURCE17} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/notify_desktop.conf | |
414 | install %{SOURCE18} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/notify_email.conf | |
415 | install %{SOURCE19} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/nut.conf | |
416 | install %{SOURCE20} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/ping.conf | |
417 | install %{SOURCE21} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/postgresql.conf | |
418 | install %{SOURCE22} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/powerdns.conf | |
419 | install %{SOURCE23} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/rrdtool.conf | |
420 | install %{SOURCE24} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/sensors.conf | |
421 | install %{SOURCE25} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/snmp.conf | |
422 | install %{SOURCE26} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/uuid.conf | |
423 | install %{SOURCE27} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/xmms.conf | |
25bc0190 PG |
424 | install %{SOURCE28} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/tcpconns.conf |
425 | install %{SOURCE29} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/teamspeak2.conf | |
426 | install %{SOURCE30} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/thermal.conf | |
427 | install %{SOURCE31} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/unixsock.conf | |
428 | install %{SOURCE32} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/users.conf | |
429 | install %{SOURCE33} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/vmem.conf | |
430 | install %{SOURCE34} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/vserver.conf | |
431 | install %{SOURCE35} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/wireless.conf | |
711f12a6 | 432 | |
96376a8d PG |
433 | # Cleanups: |
434 | rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/*.la | |
435 | ||
373d486f AF |
436 | %clean |
437 | rm -rf $RPM_BUILD_ROOT | |
438 | ||
81857fc6 | 439 | %post |
373d486f AF |
440 | /sbin/chkconfig --add %{name} |
441 | %service %{name} restart | |
442 | ||
81857fc6 | 443 | %preun |
373d486f AF |
444 | if [ "$1" = "0" ]; then |
445 | %service -q %{name} stop | |
446 | /sbin/chkconfig --del %{name} | |
447 | fi | |
448 | ||
96376a8d PG |
449 | %triggerin collection -- apache1 < 1.3.37-3, apache1-base |
450 | %webapp_register apache %{_webapp} | |
451 | ||
452 | %triggerun collection -- apache1 < 1.3.37-3, apache1-base | |
453 | %webapp_unregister apache %{_webapp} | |
454 | ||
455 | %triggerin collection -- apache < 2.2.0, apache-base | |
456 | %webapp_register httpd %{_webapp} | |
457 | ||
458 | %triggerun collection -- apache < 2.2.0, apache-base | |
459 | %webapp_unregister httpd %{_webapp} | |
460 | ||
373d486f AF |
461 | %files |
462 | %defattr(644,root,root,755) | |
e105712e | 463 | %doc AUTHORS ChangeLog README TODO contrib |
25bc0190 PG |
464 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.conf |
465 | %dir %{_sysconfdir}/%{name}.d | |
466 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/tcpconns.conf | |
467 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/teamspeak2.conf | |
468 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/thermal.conf | |
469 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/unixsock.conf | |
470 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/users.conf | |
471 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/vmem.conf | |
472 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/vserver.conf | |
473 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/wireless.conf | |
373d486f | 474 | %attr(755,root,root) %{_sbindir}/collectd |
e105712e | 475 | %attr(755,root,root) %{_sbindir}/collectdmon |
18e77dbc | 476 | %attr(755,root,root) %{_bindir}/collectd-nagios |
25bc0190 | 477 | |
373d486f | 478 | %dir %{_libdir}/%{name} |
c1bbd93e | 479 | %attr(755,root,root) %{_libdir}/%{name}/apcups.so |
18e77dbc | 480 | #%attr(755,root,root) %{_libdir}/%{name}/apple_sensors.so |
373d486f | 481 | %attr(755,root,root) %{_libdir}/%{name}/battery.so |
373d486f | 482 | %attr(755,root,root) %{_libdir}/%{name}/cpufreq.so |
c1bbd93e | 483 | %attr(755,root,root) %{_libdir}/%{name}/cpu.so |
18e77dbc | 484 | %attr(755,root,root) %{_libdir}/%{name}/csv.so |
373d486f AF |
485 | %attr(755,root,root) %{_libdir}/%{name}/df.so |
486 | %attr(755,root,root) %{_libdir}/%{name}/disk.so | |
762d0c28 | 487 | %attr(755,root,root) %{_libdir}/%{name}/email.so |
18e77dbc | 488 | %attr(755,root,root) %{_libdir}/%{name}/entropy.so |
489 | %attr(755,root,root) %{_libdir}/%{name}/exec.so | |
0b998ec1 | 490 | %attr(755,root,root) %{_libdir}/%{name}/filecount.so |
18e77dbc | 491 | %attr(755,root,root) %{_libdir}/%{name}/interface.so |
4b6e34c7 | 492 | %if %{with iptables} |
e105712e | 493 | %attr(755,root,root) %{_libdir}/%{name}/iptables.so |
4b6e34c7 | 494 | %endif |
95c10a4d PG |
495 | # Disabled - requires fixed libc-headers or whole kernel source. |
496 | # It was marked as disabled in status message on top. | |
497 | #%attr(755,root,root) %{_libdir}/%{name}/ipvs.so | |
18e77dbc | 498 | %attr(755,root,root) %{_libdir}/%{name}/irq.so |
373d486f | 499 | %attr(755,root,root) %{_libdir}/%{name}/load.so |
18e77dbc | 500 | %attr(755,root,root) %{_libdir}/%{name}/logfile.so |
762d0c28 | 501 | %attr(755,root,root) %{_libdir}/%{name}/mbmon.so |
e6f53b24 | 502 | %attr(755,root,root) %{_libdir}/%{name}/memcached.so |
373d486f | 503 | %attr(755,root,root) %{_libdir}/%{name}/memory.so |
87ba198e | 504 | %if %{with multimeter} |
762d0c28 | 505 | %attr(755,root,root) %{_libdir}/%{name}/multimeter.so |
87ba198e | 506 | %endif |
4b6e34c7 | 507 | %if %{with netlink} |
e105712e | 508 | %attr(755,root,root) %{_libdir}/%{name}/netlink.so |
4b6e34c7 | 509 | %endif |
18e77dbc | 510 | %attr(755,root,root) %{_libdir}/%{name}/network.so |
373d486f | 511 | %attr(755,root,root) %{_libdir}/%{name}/nfs.so |
c1bbd93e | 512 | %attr(755,root,root) %{_libdir}/%{name}/ntpd.so |
e6f53b24 | 513 | #%attr(755,root,root) %{_libdir}/%{name}/perl.so |
373d486f | 514 | %attr(755,root,root) %{_libdir}/%{name}/processes.so |
373d486f AF |
515 | %attr(755,root,root) %{_libdir}/%{name}/serial.so |
516 | %attr(755,root,root) %{_libdir}/%{name}/swap.so | |
e6f53b24 | 517 | %attr(755,root,root) %{_libdir}/%{name}/syslog.so |
e105712e | 518 | %attr(755,root,root) %{_libdir}/%{name}/tail.so |
18e77dbc | 519 | #%attr(755,root,root) %{_libdir}/%{name}/tape.so |
e6f53b24 | 520 | %attr(755,root,root) %{_libdir}/%{name}/tcpconns.so |
25bc0190 | 521 | %attr(755,root,root) %{_libdir}/%{name}/teamspeak2.so |
0b998ec1 | 522 | %attr(755,root,root) %{_libdir}/%{name}/thermal.so |
18e77dbc | 523 | #%attr(755,root,root) %{_libdir}/%{name}/traffic.so |
18e77dbc | 524 | %attr(755,root,root) %{_libdir}/%{name}/unixsock.so |
e6f53b24 | 525 | %attr(755,root,root) %{_libdir}/%{name}/users.so |
e105712e | 526 | %attr(755,root,root) %{_libdir}/%{name}/vmem.so |
c1bbd93e | 527 | %attr(755,root,root) %{_libdir}/%{name}/vserver.so |
f6984413 | 528 | %attr(755,root,root) %{_libdir}/%{name}/wireless.so |
e6f53b24 | 529 | %{_libdir}/%{name}/types.db |
373d486f | 530 | |
ff0d0ea0 | 531 | %attr(754,root,root) /etc/rc.d/init.d/%{name} |
373d486f AF |
532 | |
533 | %{_mandir}/man1/collectd.1* | |
18e77dbc | 534 | %{_mandir}/man1/collectd-nagios.1* |
373d486f | 535 | %{_mandir}/man5/collectd.conf.5* |
18e77dbc | 536 | %{_mandir}/man5/collectd-email.5* |
537 | %{_mandir}/man5/collectd-exec.5* | |
538 | %{_mandir}/man5/collectd-perl.5* | |
539 | %{_mandir}/man5/collectd-snmp.5* | |
540 | %{_mandir}/man5/collectd-unixsock.5* | |
e105712e | 541 | %{_mandir}/man1/collectdmon.1* |
542 | %{_mandir}/man5/types.db.5* | |
543 | %{_var}/log/collectd.log | |
544 | %dir %{_var}/lib/%{name} | |
545 | ||
8bf13ddb PG |
546 | ########## PLUGINS: |
547 | %files ascent | |
548 | %defattr(644,root,root,755) | |
711f12a6 | 549 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/ascent.conf |
8bf13ddb | 550 | %attr(755,root,root) %{_libdir}/%{name}/ascent.so |
18e77dbc | 551 | |
552 | %files apache | |
553 | %defattr(644,root,root,755) | |
711f12a6 | 554 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/apache.conf |
18e77dbc | 555 | %attr(755,root,root) %{_libdir}/%{name}/apache.so |
556 | ||
133ab397 | 557 | %files collection |
5fafedfc | 558 | %defattr(644,root,root,755) |
c8f99641 | 559 | %dir %{_webappdir} |
96376a8d | 560 | %config(noreplace) %verify(not md5 mtime size) %{_webappdir}/collection.conf |
4b6e34c7 | 561 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_webappdir}/apache.conf |
562 | %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_webappdir}/httpd.conf | |
b4b27e4a | 563 | %dir %{_appdir} |
c8f99641 | 564 | %dir %{_appdir}/cgi-bin |
96376a8d | 565 | %attr(755,root,root) %{_appdir}/cgi-bin/collection.cgi |
5fafedfc | 566 | |
8bf13ddb PG |
567 | %files dns |
568 | %defattr(644,root,root,755) | |
711f12a6 | 569 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/dns.conf |
8bf13ddb PG |
570 | %attr(755,root,root) %{_libdir}/%{name}/dns.so |
571 | ||
572 | %files hddtemp | |
573 | %defattr(644,root,root,755) | |
711f12a6 | 574 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/hddtemp.conf |
8bf13ddb PG |
575 | %attr(755,root,root) %{_libdir}/%{name}/hddtemp.so |
576 | ||
87ba198e | 577 | %if %{with ipmi} |
578 | %files ipmi | |
579 | %defattr(644,root,root,755) | |
711f12a6 | 580 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/ipmi.conf |
87ba198e | 581 | %attr(755,root,root) %{_libdir}/%{name}/ipmi.so |
582 | %endif | |
583 | ||
18e77dbc | 584 | %files mysql |
585 | %defattr(644,root,root,755) | |
711f12a6 | 586 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/mysql.conf |
18e77dbc | 587 | %attr(755,root,root) %{_libdir}/%{name}/mysql.so |
8bf13ddb PG |
588 | |
589 | %files nginx | |
590 | %defattr(644,root,root,755) | |
711f12a6 | 591 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/nginx.conf |
8bf13ddb PG |
592 | %attr(755,root,root) %{_libdir}/%{name}/nginx.so |
593 | ||
7be39ce7 | 594 | %files notify_desktop |
595 | %defattr(644,root,root,755) | |
711f12a6 | 596 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/notify_desktop.conf |
7be39ce7 | 597 | %attr(755,root,root) %{_libdir}/%{name}/notify_desktop.so |
598 | ||
b4b27e4a PG |
599 | %files notify_email |
600 | %defattr(644,root,root,755) | |
711f12a6 | 601 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/notify_email.conf |
b4b27e4a PG |
602 | %attr(755,root,root) %{_libdir}/%{name}/notify_email.so |
603 | ||
604 | %files nut | |
605 | %defattr(644,root,root,755) | |
711f12a6 | 606 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/nut.conf |
b4b27e4a PG |
607 | %attr(755,root,root) %{_libdir}/%{name}/nut.so |
608 | ||
907cfb56 PG |
609 | %files ping |
610 | %defattr(644,root,root,755) | |
711f12a6 | 611 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/ping.conf |
907cfb56 PG |
612 | %attr(755,root,root) %{_libdir}/%{name}/ping.so |
613 | ||
b4b27e4a PG |
614 | %files postgresql |
615 | %defattr(644,root,root,755) | |
711f12a6 | 616 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/postgresql.conf |
b4b27e4a PG |
617 | %attr(755,root,root) %{_libdir}/%{name}/postgresql.so |
618 | ||
4b6e34c7 | 619 | %files powerdns |
620 | %defattr(644,root,root,755) | |
711f12a6 | 621 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/powerdns.conf |
4b6e34c7 | 622 | %attr(755,root,root) %{_libdir}/%{name}/powerdns.so |
623 | ||
8bf13ddb PG |
624 | %files rrdtool |
625 | %defattr(644,root,root,755) | |
711f12a6 | 626 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/rrdtool.conf |
8bf13ddb PG |
627 | %attr(755,root,root) %{_libdir}/%{name}/rrdtool.so |
628 | ||
629 | %files sensors | |
630 | %defattr(644,root,root,755) | |
711f12a6 | 631 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/sensors.conf |
8bf13ddb PG |
632 | %attr(755,root,root) %{_libdir}/%{name}/sensors.so |
633 | ||
634 | %files snmp | |
635 | %defattr(644,root,root,755) | |
711f12a6 | 636 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/snmp.conf |
8bf13ddb PG |
637 | %attr(755,root,root) %{_libdir}/%{name}/snmp.so |
638 | ||
639 | %files uuid | |
640 | %defattr(644,root,root,755) | |
711f12a6 | 641 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/uuid.conf |
8bf13ddb PG |
642 | %attr(755,root,root) %{_libdir}/%{name}/uuid.so |
643 | ||
644 | %files xmms | |
645 | %defattr(644,root,root,755) | |
711f12a6 | 646 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/xmms.conf |
8bf13ddb | 647 | %attr(755,root,root) %{_libdir}/%{name}/xmms.so |