2 # - package contrib scripts as %doc
3 # - perl modules with Collectd classes package to separate package
5 # apple_sensors . . . no (obvious)
6 # ipvs . . . . . . . no (ip_vs.h not found - llh to be fixed)
7 # libvirt . . . . . . no (requires library)
8 # multimeter . . . . no ?
9 # onewire . . . . . . no (needs libowfs)
10 # perl . . . . . . . no (needs libperl)
11 # tape . . . . . . . no ?
14 %bcond_without dns # ???
15 %bcond_without ipmi # ipmi plugin package
16 %bcond_without iptables # iptables plugin
17 %bcond_with multimeter # multimeter plugin
18 %bcond_without netlink # netlink plugin
20 #http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=358637
22 %undefine with_iptables
23 %undefine with_netlink
25 Summary: Collects system information in RRD files
26 Summary(pl.UTF-8): Zbieranie informacji o systemie w plikach RRD
32 Source0: http://collectd.org/files/%{name}-%{version}.tar.gz
33 # Source0-md5: ab900d15662859b8793abf99eda15c29
36 Source3: %{name}-http.conf
37 Source10: %{name}-ascent.conf
38 Source11: %{name}-apache.conf
39 Source12: %{name}-dns.conf
40 Source13: %{name}-hddtemp.conf
41 Source14: %{name}-ipmi.conf
42 Source15: %{name}-mysql.conf
43 Source16: %{name}-nginx.conf
44 Source17: %{name}-notify_desktop.conf
45 Source18: %{name}-notify_email.conf
46 Source19: %{name}-nut.conf
47 Source20: %{name}-ping.conf
48 Source21: %{name}-postgresql.conf
49 Source22: %{name}-powerdns.conf
50 Source23: %{name}-rrdtool.conf
51 Source24: %{name}-sensors.conf
52 Source25: %{name}-snmp.conf
53 Source26: %{name}-uuid.conf
54 Source27: %{name}-xmms.conf
55 Source28: %{name}-tcpconns.conf
56 Source29: %{name}-teamspeak2.conf
57 Source30: %{name}-thermal.conf
58 Source31: %{name}-unixsock.conf
59 Source32: %{name}-users.conf
60 Source33: %{name}-vmem.conf
61 Source34: %{name}-vserver.conf
62 Source35: %{name}-wireless.conf
63 Source36: %{name}-apcups.conf
64 Source37: %{name}-battery.conf
65 Source38: %{name}-cpufreq.conf
66 Source39: %{name}-cpu.conf
67 Source40: %{name}-csv.conf
68 Source41: %{name}-df.conf
69 Source42: %{name}-disk.conf
70 Source43: %{name}-email.conf
71 Source44: %{name}-entropy.conf
72 Source45: %{name}-exec.conf
73 Source46: %{name}-filecount.conf
74 Source47: %{name}-interface.conf
75 Source48: %{name}-iptables.conf
76 Source49: %{name}-irq.conf
77 Source51: %{name}-load.conf
78 Source52: %{name}-logfile.conf
79 Source53: %{name}-mbmon.conf
80 Source54: %{name}-memcached.conf
81 Source55: %{name}-memory.conf
82 Source56: %{name}-multimeter.conf
83 Source57: %{name}-netlink.conf
84 Source58: %{name}-network.conf
85 Source59: %{name}-nfs.conf
86 Source60: %{name}-ntpd.conf
87 Source61: %{name}-processes.conf
88 Source62: %{name}-serial.conf
89 Source63: %{name}-swap.conf
90 Source64: %{name}-syslog.conf
91 Source65: %{name}-tail.conf
92 URL: http://collectd.org/
93 %{?with_ipmi:BuildRequires: OpenIPMI-devel >= 2.0.14-3}
94 BuildRequires: autoconf
95 BuildRequires: automake
96 BuildRequires: curl-devel
97 %{?with_iptables:BuildRequires: iptables-devel >= 1.4.1.1-4}
98 BuildRequires: libesmtp-devel
99 BuildRequires: libnetlink-devel
100 BuildRequires: libnotify-devel
101 BuildRequires: liboping-devel
102 BuildRequires: libpcap-devel
103 BuildRequires: libstatgrab-devel >= 0.12
104 BuildRequires: libtool
105 BuildRequires: lm_sensors-devel
106 BuildRequires: mysql-devel
107 BuildRequires: nut-devel
108 BuildRequires: perl-devel
109 BuildRequires: rpmbuild(macros) >= 1.268
110 BuildRequires: rrdtool-devel
111 BuildRequires: net-snmp-devel
112 BuildRequires: xmms-devel
113 Requires(post,preun): /sbin/chkconfig
115 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
117 %define _pkglibdir /var/lib/%{name}
118 %define _webapps /etc/webapps
119 %define _webapp %{name}
120 %define _webappdir %{_webapps}/%{_webapp}
121 %define _appdir %{_datadir}/%{_webapp}
124 collectd is a small daemon which collects system information every 10
125 seconds and writes the results in an RRD-file.
127 In contrast to most similar software, collectd is not a script but
128 written in plain C for performance and portability. As a daemon it
129 stays in memory, so there is no need to start up a heavy interpreter
130 every time new values should be logged. This allows collectd to have a
131 10 second resolution while being nice to the system.
133 %description -l pl.UTF-8
134 collectd to mały demon zbierający co 10 sekund informacje o systemie i
135 zapisujący wyniki do pliku RRD.
137 W odróżnieniu od innych podobnych programów collectd nie jest
138 skryptem, lecz jest napisany w czystym C z myślą o wydajności i
139 przenośności. Jako demon pozostaje w pamięci, więc nie ma potrzeby
140 urychamiania ciężkiego interpretera za każdym razem, kiedy powinny być
141 zapisane nowe wartości. Dzięki temu collect może mieć rozdzielczość 10
142 sekund i nie obciążać zbytnio systemu.
145 Summary: apache-plugin for collectd
146 Summary(pl_PL.UTF-8): Wtyczka apache dla collectd
148 Requires: %{name} = %{version}-%{release}
151 This plugin collectd data provided by Apache's `mod_status'.
153 %description apache -l pl.UTF-8
154 Wtyczka collectd zbierająca informacje udostępniane przez moduł
158 Summary: APC UPS plugin for collectd
159 Summary(pl_PL.UTF-8): Wtyczka APC UPS dla collectd
161 Requires: %{name} = %{version}-%{release}
164 APC UPS plugin for collectd.
167 Summary: ascent-plugin for collectd
168 Summary(pl_PL.UTF-8): Wtyczka ascent dla collectd
170 Requires: %{name} = %{version}-%{release}
173 ascent plugin for collectd.
176 Summary: battery plugin for collectd
177 Summary(pl_PL.UTF-8): Wtyczka battery dla collectd
179 Requires: %{name} = %{version}-%{release}
182 This plugin collects the battery's charge, the drawn current and the
186 Summary: Web script for collectiond
187 Summary(pl_PL.UTF-8): Web script for collectiond
188 Group: Applications/WWW
189 Requires: %{name} = %{version}-%{release}
191 %description collection
192 Web script for collectiond
195 Summary: cpu-plugin for collectd
196 Summary(pl_PL.UTF-8): Wtyczka cpu dla collectd
198 Requires: %{name} = %{version}-%{release}
201 The cpu-plugin collects the amount of time spent by the CPU in various states,
202 most notably executing user code, executing system code, waiting for IO
203 operations and being idle.
206 Summary: cpufreq-plugin for collectd
207 Summary(pl_PL.UTF-8): Wtyczka cpufreq dla collectd
209 Requires: %{name} = %{version}-%{release}
212 Collects the current CPU's frequency, mostly for mobile computers.
215 Summary: CSV output plugin for collectd
216 Summary(pl_PL.UTF-8): Wtyczka wyjściowa CSV dla collectd
218 Requires: %{name} = %{version}-%{release}
221 CSV output plugin for collectd.
224 Summary: df-plugin for collectd
225 Summary(pl_PL.UTF-8): Wtyczka df dla collectd
227 Requires: %{name} = %{version}-%{release}
230 The df-plugin collects file system usage information, i. e. basically how
231 much space on a mounted partition is used and how much is available. It's
232 named after and very similar to the df(1) UNIX command that's been around
236 Summary: disk-plugin for collectd
237 Summary(pl_PL.UTF-8): Wtyczka disk dla collectd
239 Requires: %{name} = %{version}-%{release}
242 This plugin collects performance statistics of harddisks and, where
243 supported, partitions.
246 Summary: dns-plugin for collectd
247 Summary(pl_PL.UTF-8): Wtyczka dns dla collectd
249 Requires: %{name} = %{version}-%{release}
250 Requires: perl-rrdtool
253 This plugin has a similar functionality to dnstop: It uses libpcap to get
254 a copy of all traffic from/to port UDP/53 (that's the DNS port), interprets
255 the packets and collects statistics of your DNS traffic.
258 Summary: email-plugin for collectd
259 Summary(pl_PL.UTF-8): Wtyczka email dla collectd
261 Requires: %{name} = %{version}-%{release}
264 The email plugin opens an UNIX-socket over which one can submit email
265 statistics, such as the number of ``ham'', ``spam'', ``virus'', etc. mails
266 received/handled, spam scores and matched spam checks.
268 This plugin is intended to be used with the the
269 Mail::SpamAssassin::Plugin::Collectd manpage SpamAssassin-plugin which is
270 included in contrib/, but is of course not limited to that use.
273 Summary: entropy-plugin for collectd
274 Summary(pl_PL.UTF-8): Wtyczka entropy dla collectd
276 Requires: %{name} = %{version}-%{release}
279 entropy plugin for collectd.
282 Summary: exec-plugin for collectd
283 Summary(pl_PL.UTF-8): Wtyczka exec dla collectd
285 Requires: %{name} = %{version}-%{release}
288 The exec plugin forks of an executable either to receive values or to
289 dispatch notifications to the outside world.
292 Summary: filecount-plugin for collectd
293 Summary(pl_PL.UTF-8): Wtyczka filecount dla collectd
295 Requires: %{name} = %{version}-%{release}
297 %description filecount
298 The filecount-plugin does something very simple: Count the number of files
299 in a directory and all its subdirectories. This can be used for a variety of
300 statistics, for example the queue length of an MTA, the number of PHP
301 sessions of a web server or simply the number of files in your home
305 Summary: hddtemp-plugin for collectd
306 Summary(pl_PL.UTF-8): Wtyczka hddtemp dla collectd
308 Requires: %{name} = %{version}-%{release}
311 Temperature of harddisks. The temperatures are provided via S.M.A.R.T. and
312 queried by the external hddtemp-daemon.
315 Summary: interface-plugin for collectd
316 Summary(pl_PL.UTF-8): Wtyczka interface dla collectd
318 Requires: %{name} = %{version}-%{release}
320 %description interface
321 The interface-plugin collects information about the traffic (octets), packets
322 and errors of interfaces.
325 Summary: iptables-plugin for collectd
326 Summary(pl_PL.UTF-8): Wtyczka iptables dla collectd
328 Requires: %{name} = %{version}-%{release}
330 %description iptables
331 With this plugin you can gather statistics from your ip_tables based
332 packetfilter (aka. firewall). It can collect the byte- and packet-counters
333 of selected rules and submit them to collectd. You can select rules that
334 should be collected wither by its position (e.g. "the fourth rule in the
335 INPUT queue in the filter table") or by its comment (using the COMMENT
336 match). This means that depending on your firewall layout you can collect
337 certain services (such as the amount of web-traffic), source or destination
338 hosts or networks, dropped packets and much more.
341 Summary: ipmi-plugin for collectd
342 Summary(pl_PL.UTF-8): Wtyczka ipmi dla collectd
344 Requires: %{name} = %{version}-%{release}
347 ipmi plugin for collectd.
349 %description ipmi -l pl.UTF-8
350 Wtyczka ipmi dla collectd.
353 Summary: IRQs-plugin for collectd
354 Summary(pl_PL.UTF-8): Wtyczka IRQs dla collectd
356 Requires: %{name} = %{version}-%{release}
359 IRQs plugin for collectd.
362 Summary: load-plugin for collectd
363 Summary(pl_PL.UTF-8): Wtyczka load dla collectd
365 Requires: %{name} = %{version}-%{release}
368 Collects the system load. These numbers give a rough overview over the
369 utilization of a machine, though their meaning is mostly overrated.
372 Summary: logfile-plugin for collectd
373 Summary(pl_PL.UTF-8): Wtyczka logfile dla collectd
375 Requires: %{name} = %{version}-%{release}
378 Logfile plugin for collectd.
380 %module_scripts mbmon
382 Summary: mbmon-plugin for collectd
383 Summary(pl_PL.UTF-8): Wtyczka mbmon dla collectd
385 Requires: %{name} = %{version}-%{release}
388 The mbmon plugin uses mbmon to retrieve temperature, voltage, etc.
391 Summary: memcached-plugin for collectd
392 Summary(pl_PL.UTF-8): Wtyczka memcached dla collectd
394 Requires: %{name} = %{version}-%{release}
396 %description memcached
397 The memcached plugin connects to a memcached daemon and collects the number
398 of connections and requests handled by the daemon, the CPU resources consumed,
399 number of items cached, number of threads, and bytes sent and received.
402 Summary: memory-plugin for collectd
403 Summary(pl_PL.UTF-8): Wtyczka memory dla collectd
405 Requires: %{name} = %{version}-%{release}
408 Collects physical memory utilization for collectd.
411 Summary: multimeter-plugin for collectd
412 Summary(pl_PL.UTF-8): Wtyczka multimeter dla collectd
414 Requires: %{name} = %{version}-%{release}
416 %description multimeter
417 Multimeter plugin for collectd.
420 Summary: mysql-plugin for collectd
421 Summary(pl_PL.UTF-8): Moduł mysql dla collectd.
423 Requires: %{name} = %{version}-%{release}
426 MySQL querying plugin. This plugins provides data of issued commands,
427 called handlers and database traffic.
429 %description mysql -l pl.UTF-8
430 Moduł odpytujący MySQL. Wtyczka udostępnia dane o wydawanych
431 poleceniach, wywoływanych procedurach obsługi i ruchu bazodanowym.
434 Summary: netlink-plugin for collectd
435 Summary(pl_PL.UTF-8): Wtyczka netlink dla collectd
437 Requires: %{name} = %{version}-%{release}
440 This plugin will open a netlink socket to the Linux kernel and use it to get
441 statistics for interfaces, qdiscs, classes, and, if you can make use of it,
442 filters. Since in most setups many of the statistics this plugin can collect
443 aren't of interest, you can select which information to gather using the
447 Summary: network-plugin for collectd
448 Summary(pl_PL.UTF-8): Wtyczka network dla collectd
450 Requires: %{name} = %{version}-%{release}
453 nginx plugin for collectd.
456 Summary: NFS-plugin for collectd
457 Summary(pl_PL.UTF-8): Wtyczka NFS dla collectd
459 Requires: %{name} = %{version}-%{release}
462 The nfs plugin counts the number of procedure calls of the different NFS
466 Summary: nginx-plugin for collectd
467 Summary(pl_PL.UTF-8): Wtyczka nginx dla collectd
469 Requires: %{name} = %{version}-%{release}
472 This plugin collects the number of connections and requests handled by the
473 nginx daemon, a HTTP and mail server/proxy. It queries the page provided by
474 the ngx_http_stub_status_module module, which isn't compiled by default.
476 %package notify_desktop
477 Summary: notify_desktop for collectd
478 Summary(pl_PL.UTF-8): Wtyczka notify_desktop dla collectd
480 Requires: %{name} = %{version}-%{release}
482 %description notify_desktop
483 This plugin sends a desktop notification to a notification daemon, as
484 defined in the Desktop Notification Specification. To actually display the
485 notifications, notification-daemon is required and collectd has to be able
486 to access the X server.
488 %package notify_email
489 Summary: notify_email-plugin for collectd
490 Summary(pl_PL.UTF-8): Wtyczka notify_email dla collectd
492 Requires: %{name} = %{version}-%{release}
494 %description notify_email
495 notify_email plugin for collectd.
498 Summary: ntpd-plugin for collectd
499 Summary(pl_PL.UTF-8): Wtyczka ntpd dla collectd
501 Requires: %{name} = %{version}-%{release}
504 NTPd plugin for collectd.
507 Summary: nut-plugin for collectd
508 Summary(pl_PL.UTF-8): Wtyczka nut dla collectd
510 Requires: %{name} = %{version}-%{release}
513 UPS statistics using the Network UPS Tools. These statistics include
514 basically everything NUT will give us, including voltages, currents, power,
515 frequencies, load, and temperatures.
518 Summary: ping-plugin for collectd
519 Summary(pl_PL.UTF-8): Wtyczka ping dla collectd
521 Requires: %{name} = %{version}-%{release}
524 The network latency is measured as a roundtrip time. An ICMP-echo-request
525 (aka. "ping")is sent to a host and the time needed for his echo-reply (aka.
526 "pong") to arrive is measured. If a reply is not received within one second
527 the plugin will no longer expect a reply and return. This may happen in
528 several circumstances, e. g. the packet is lost, the host is down, a router
529 has dismissed the packet, etc.
532 Summary: mysql-plugin for collectd
533 Summary(pl_PL.UTF-8): Moduł postgresql dla collectd.
535 Requires: %{name} = %{version}-%{release}
537 %description postgresql
538 The postgresql plugin queries statistics from PostgreSQL databases. It keeps
539 a persistent connection to all configured databases and tries to reconnect
540 if the connection has been interrupted.
543 Summary: powerdns-plugin for collectd
544 Summary(pl_PL.UTF-8): Wtyczka powerdns dla collectd
546 Requires: %{name} = %{version}-%{release}
548 %description powerdns
549 The powerdns plugin queries statistics from an authoritative PowerDNS
550 nameserver and/or a PowerDNS recursor. Since both offer a wide variety of
551 values, many of which are probably meaningless to most users, but may be
555 Summary: processes-plugin for collectd
556 Summary(pl_PL.UTF-8): Wtyczka processes dla collectd
558 Requires: %{name} = %{version}-%{release}
560 %description processes
561 This plugin collects the number of processes, grouped by their state (e.g.
562 running, sleeping, zombies, etc.). In addition to that, it can select
563 detailed statistics about selected processes, grouped by name.
566 Summary: rrdtool-plugin for collectd
567 Summary(pl_PL.UTF-8): Wtyczka rrdtool dla collectd
569 Requires: %{name} = %{version}-%{release}
573 RRDTOOL plugin for collectd.
576 Summary: sensors-plugin for collectd
577 Summary(pl_PL.UTF-8): Wtyczka sensors dla collectd
579 Requires: %{name} = %{version}-%{release}
582 This plugin uses lm-sensors to read hardware sensors. You will need to
583 configure lm-sensors before this plugin will collect any usefull and correct
586 %module_scripts serial
588 Summary: serial-plugin for collectd
589 Summary(pl_PL.UTF-8): Wtyczka serial dla collectd
591 Requires: %{name} = %{version}-%{release}
594 Serial plugin for collectd.
597 Summary: snmp-plugin for collectd
598 Summary(pl_PL.UTF-8): Wtyczka snmp dla collectd
600 Requires: %{name} = %{version}-%{release}
603 The snmp plugin queries other hosts using SNMP, the Simple Network
604 Management Protocol, and translates the value it receives to collectd's
605 internal format and dispatches them. Depending on the write plugins you have
606 loaded they may be written to disk or submitted to another instance or
607 whatever you configured.
610 Summary: swap-plugin for collectd
611 Summary(pl_PL.UTF-8): Wtyczka swap dla collectd
613 Requires: %{name} = %{version}-%{release}
616 Swap space plugin for collectd.
619 Summary: syslog-plugin for collectd
620 Summary(pl_PL.UTF-8): Wtyczka syslog dla collectd
622 Requires: %{name} = %{version}-%{release}
625 Syslog plugin for collectd.
628 Summary: tail-plugin for collectd
629 Summary(pl_PL.UTF-8): Wtyczka tail dla collectd
631 Requires: %{name} = %{version}-%{release}
634 The tail-plugin can be used to "tail" logfiles, i.e. follow them as tail -F
635 does. Each line is given to one or more "matches" which test if the line is
636 relevant for any statistics using a regular expression.
639 Summary: tcpconns-plugin for collectd
640 Summary(pl_PL.UTF-8): Wtyczka tcpconns dla collectd
642 Requires: %{name} = %{version}-%{release}
644 %description tcpconns
645 The tcpconns-plugin counts the number of TCP connections to or from a
646 specified port. Typically the connectioins where you specify the local port
647 are incoming connections while the connections where you specify the remote
648 port are outgoing connections.
651 Summary: teamspeak2-plugin for collectd
652 Summary(pl_PL.UTF-8): Wtyczka teamspeak2 dla collectd
654 Requires: %{name} = %{version}-%{release}
656 %description teamspeak2
657 The teamspeak2 plugin connects to the query port of a teamspeak2 server and
658 polls interesting global and virtual server data. The plugin can query only
659 one physical server but unlimited virtual servers.
662 Summary: thermal-plugin for collectd
663 Summary(pl_PL.UTF-8): Wtyczka thermal dla collectd
665 Requires: %{name} = %{version}-%{release}
668 Thermal plugin for collectd.
671 Summary: unixsock-plugin for collectd
672 Summary(pl_PL.UTF-8): Wtyczka unixsock dla collectd
674 Requires: %{name} = %{version}-%{release}
676 %description unixsock
677 The unixsock plugin opens an UNIX-socket over which one can interact with
678 the daemon. This can be used to use the values collected by collectd in
679 other applications, such as monitoring, or submit externally collected
683 Summary: users-plugin for collectd
684 Summary(pl_PL.UTF-8): Wtyczka users dla collectd
686 Requires: %{name} = %{version}-%{release}
689 Number of users currently logged in.
692 Summary: uuid-plugin for collectd
693 Summary(pl_PL.UTF-8): Wtyczka uuid dla collectd
695 Requires: %{name} = %{version}-%{release}
698 This plugin, if loaded, causes the Hostname to be taken from the machine's
699 UUID. The UUID is a universally unique designation for the machine, usually
700 taken from the machine's BIOS. This is most useful if the machine is
701 running in a virtual environment such as Xen, in which case the UUID is
702 preserved across shutdowns and migration.
705 Summary: vmem-plugin for collectd
706 Summary(pl_PL.UTF-8): Wtyczka vmem dla collectd
708 Requires: %{name} = %{version}-%{release}
711 The vmem plugin collects information about the usage of virtual memory.
712 Since the statistics provided by the Linux kernel are very detailed, they
713 are collected very detailed.
716 Summary: vserver-plugin for collectd
717 Summary(pl_PL.UTF-8): Wtyczka vserver dla collectd
719 Requires: %{name} = %{version}-%{release}
722 Collects information about the virtual servers running on a system, using
726 Summary: wireless-plugin for collectd
727 Summary(pl_PL.UTF-8): Wtyczka wireless dla collectd
729 Requires: %{name} = %{version}-%{release}
731 %description wireless
732 Wireless plugin for collectd.
735 Summary: xmms-plugin for collectd
736 Summary(pl_PL.UTF-8): Wtyczka xmms dla collectd
738 Requires: %{name} = %{version}-%{release}
741 This plugin collectd data provided by XMMS.
746 cat >> collection.conf <<'EOF'
747 datadir: "/var/lib/collectd/"
748 libdir: "/usr/lib/collectd/"
759 --with-libstatgrab=/usr \
760 --with-lm-sensors=/usr \
761 --with-libmysql=/usr \
762 --%{?with_ipmi:en}%{!?with_ipmi:dis}able-ipmi \
763 --%{?with_multimeter:en}%{!?with_multimeter:dis}able-multimeter \
764 --%{?with_dns:en}%{!?with_dns:dis}able-dns \
765 --%{?with_iptables:en}%{!?with_iptables:dis}able-iptables \
766 --%{?with_netlink:en}%{!?with_netlink:dis}able-netlink \
772 %{__make} LDFLAGS="%{rpmldflags} -lstatgrab" \
773 BUILD_WITH_OPENIPMI_CFLAGS="-I/usr/include" \
774 BUILD_WITH_OPENIPMI_LIBS="-L/usr/lib64 -lOpenIPMIutils -lOpenIPMIpthread"
777 rm -rf $RPM_BUILD_ROOT
778 install -d $RPM_BUILD_ROOT{%{_var}/{log/,lib/%{name}},/etc/{rc.d/init.d/,collectd.d}} \
779 $RPM_BUILD_ROOT{%{_appdir}/cgi-bin,%{_webappdir},%{_pkglibdir}}
782 DESTDIR=$RPM_BUILD_ROOT
784 touch $RPM_BUILD_ROOT%{_var}/log/collectd.log
785 install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
788 install contrib/collection.conf $RPM_BUILD_ROOT%{_webappdir}
789 install contrib/collection.cgi $RPM_BUILD_ROOT%{_appdir}/cgi-bin
790 install %{SOURCE3} $RPM_BUILD_ROOT%{_webappdir}/apache.conf
791 install %{SOURCE3} $RPM_BUILD_ROOT%{_webappdir}/httpd.conf
793 ### Configs instalation ###
794 # Example config in sources: src/collectd.conf
795 install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.conf
796 install %{SOURCE10} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/ascent.conf
797 install %{SOURCE11} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/apache.conf
798 %{?with_dns:install %{SOURCE12} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/dns.conf}
799 install %{SOURCE13} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/hddtemp.conf
800 %{?with_ipmi:install %{SOURCE14} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/ipmi.conf}
801 install %{SOURCE15} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/mysql.conf
802 install %{SOURCE16} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/nginx.conf
803 install %{SOURCE17} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/notify_desktop.conf
804 install %{SOURCE18} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/notify_email.conf
805 install %{SOURCE19} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/nut.conf
806 install %{SOURCE20} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/ping.conf
807 install %{SOURCE21} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/postgresql.conf
808 install %{SOURCE22} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/powerdns.conf
809 install %{SOURCE23} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/rrdtool.conf
810 install %{SOURCE24} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/sensors.conf
811 install %{SOURCE25} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/snmp.conf
812 install %{SOURCE26} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/uuid.conf
813 install %{SOURCE27} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/xmms.conf
814 install %{SOURCE28} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/tcpconns.conf
815 install %{SOURCE29} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/teamspeak2.conf
816 install %{SOURCE30} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/thermal.conf
817 install %{SOURCE31} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/unixsock.conf
818 install %{SOURCE32} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/users.conf
819 install %{SOURCE33} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/vmem.conf
820 install %{SOURCE34} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/vserver.conf
821 install %{SOURCE35} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/wireless.conf
822 install %{SOURCE36} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/apcups.conf
823 install %{SOURCE37} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/battery.conf
824 install %{SOURCE38} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/cpufreq.conf
825 install %{SOURCE39} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/cpu.conf
826 install %{SOURCE40} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/csv.conf
827 install %{SOURCE41} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/df.conf
828 install %{SOURCE42} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/disk.conf
829 install %{SOURCE43} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/email.conf
830 install %{SOURCE44} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/entropy.conf
831 install %{SOURCE45} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/exec.conf
832 install %{SOURCE46} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/filecount.conf
833 install %{SOURCE47} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/interface.conf
834 %{?with_iptables:install %{SOURCE48} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/iptables.conf}
835 install %{SOURCE49} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/irq.conf
836 install %{SOURCE51} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/load.conf
837 install %{SOURCE52} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/logfile.conf
838 install %{SOURCE53} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/mbmon.conf
839 install %{SOURCE54} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/memcached.conf
840 install %{SOURCE55} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/memory.conf
841 %{?with_multimeter:install %{SOURCE56} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/multimeter.conf}
842 %{?with_netlink:install %{SOURCE57} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/netlink.conf}
843 install %{SOURCE58} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/network.conf
844 install %{SOURCE59} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/nfs.conf
845 install %{SOURCE60} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/ntpd.conf
846 install %{SOURCE61} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/processes.conf
847 install %{SOURCE62} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/serial.conf
848 install %{SOURCE63} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/swap.conf
849 install %{SOURCE64} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/syslog.conf
850 install %{SOURCE65} $RPM_BUILD_ROOT%{_sysconfdir}/collectd.d/tail.conf
853 rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/*.la
856 rm -rf $RPM_BUILD_ROOT
859 /sbin/chkconfig --add %{name}
860 %service %{name} restart
863 if [ "$1" = "0" ]; then
864 %service -q %{name} stop
865 /sbin/chkconfig --del %{name}
868 %define module_scripts() \
870 %service %{name} restart \
873 %service %{name} restart
875 %module_scripts apache
876 %module_scripts apcups
877 %module_scripts ascent
878 %module_scripts battery
879 %module_scripts cpufreq
884 %{?with_dns:%module_scripts dns}
885 %module_scripts email
886 %module_scripts entropy
888 %module_scripts filecount
889 %module_scripts hddtemp
890 %module_scripts interface
891 %{?with_ipmi:%module_scripts ipmi}
892 %{?with_iptables:%module_scripts iptables}
895 %module_scripts logfile
896 %module_scripts mbmon
897 %module_scripts memcached
898 %module_scripts memory
899 %{?with_multimeter:%module_scripts multimeter}
900 %module_scripts mysql
901 %{?with_netlink:%module_scripts netlink}
902 %module_scripts network
904 %module_scripts nginx
905 %module_scripts notify_desktop
906 %module_scripts notify_email
910 %module_scripts postgresql
911 %module_scripts powerdns
912 %module_scripts processes
913 %module_scripts rrdtool
914 %module_scripts sensors
915 %module_scripts serial
918 %module_scripts syslog
920 %module_scripts tcpconns
921 %module_scripts teamspeak2
922 %module_scripts thermal
923 %module_scripts unixsock
924 %module_scripts users
927 %module_scripts vserver
928 %module_scripts wireless
931 %triggerin collection -- apache1 < 1.3.37-3, apache1-base
932 %webapp_register apache %{_webapp}
934 %triggerun collection -- apache1 < 1.3.37-3, apache1-base
935 %webapp_unregister apache %{_webapp}
937 %triggerin collection -- apache < 2.2.0, apache-base
938 %webapp_register httpd %{_webapp}
940 %triggerun collection -- apache < 2.2.0, apache-base
941 %webapp_unregister httpd %{_webapp}
944 %defattr(644,root,root,755)
945 %doc AUTHORS ChangeLog README TODO contrib
946 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.conf
947 %dir %{_sysconfdir}/%{name}.d
948 %attr(755,root,root) %{_sbindir}/collectd
949 %attr(755,root,root) %{_sbindir}/collectdmon
950 %attr(755,root,root) %{_bindir}/collectd-nagios
951 %dir %{_libdir}/%{name}
952 %{_libdir}/%{name}/types.db
953 %attr(754,root,root) /etc/rc.d/init.d/%{name}
954 %{_mandir}/man1/collectd.1*
955 %{_mandir}/man1/collectd-nagios.1*
956 %{_mandir}/man5/collectd.conf.5*
957 %{_mandir}/man5/collectd-perl.5*
958 %{_mandir}/man1/collectdmon.1*
959 %{_mandir}/man5/types.db.5*
960 %{_var}/log/collectd.log
961 %dir %{_var}/lib/%{name}
964 %defattr(644,root,root,755)
966 %config(noreplace) %verify(not md5 mtime size) %{_webappdir}/collection.conf
967 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_webappdir}/apache.conf
968 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_webappdir}/httpd.conf
970 %dir %{_appdir}/cgi-bin
971 %attr(755,root,root) %{_appdir}/cgi-bin/collection.cgi
975 %defattr(644,root,root,755)
976 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/apcups.conf
977 %attr(755,root,root) %{_libdir}/%{name}/apcups.so
980 %defattr(644,root,root,755)
981 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/ascent.conf
982 %attr(755,root,root) %{_libdir}/%{name}/ascent.so
985 %defattr(644,root,root,755)
986 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/apache.conf
987 %attr(755,root,root) %{_libdir}/%{name}/apache.so
990 %defattr(644,root,root,755)
991 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/battery.conf
992 %attr(755,root,root) %{_libdir}/%{name}/battery.so
995 %defattr(644,root,root,755)
996 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/cpu.conf
997 %attr(755,root,root) %{_libdir}/%{name}/cpu.so
1000 %defattr(644,root,root,755)
1001 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/cpufreq.conf
1002 %attr(755,root,root) %{_libdir}/%{name}/cpufreq.so
1005 %defattr(644,root,root,755)
1006 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/csv.conf
1007 %attr(755,root,root) %{_libdir}/%{name}/csv.so
1010 %defattr(644,root,root,755)
1011 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/df.conf
1012 %attr(755,root,root) %{_libdir}/%{name}/df.so
1015 %defattr(644,root,root,755)
1016 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/disk.conf
1017 %attr(755,root,root) %{_libdir}/%{name}/disk.so
1020 %defattr(644,root,root,755)
1021 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/dns.conf
1022 %attr(755,root,root) %{_libdir}/%{name}/dns.so
1025 %defattr(644,root,root,755)
1026 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/email.conf
1027 %attr(755,root,root) %{_libdir}/%{name}/email.so
1028 %{_mandir}/man5/collectd-email.5*
1031 %defattr(644,root,root,755)
1032 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/entropy.conf
1033 %attr(755,root,root) %{_libdir}/%{name}/entropy.so
1036 %defattr(644,root,root,755)
1037 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/exec.conf
1038 %attr(755,root,root) %{_libdir}/%{name}/exec.so
1039 %{_mandir}/man5/collectd-exec.5*
1042 %defattr(644,root,root,755)
1043 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/filecount.conf
1044 %attr(755,root,root) %{_libdir}/%{name}/filecount.so
1047 %defattr(644,root,root,755)
1048 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/hddtemp.conf
1049 %attr(755,root,root) %{_libdir}/%{name}/hddtemp.so
1052 %defattr(644,root,root,755)
1053 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/interface.conf
1054 %attr(755,root,root) %{_libdir}/%{name}/interface.so
1058 %defattr(644,root,root,755)
1059 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/ipmi.conf
1060 %attr(755,root,root) %{_libdir}/%{name}/ipmi.so
1063 %if %{with iptables}
1065 %defattr(644,root,root,755)
1066 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/iptables.conf
1067 %attr(755,root,root) %{_libdir}/%{name}/iptables.so
1071 %defattr(644,root,root,755)
1072 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/irq.conf
1073 %attr(755,root,root) %{_libdir}/%{name}/irq.so
1076 %defattr(644,root,root,755)
1077 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/load.conf
1078 %attr(755,root,root) %{_libdir}/%{name}/load.so
1081 %defattr(644,root,root,755)
1082 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/logfile.conf
1083 %attr(755,root,root) %{_libdir}/%{name}/logfile.so
1086 %defattr(644,root,root,755)
1087 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/mbmon.conf
1088 %attr(755,root,root) %{_libdir}/%{name}/mbmon.so
1091 %defattr(644,root,root,755)
1092 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/memcached.conf
1093 %attr(755,root,root) %{_libdir}/%{name}/memcached.so
1096 %defattr(644,root,root,755)
1097 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/memory.conf
1098 %attr(755,root,root) %{_libdir}/%{name}/memory.so
1100 %if %{with multimeter}
1102 %defattr(644,root,root,755)
1103 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/multimeter.conf
1104 %attr(755,root,root) %{_libdir}/%{name}/multimeter.so
1108 %defattr(644,root,root,755)
1109 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/mysql.conf
1110 %attr(755,root,root) %{_libdir}/%{name}/mysql.so
1114 %defattr(644,root,root,755)
1115 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/netlink.conf
1116 %attr(755,root,root) %{_libdir}/%{name}/netlink.so
1120 %defattr(644,root,root,755)
1121 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/network.conf
1122 %attr(755,root,root) %{_libdir}/%{name}/network.so
1125 %defattr(644,root,root,755)
1126 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/nfs.conf
1127 %attr(755,root,root) %{_libdir}/%{name}/nfs.so
1130 %defattr(644,root,root,755)
1131 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/nginx.conf
1132 %attr(755,root,root) %{_libdir}/%{name}/nginx.so
1134 %files notify_desktop
1135 %defattr(644,root,root,755)
1136 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/notify_desktop.conf
1137 %attr(755,root,root) %{_libdir}/%{name}/notify_desktop.so
1140 %defattr(644,root,root,755)
1141 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/notify_email.conf
1142 %attr(755,root,root) %{_libdir}/%{name}/notify_email.so
1145 %defattr(644,root,root,755)
1146 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/ntpd.conf
1147 %attr(755,root,root) %{_libdir}/%{name}/ntpd.so
1150 %defattr(644,root,root,755)
1151 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/nut.conf
1152 %attr(755,root,root) %{_libdir}/%{name}/nut.so
1155 %defattr(644,root,root,755)
1156 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/ping.conf
1157 %attr(755,root,root) %{_libdir}/%{name}/ping.so
1160 %defattr(644,root,root,755)
1161 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/postgresql.conf
1162 %attr(755,root,root) %{_libdir}/%{name}/postgresql.so
1165 %defattr(644,root,root,755)
1166 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/powerdns.conf
1167 %attr(755,root,root) %{_libdir}/%{name}/powerdns.so
1170 %defattr(644,root,root,755)
1171 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/processes.conf
1172 %attr(755,root,root) %{_libdir}/%{name}/processes.so
1175 %defattr(644,root,root,755)
1176 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/rrdtool.conf
1177 %attr(755,root,root) %{_libdir}/%{name}/rrdtool.so
1180 %defattr(644,root,root,755)
1181 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/sensors.conf
1182 %attr(755,root,root) %{_libdir}/%{name}/sensors.so
1185 %defattr(644,root,root,755)
1186 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/serial.conf
1187 %attr(755,root,root) %{_libdir}/%{name}/serial.so
1190 %defattr(644,root,root,755)
1191 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/snmp.conf
1192 %attr(755,root,root) %{_libdir}/%{name}/snmp.so
1193 %{_mandir}/man5/collectd-snmp.5*
1196 %defattr(644,root,root,755)
1197 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/swap.conf
1198 %attr(755,root,root) %{_libdir}/%{name}/swap.so
1201 %defattr(644,root,root,755)
1202 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/syslog.conf
1203 %attr(755,root,root) %{_libdir}/%{name}/syslog.so
1206 %defattr(644,root,root,755)
1207 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/tail.conf
1208 %attr(755,root,root) %{_libdir}/%{name}/tail.so
1211 %defattr(644,root,root,755)
1212 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/tcpconns.conf
1213 %attr(755,root,root) %{_libdir}/%{name}/tcpconns.so
1216 %defattr(644,root,root,755)
1217 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/teamspeak2.conf
1218 %attr(755,root,root) %{_libdir}/%{name}/teamspeak2.so
1221 %defattr(644,root,root,755)
1222 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/thermal.conf
1223 %attr(755,root,root) %{_libdir}/%{name}/thermal.so
1226 %defattr(644,root,root,755)
1227 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/unixsock.conf
1228 %attr(755,root,root) %{_libdir}/%{name}/unixsock.so
1229 %{_mandir}/man5/collectd-unixsock.5*
1232 %defattr(644,root,root,755)
1233 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/users.conf
1234 %attr(755,root,root) %{_libdir}/%{name}/users.so
1237 %defattr(644,root,root,755)
1238 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/uuid.conf
1239 %attr(755,root,root) %{_libdir}/%{name}/uuid.so
1242 %defattr(644,root,root,755)
1243 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/vmem.conf
1244 %attr(755,root,root) %{_libdir}/%{name}/vmem.so
1247 %defattr(644,root,root,755)
1248 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/vserver.conf
1249 %attr(755,root,root) %{_libdir}/%{name}/vserver.so
1252 %defattr(644,root,root,755)
1253 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/wireless.conf
1254 %attr(755,root,root) %{_libdir}/%{name}/wireless.so
1257 %defattr(644,root,root,755)
1258 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}.d/xmms.conf
1259 %attr(755,root,root) %{_libdir}/%{name}/xmms.so