3 # - update desktop files, think about su-wrappers for console
4 %bcond_with console_wx #Enable console-wx program
6 Summary: Bacula - The Network Backup Solution
7 Summary(pl): Bacula - rozwi±zanie do wykonywania kopii zapasowych po sieci
12 Group: Networking/Utilities
13 License: extended GPL v2
14 Source0: http://dl.sourceforge.net/bacula/%{name}-%{version}.tar.gz
15 # Source0-md5: 9499d6277b8673ae7c24dcdbf89ee026
16 Source1: %{name}-manpages.tar.bz2
17 # Source1-md5: e4dae86d6574b360e831efd3913e7f4c
18 Source2: http://dl.sourceforge.net/bacula/%{name}-doc-%{version}.tar.gz
19 # Source2-md5: db08859bc193e777c76bcbf5e60f0c7e
20 Source10: %{name}-dir.init
21 Source11: %{name}-fd.init
22 Source12: %{name}-sd.init
23 Source13: %{name}.logrotate
24 Source14: %{name}-dir.sysconfig
25 Source15: %{name}-fd.sysconfig
26 Source16: %{name}-sd.sysconfig
27 URL: http://www.bacula.org/
28 BuildRequires: acl-static
29 BuildRequires: automake
30 BuildRequires: glibc-static
31 BuildRequires: libgnome-devel >= 2.0
32 BuildRequires: libgnomeui-devel >= 2.0
33 BuildRequires: libstdc++-static
34 BuildRequires: libwrap-static
36 BuildRequires: ncurses-devel
37 BuildRequires: openssl-devel
38 BuildRequires: pkgconfig
39 BuildRequires: readline-devel
40 BuildRequires: rpmbuild(macros) >= 1.202
41 BuildRequires: sed >= 4.0
42 BuildRequires: sqlite-devel
43 %if %{with console_wx}
44 BuildRequires: wxGTK2-devel >= 2.4.0
45 BuildRequires: wxGTK2-devel < 2.5.0
47 BuildRequires: zlib-devel
48 BuildRequires: zlib-static
49 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
51 %define _sysconfdir /etc/%{name}
52 %define _localstatedir /var/lib/%{name}
55 Bacula - It comes by night and sucks the vital essence from your
58 Bacula is a set of computer programs that permit you (or the system
59 administrator) to manage backup, recovery, and verification of
60 computer data across a network of computers of different kinds. In
61 technical terms, it is a network client/server based backup program.
62 Bacula is relatively easy to use and efficient, while offering many
63 advanced storage management features that make it easy to find and
64 recover lost or damaged files.
67 Bacula - przychodzi noc± i wysysa ¿ywotny ekstrakt z komputerów.
69 Bacula to zbiór programów umo¿liwiaj±cych administratorowi na
70 zarz±dzanie kopiami zapasowymi, odzyskiwaniem i weryfikacj± danych
71 w sieci komputerów ró¿nego rodzaju. W terminologii technicznej jest to
72 program do kopii zapasowych pracuj±cy w architekturze klient-serwer.
73 Bacula jest stosunkowo ³atwa w u¿yciu i wydajna, oferuj±c przy tym
74 wiele zaawansowanych mo¿liwo¶ci przy zarz±dzaniu no¶nikami,
75 u³atwiaj±cych znalezienie i odzyskanie utraconych lub uszkodzonych
79 Summary: Common files for bacula package
80 Summary(pl): Pliki wspólne dla pakietu bacula
81 Group: Networking/Utilities
82 Conflicts: bacula-dir < 0:1.34.6
83 Conflicts: bacula-fd < 0:1.34.6
84 Conflicts: bacula-sd < 0:1.34.6
85 Conflicts: bacula-console < 0:1.34.6
86 Requires(post): openssl-tools
87 Requires(post): sed >= 4.0
90 Bacula - It comes by night and sucks the vital essence from your
93 Bacula is a set of computer programs that permit you (or the system
94 administrator) to manage backup, recovery, and verification of
95 computer data across a network of computers of different kinds. In
96 technical terms, it is a network client/server based backup program.
97 Bacula is relatively easy to use and efficient, while offering many
98 advanced storage management features that make it easy to find and
99 recover lost or damaged files.
101 %description common -l pl
102 Bacula - przychodzi noc± i wysysa ¿ywotny ekstrakt z komputerów.
104 Bacula to zbiór programów umo¿liwiaj±cych administratorowi na
105 zarz±dzanie kopiami zapasowymi, odzyskiwaniem i weryfikacj± danych
106 w sieci komputerów ró¿nego rodzaju. W terminologii technicznej jest to
107 program do kopii zapasowych pracuj±cy w architekturze klient-serwer.
108 Bacula jest stosunkowo ³atwa w u¿yciu i wydajna, oferuj±c przy tym
109 wiele zaawansowanych mo¿liwo¶ci przy zarz±dzaniu no¶nikami,
110 u³atwiaj±cych znalezienie i odzyskanie utraconych lub uszkodzonych
114 Summary: Bacula Director and Catalog services
115 Summary(pl): Us³ugi Bacula Director i Catalog
116 Group: Networking/Utilities
117 Obsoletes: %{name}-updatedb
118 PreReq: bacula-common = %{epoch}:%{version}-%{release}
119 Requires(post): sed >= 4.0
122 Bacula - It comes by night and sucks the vital essence from your
125 Bacula Director is the program that supervises all the backup,
126 restore, verify and archive operations. The system administrator uses
127 the Bacula Director to schedule backups and to recover files. Catalog
128 services are comprised of the software programs responsible for
129 maintaining the file indexes and volume databases for all files backed
130 up. The Catalog services permit the System Administrator or user to
131 quickly locate and restore any desired file, since it maintains a
132 record of all Volumes used, all Jobs run, and all Files saved. This
133 build requires sqlite to be installed separately as the catalog
136 %description dir -l pl
137 Bacula - przychodzi noc± i wysysa ¿ywotny ekstrakt z komputerów.
139 Bacula Director to program nadzoruj±cy wszystkie operacje wykonywania
140 kopii zapasowych, odzyskiwania, weryfikacji i archiwizowania.
141 Administrator u¿ywa Bacula Directora do szeregowania kopii zapasowych
142 oraz odzyskiwania plików. Us³ugi katalogowe (Catalog services) s±
143 u¿ywane przez programy odpowiedzialne za zarz±dzanie indeksami plików
144 i baz± danych wolumenów dla wszystkich kopiowanych plików. Us³ugi
145 katalogowe umo¿liwiaj± administratorowi lub u¿ytkownikowi szybko
146 zlokalizowaæ i odtworzyæ dowolny plik, poniewa¿ utrzymuj± rekord ze
147 wszystkimi u¿ywanymi wolumenami, uruchomionymi zadaniami i zapisanymi
148 plikami. Pakiet wymaga sqlite zainstalowanego oddzielnie jako bazy
152 Summary: Bacula Console
153 Summary(pl): Konsola Baculi
154 Group: Networking/Utilities
155 PreReq: bacula-common = %{epoch}:%{version}-%{release}
156 Requires(post): sed >= 4.0
159 Bacula - It comes by night and sucks the vital essence from your
162 Bacula Console is the program that allows the administrator or user to
163 communicate with the Bacula Director. This is the text only console
166 %description console -l pl
167 Bacula - przychodzi noc± i wysysa ¿ywotny ekstrakt z komputerów.
169 Bacula Console to program umo¿liwiaj±cy administratorowi lub
170 u¿ytkownikowi komunikowanie siê z programem Bacula Director. To jest
171 interfejs czysto tekstowy.
174 Summary: Bacula wxWidgets Console
175 Summary(pl): Konsola Baculi oparta na wxWidgets
176 Group: Networking/Utilities
177 PreReq: bacula-common = %{epoch}:%{version}-%{release}
178 Requires(post): sed >= 4.0
180 %description console-wx
181 Bacula - It comes by night and sucks the vital essence from your
184 Bacula Console is the program that allows the administrator or user to
185 communicate with the Bacula Director. This is the wxWidgets GUI
188 %description console-wx -l pl
189 Bacula - przychodzi noc± i wysysa ¿ywotny ekstrakt z komputerów.
191 Bacula Console to program umo¿liwiaj±cy administratorowi lub
192 u¿ytkownikowi komunikowanie siê z programem Bacula Director. To jest
193 interfejs graficzny oparty na wxWidgets.
195 %package console-gnome
196 Summary: Bacula GNOME Console
197 Summary(pl): Konsola Baculi oparta dla GNOME
198 Group: Networking/Utilities
199 PreReq: bacula-common = %{epoch}:%{version}-%{release}
200 Requires(post): sed >= 4.0
202 %description console-gnome
203 Bacula - It comes by night and sucks the vital essence from your
206 Bacula Console is the program that allows the administrator or user to
207 communicate with the Bacula Director. This is the GNOME GUI
210 %description console-gnome -l pl
211 Bacula - przychodzi noc± i wysysa ¿ywotny ekstrakt z komputerów.
213 Bacula Console to program umo¿liwiaj±cy administratorowi lub
214 u¿ytkownikowi komunikowanie siê z programem Bacula Director. To jest
215 interfejs graficzny oparty na GNOME.
217 %package tray-monitor
218 Summary: Bacula Tray Monitor
219 Group: Networking/Utilities
220 PreReq: bacula-common = %{epoch}:%{version}-%{release}
221 Requires(post): sed >= 4.0
223 %description tray-monitor
224 Bacula - It comes by night and sucks the vital essence from your
227 The Monitor program is typically an icon in the system tray. However, once the
228 icon is expanded into a full window, the administrator or user can obtain
229 status information about the Director or the backup status on the local
230 workstation or any other Bacula daemon that is configured.
233 Summary: Bacula File services (Client)
234 Summary(pl): Us³ugi Bacula File (klient)
235 Group: Networking/Utilities
236 PreReq: bacula-common = %{epoch}:%{version}-%{release}
237 Requires(post): sed >= 4.0
240 Bacula - It comes by night and sucks the vital essence from your
243 Bacula File services (or Client program) is the software program that
244 is installed on the machine to be backed up. It is specific to the
245 operating system on which it runs and is responsible for providing the
246 file attributes and data when requested by the Director. The File
247 services are also responsible for the file system dependent part of
248 restoring the file attributes and data during a recovery operation.
249 This program runs as a daemon on the machine to be backed up, and in
250 some of the documentation, the File daemon is referred to as the
251 Client (for example in Bacula configuration file).
253 %description fd -l pl
254 Bacula - przychodzi noc± i wysysa ¿ywotny ekstrakt z komputerów.
256 Us³ugi Bacula File (inaczej program kliencki) to oprogramowanie, które
257 instaluje siê na maszynach, z których maj± byæ wykonywane kopie
258 zapasowe. S± one specyficzne dla systemu operacyjnego, pod którym
259 dzia³a dana maszyna i odpowiadaj± za dostarczanie atrybutów i danych
260 plików na ¿±danie Directora. Us³ugi plikowe s± tak¿e odpowiedzialne za
261 zale¿n± od systemu plików czê¶æ odzyskiwania atrybutów i danych plików
262 podczas operacji odzyskiwania danych. Program dzia³a jako demon na
263 maszynie, która ma byæ backupowana i w czê¶ci dokumentacji demon ten
264 (File) jest nazywany klientem (na przyk³ad w pliku konfiguracyjnym
268 Summary: Bacula Storage services
269 Summary(pl): Us³ugi Bacula Storage
270 Group: Networking/Utilities
271 PreReq: bacula-common = %{epoch}:%{version}-%{release}
272 Requires(post): sed >= 4.0
275 Bacula - It comes by night and sucks the vital essence from your
278 Bacula Storage services consist of the software programs that perform
279 the storage and recovery of the file attributes and data to the
280 physical backup media or volumes. In other words, the Storage daemon
281 is responsible for reading and writing your tapes (or other storage
282 media, e.g. files). The Storage services runs as a daemon on the
283 machine that has the backup device (usually a tape drive).
285 %description sd -l pl
286 Bacula - przychodzi noc± i wysysa ¿ywotny ekstrakt z komputerów.
288 Us³ugi Bacula Storage sk³adaj± siê z programów obs³uguj±cych
289 przechowywanie danych oraz odzyskiwanie atrybutów i danych na
290 fizycznych no¶nikach lub wolumenach. Innymi s³owy, demon Storage jest
291 odpowiedzialny za odczyt i zapis ta¶m (lub innych no¶ników do
292 przechowywania danych, np. plików). Us³ugi Storage dzia³aj± jako demon
293 na maszynie, która zawiera urz±dzenie backupowe (zwykle napêd
297 Summary: Bacula - The Network Backup Solution
298 Summary(pl): Bacula - rozwi±zanie do wykonywania kopii zapasowych po sieci
299 Group: Networking/Utilities
300 Requires: %{name}-fd = %{epoch}:%{version}-%{release}
305 Bacula - It comes by night and sucks the vital essence from your
308 Bacula is a set of computer programs that permit you (or the system
309 administrator) to manage backup, recovery, and verification of
310 computer data across a network of computers of different kinds. In
311 technical terms, it is a network client/server based backup program.
312 Bacula is relatively easy to use and efficient, while offering many
313 advanced storage management features that make it easy to find and
314 recover lost or damaged files.
316 This package installs scripts for disaster recovery and builds rescue
317 floppy disk for bare metal recovery.
319 To make the bacula rescue disk run "./make_rescue_disk --copy-static-bacula
320 - --copy-etc-files" from the %{_sysconfdir}/rescue directory. To recreate the
321 rescue information for this system run ./getdiskinfo again.
323 %description rescue -l pl
324 Bacula - przychodzi noc± i wysysa ¿ywotny ekstrakt z komputerów.
326 Bacula to zbiór programów umo¿liwiaj±cych administratorowi na
327 zarz±dzanie kopiami zapasowymi, odzyskiwaniem i weryfikacj± danych
328 w sieci komputerów ró¿nego rodzaju. W terminologii technicznej jest to
329 program do kopii zapasowych pracuj±cy w architekturze klient-serwer.
330 Bacula jest stosunkowo ³atwa w u¿yciu i wydajna, oferuj±c przy tym
331 wiele zaawansowanych mo¿liwo¶ci przy zarz±dzaniu no¶nikami,
332 u³atwiaj±cych znalezienie i odzyskanie utraconych lub uszkodzonych
335 Ten pakiet zawiera skrypty do odtwarzania po awarii i tworzy dyskietkê
336 ratunkowe do odtwarzania systemu od zera.
338 Aby stworzyæ dyskietkê ratunkow± Baculi, nale¿y uruchomiæ "./make_rescue_disk
339 --copy-static-bacula - --copy-etc-files" z katalogu
340 %{_sysconfdir}/rescue . Aby ponownie utworzyæ informacje ratunkowe dla
341 danego systemu, nale¿y ponownie uruchomiæ ./getdiskinfo .
345 sed -i -e 's#wx-config#wxgtk2-2.4-config#g' configure*
346 sed -i -e 's#-lreadline -ltermcap#-lreadline#g' configure*
347 sed -i -e 's#bindir=.*#bindir=%{_bindir}#g' \
348 src/cats/create_* src/cats/delete_* src/cats/drop_* \
349 src/cats/grant_* src/cats/make_* src/cats/update_*
350 sed -i -e 's/@hostname@/--hostname--/' src/*/*.conf.in
353 cp -f %{_datadir}/automake/config.sub autoconf
354 CPPFLAGS="-I%{_includedir}/ncurses -I%{_includedir}/readline"
356 --with-scriptdir=%{_libexecdir}/%{name} \
359 --enable-smartalloc \
360 %{?with_console_wx:--enable-wx-console} \
361 --enable-tray-monitor \
363 --with-tcp-wrappers \
364 --with-working-dir=%{_var}/lib/%{name} \
365 --with-dump-email="root@localhost" \
366 --with-job-email="root@localhost" \
367 --with-smtp-host=localhost \
368 --with-pid-dir=/var/run \
369 --with-subsys-dir=/var/lock/subsys \
371 --with-dir-password="#FAKE-dir-password#" \
372 --with-fd-password="#FAKE-fd-password#" \
373 --with-sd-password="#FAKE-sd-password#" \
374 --with-mon-dir-password="#FAKE-mon-dir-password#" \
375 --with-mon-fd-password="#FAKE-mon-fd-password#" \
376 --with-mon-sd-password="#FAKE-mon-sd-password#" \
382 rm -rf $RPM_BUILD_ROOT
384 install -d $RPM_BUILD_ROOT/etc/{rc.d/init.d,logrotate.d,pam.d,sysconfig}
385 install -d $RPM_BUILD_ROOT%{_sysconfdir}/rescue
386 install -d $RPM_BUILD_ROOT{%{_pixmapsdir},%{_desktopdir},%{_mandir},%{_bindir}}
389 DESTDIR=$RPM_BUILD_ROOT
392 strip -R.comment -R.note src/filed/static-bacula-fd
393 install src/filed/static-bacula-fd $RPM_BUILD_ROOT%{_sysconfdir}/rescue/bacula-fd
395 # tray-monitor is for regular users
396 mv $RPM_BUILD_ROOT%{_sbindir}/bacula-tray-monitor $RPM_BUILD_ROOT%{_bindir}
398 install %{SOURCE10} $RPM_BUILD_ROOT/etc/rc.d/init.d/bacula-dir
399 install %{SOURCE11} $RPM_BUILD_ROOT/etc/rc.d/init.d/bacula-fd
400 install %{SOURCE12} $RPM_BUILD_ROOT/etc/rc.d/init.d/bacula-sd
401 install %{SOURCE13} $RPM_BUILD_ROOT/etc/logrotate.d/%{name}-dir
402 install %{SOURCE14} $RPM_BUILD_ROOT/etc/sysconfig/bacula-dir
403 install %{SOURCE15} $RPM_BUILD_ROOT/etc/sysconfig/bacula-fd
404 install %{SOURCE16} $RPM_BUILD_ROOT/etc/sysconfig/bacula-sd
406 install scripts/bacula.png $RPM_BUILD_ROOT%{_pixmapsdir}/bacula.png
407 install src/tray-monitor/generic.xpm $RPM_BUILD_ROOT%{_pixmapsdir}/bacula-tray-monitor.xpm
408 install scripts/bacula.desktop.gnome2 $RPM_BUILD_ROOT%{_desktopdir}/bacula.desktop
409 sed -e 's/gnome-console/wx-console/g;s/Console/Wx Console/g' \
410 scripts/bacula.desktop.gnome2 > $RPM_BUILD_ROOT%{_desktopdir}/bacula-wx.desktop
411 sed -e 's#%{_sbindir}#%{_bindir}#' \
412 scripts/bacula-tray-monitor.desktop > $RPM_BUILD_ROOT%{_desktopdir}/bacula-tray-monitor.desktop
414 # install the rescue stuff, these are the rescue scripts
415 install rescue/linux/floppy/backup.etc.list $RPM_BUILD_ROOT%{_sysconfdir}/rescue
416 install rescue/linux/floppy/*_* $RPM_BUILD_ROOT%{_sysconfdir}/rescue
417 install rescue/linux/floppy/getdiskinfo $RPM_BUILD_ROOT%{_sysconfdir}/rescue
418 install rescue/linux/floppy/sfdisk.bz2 $RPM_BUILD_ROOT%{_sysconfdir}/rescue
420 # install the updatedb scripts
421 install updatedb/update_sqlite* $RPM_BUILD_ROOT%{_libexecdir}/%{name}
424 cp -a man1 man8 $RPM_BUILD_ROOT%{_mandir}
428 # place for site passwords
429 touch $RPM_BUILD_ROOT%{_sysconfdir}/{dir-password,fd-password,sd-password}
430 touch $RPM_BUILD_ROOT%{_sysconfdir}/{mon-dir-password,mon-fd-password,mon-sd-password}
433 rm -f $RPM_BUILD_ROOT%{_libexecdir}/%{name}/{gconsole,startmysql,stopmysql,bacula,bconsole,fd}
434 rm -f $RPM_BUILD_ROOT%{_sbindir}/static-bacula-fd
435 rm -f $RPM_BUILD_ROOT%{_mandir}/man1/gnome*
436 %if !%{with console_wx}
437 rm -f $RPM_BUILD_ROOT%{_desktopdir}/bacula-wx.desktop
438 rm -f $RPM_BUILD_ROOT%{_mandir}/man1/wx-console*
440 touch $RPM_BUILD_ROOT%{_sysconfdir}/.pw.sed
443 rm -rf $RPM_BUILD_ROOT
446 %groupadd -P %{name}-common -g 136 -r -f bacula
447 %useradd -P %{name}-common -u 136 -r -d /var/lib/bacula -s /bin/false -c "Bacula User" -g bacula bacula
450 echo "Updating bacula passwords and names..."
452 for f in *-password ; do
453 if [ ! -s $f ] ; then
454 openssl rand -base64 33 > $f
457 for cf in *.conf *.conf.rpmnew ; do
458 [ -f $cf ] && sed -i -e"s:#FAKE-$f#:$p:" "$cf" || :
461 for cf in *.conf *.conf.rpmnew ; do
462 [ -f $cf ] && sed -i -e"s:--hostname--:`hostname`:" "$cf" || :
466 if [ "$1" = "0" ]; then
473 [ -s %{_localstatedir}/bacula.db ] && \
474 DB_VER=`echo "select * from Version;" | \
475 %{_bindir}/sqlite %{_localstatedir}/bacula.db | tail -n 1 2>/dev/null`
476 if [ -z "$DB_VER" ]; then
477 # grant privileges and create tables
478 %{_libexecdir}/%{name}/grant_bacula_privileges > dev/null
479 %{_libexecdir}/%{name}/create_bacula_database > dev/null
480 %{_libexecdir}/%{name}/make_bacula_tables > dev/null
481 elif [ "$DB_VER" -lt "8" ]; then
482 echo "Backing up bacula tables"
483 echo ".dump" | sqlite %{_localstatedir}/bacula.db | bzip2 > %{_localstatedir}/bacula_backup.sql.bz2
485 echo "Upgrading bacula tables"
486 if [ "$DB_VER" -lt "7" ]; then
487 if [ "$DB_VER" -lt "6" ]; then
488 if [ "$DB_VER" -lt "5" ]; then
489 %{_libexecdir}/%{name}/update_${type}_tables_4_to_5
491 %{_libexecdir}/%{name}/update_${type}_tables_5_to_6
493 %{_libexecdir}/%{name}/update_${type}_tables_6_to_7
495 %{_libexecdir}/%{name}/update_bacula_tables
496 echo "If bacula works correctly you can remove the backup file %{_localstatedir}/bacula_backup.sql.bz2"
498 chown -R bacula:bacula %{_localstatedir}
499 chmod -R u+rX,go-rwx %{_localstatedir}/*
501 echo "Updating Bacula passwords and names..."
503 for f in *-password ; do
505 sed -i -e"s:#FAKE-$f#:$p:" *.conf *.conf.rpmnew
507 sed -i -e"s:--hostname--:`hostname`:" *.conf *.conf.rpmnew
509 /sbin/chkconfig --add bacula-dir
510 if [ -f /var/lock/subsys/bacula-dir ]; then
511 /etc/rc.d/init.d/bacula-dir restart 1>&2
513 echo "Run \"/etc/rc.d/init.d/bacula-dir start\" to start Bacula Director daemon."
517 if [ "$1" = "0" ]; then
518 if [ -f /var/lock/subsys/bacula-dir ]; then
519 /etc/rc.d/init.d/bacula-dir stop 1>&2
521 /sbin/chkconfig --del bacula-dir
525 echo "Updating Bacula passwords and names..."
527 for f in *-password ; do
529 sed -i -e"s:#FAKE-$f#:$p:" *.conf *.conf.rpmnew
531 sed -i -e"s:--hostname--:`hostname`:" *.conf *.conf.rpmnew
533 /sbin/chkconfig --add bacula-fd
534 if [ -f /var/lock/subsys/bacula-fd ]; then
535 /etc/rc.d/init.d/bacula-fd restart 1>&2
537 echo "Run \"/etc/rc.d/init.d/bacula-fd start\" to start Bacula File daemon."
541 if [ "$1" = "0" ]; then
542 if [ -f /var/lock/subsys/bacula-fd ]; then
543 /etc/rc.d/init.d/bacula-fd stop 1>&2
545 /sbin/chkconfig --del bacula-fd
549 echo "Updating Bacula passwords and names..."
551 for f in *-password ; do
553 sed -i -e"s:#FAKE-$f#:$p:" *.conf *.conf.rpmnew
555 sed -i -e"s:--hostname--:`hostname`:" *.conf *.conf.rpmnew
557 /sbin/chkconfig --add bacula-sd
558 if [ -f /var/lock/subsys/bacula-sd ]; then
559 /etc/rc.d/init.d/bacula-sd restart 1>&2
561 echo "Run \"/etc/rc.d/init.d/bacula-sd start\" to start Bacula Storage daemon."
565 if [ "$1" = "0" ]; then
566 if [ -f /var/lock/subsys/bacula-sd ]; then
567 /etc/rc.d/init.d/bacula-sd stop 1>&2
569 /sbin/chkconfig --del bacula-sd
573 if [ -e %{_sysconfdir}/console.conf -a ! -e %{_sysconfdir}/bconsole.conf ]; then
574 mv %{_sysconfdir}/console.conf %{_sysconfdir}/bconsole.conf
578 echo "Updating Bacula passwords and names..."
580 for f in *-password ; do
582 sed -i -e"s:#FAKE-$f#:$p:" *.conf *.conf.rpmnew
584 sed -i -e"s:--hostname--:`hostname`:" *.conf *.conf.rpmnew
587 echo "Updating Bacula passwords and names..."
589 for f in *-password ; do
591 sed -i -e"s:#FAKE-$f#:$p:" *.conf *.conf.rpmnew
593 sed -i -e"s:--hostname--:`hostname`:" *.conf *.conf.rpmnew
596 echo "Updating Bacula passwords and names..."
598 for f in *-password ; do
600 sed -i -e"s:#FAKE-$f#:$p:" *.conf *.conf.rpmnew
602 sed -i -e"s:--hostname--:`hostname`:" *.conf *.conf.rpmnew
605 echo "Updating Bacula passwords and names..."
607 for f in *-password ; do
609 sed -i -e"s:#FAKE-$f#:$p:" *.conf *.conf.rpmnew
611 sed -i -e"s:--hostname--:`hostname`:" *.conf *.conf.rpmnew
614 # link our current installed conf file to the rescue directory
615 ln -sf %{_sysconfdir}/bacula-fd.conf %{_sysconfdir}/rescue/bacula-fd.conf
618 echo "Creating rescue files for this system..."
619 cd %{_sysconfdir}/rescue
623 # remove the files created after the initial rpm installation
624 if [ "$1" = "0" ]; then
625 rm -f %{_sysconfdir}/rescue/bacula-fd.conf
626 rm -f %{_sysconfdir}/rescue/partition.*
627 rm -f %{_sysconfdir}/rescue/format.*
628 rm -f %{_sysconfdir}/rescue/mount_drives
629 rm -f %{_sysconfdir}/rescue/start_network
630 rm -f %{_sysconfdir}/rescue/sfdisk
631 rm -rf %{_sysconfdir}/rescue/diskinfo/*
635 %defattr(644,root,root,755)
638 %attr(600,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/*-password
639 %attr(755,root,root) %{_sbindir}/btraceback
640 %attr(755,root,root) %{_sbindir}/bsmtp
641 %dir %{_libexecdir}/%{name}
642 %{_libexecdir}/%{name}/btraceback.dbx
643 %{_libexecdir}/%{name}/btraceback.gdb
644 %attr(770,root,bacula) %dir %{_localstatedir}
647 %defattr(644,root,root,755)
648 %doc ChangeLog CheckList ReleaseNotes kernstodo LICENSE
649 %doc doc/*.pdf examples %{name}-doc-%{version}/html-manual
650 %attr(600,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/bacula-dir.conf
651 %ghost %{_sysconfdir}/.pw.sed
652 %attr(640,root,root) %config(noreplace) /etc/logrotate.d/bacula-dir
653 %attr(754,root,root) /etc/rc.d/init.d/bacula-dir
654 %attr(644,root,root) %config(noreplace) %verify(not md5 size mtime) /etc/sysconfig/bacula-dir
655 %attr(755,root,root) %{_sbindir}/bacula-dir
656 %attr(755,root,root) %{_sbindir}/dbcheck
657 %{_mandir}/man8/bacula-dir.8*
658 %{_mandir}/man1/dbcheck.1*
659 %{_libexecdir}/%{name}/query.sql
660 %attr(755,root,root) %{_libexecdir}/%{name}/create_sqlite_database
661 %attr(755,root,root) %{_libexecdir}/%{name}/drop_sqlite_database
662 %attr(755,root,root) %{_libexecdir}/%{name}/drop_sqlite_tables
663 %attr(755,root,root) %{_libexecdir}/%{name}/grant_sqlite_privileges
664 %attr(755,root,root) %{_libexecdir}/%{name}/make_sqlite_tables
665 %attr(755,root,root) %{_libexecdir}/%{name}/update_sqlite_tables*
666 %attr(755,root,root) %{_libexecdir}/%{name}/create_bacula_database
667 %attr(755,root,root) %{_libexecdir}/%{name}/drop_bacula_database
668 %attr(755,root,root) %{_libexecdir}/%{name}/drop_bacula_tables
669 %attr(755,root,root) %{_libexecdir}/%{name}/grant_bacula_privileges
670 %attr(755,root,root) %{_libexecdir}/%{name}/make_bacula_tables
671 %attr(755,root,root) %{_libexecdir}/%{name}/update_bacula_tables
672 %attr(755,root,root) %{_libexecdir}/%{name}/make_catalog_backup
673 %attr(755,root,root) %{_libexecdir}/%{name}/delete_catalog_backup
676 %defattr(644,root,root,755)
678 %attr(600,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/bacula-fd.conf
679 %attr(754,root,root) /etc/rc.d/init.d/bacula-fd
680 %attr(644,root,root) %config(noreplace) %verify(not md5 size mtime) /etc/sysconfig/bacula-fd
681 %attr(755,root,root) %{_sbindir}/bacula-fd
682 %{_mandir}/man8/bacula-fd.8*
685 %defattr(644,root,root,755)
688 %attr(600,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/bacula-sd.conf
689 %attr(754,root,root) /etc/rc.d/init.d/bacula-sd
690 %attr(644,root,root) %config(noreplace) %verify(not md5 size mtime) /etc/sysconfig/bacula-sd
691 %attr(755,root,root) %{_sbindir}/bacula-sd
692 %attr(755,root,root) %{_sbindir}/bcopy
693 %attr(755,root,root) %{_sbindir}/bextract
694 %attr(755,root,root) %{_sbindir}/bls
695 %attr(755,root,root) %{_sbindir}/bscan
696 %attr(755,root,root) %{_sbindir}/btape
697 %{_libexecdir}/%{name}/mtx-changer
698 %{_mandir}/man8/bacula-sd.8*
699 %{_mandir}/man1/bcopy.1*
700 %{_mandir}/man1/bextract.1*
701 %{_mandir}/man1/bls.1*
702 %{_mandir}/man1/bscan.1*
703 %{_mandir}/man1/btape.1*
706 %defattr(644,root,root,755)
708 %attr(600,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/bconsole.conf
709 %attr(755,root,root) %{_sbindir}/bconsole
710 %{_mandir}/man1/bconsole.1*
712 %if %{with console_wx}
714 %defattr(644,root,root,755)
716 %{_pixmapsdir}/%{name}.png
717 %{_desktopdir}/bacula-wx.desktop
718 %attr(600,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/wx-console.conf
719 %attr(755,root,root) %{_sbindir}/wx-console
720 %{_mandir}/man1/wx-console.1*
724 %defattr(644,root,root,755)
726 %{_pixmapsdir}/%{name}.png
727 %{_desktopdir}/bacula.desktop
728 %attr(600,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/gnome-console.conf
729 %attr(755,root,root) %{_sbindir}/gnome-console
730 #%{_mandir}/man1/gnome-console.1*
733 %defattr(644,root,root,755)
735 %{_pixmapsdir}/%{name}-tray-monitor.xpm
736 %{_desktopdir}/%{name}-tray-monitor.desktop
737 %attr(644,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/tray-monitor.conf
738 %attr(755,root,root) %{_bindir}/bacula-tray-monitor
739 #%{_mandir}/man1/bacula-tray-monitor.1*
742 %defattr(644,root,root,755)
744 %dir %{_sysconfdir}/rescue
745 %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/rescue/backup.etc.list
746 %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/rescue/bacula-fd
747 %attr(755,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/rescue/format_floppy
748 %attr(755,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/rescue/getdiskinfo
749 %attr(755,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/rescue/make_rescue_disk
750 %attr(755,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/rescue/restore_bacula
751 %attr(755,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/rescue/restore_etc
752 %attr(755,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/rescue/run_grub
753 %attr(755,root,root) %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/rescue/run_lilo
754 %config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/rescue/sfdisk.bz2