1 |
wschlich 10/05/11 06:50:19 |
2 |
|
3 |
Modified: bacula-5.0.1-r2.ebuild ChangeLog |
4 |
Added: bacula-5.0.2.ebuild |
5 |
Log: |
6 |
version bump |
7 |
(Portage version: 2.2_rc60/cvs/Linux i686) |
8 |
|
9 |
Revision Changes Path |
10 |
1.2 app-backup/bacula/bacula-5.0.1-r2.ebuild |
11 |
|
12 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-backup/bacula/bacula-5.0.1-r2.ebuild?rev=1.2&view=markup |
13 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-backup/bacula/bacula-5.0.1-r2.ebuild?rev=1.2&content-type=text/plain |
14 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-backup/bacula/bacula-5.0.1-r2.ebuild?r1=1.1&r2=1.2 |
15 |
|
16 |
Index: bacula-5.0.1-r2.ebuild |
17 |
=================================================================== |
18 |
RCS file: /var/cvsroot/gentoo-x86/app-backup/bacula/bacula-5.0.1-r2.ebuild,v |
19 |
retrieving revision 1.1 |
20 |
retrieving revision 1.2 |
21 |
diff -u -r1.1 -r1.2 |
22 |
--- bacula-5.0.1-r2.ebuild 23 Mar 2010 10:12:39 -0000 1.1 |
23 |
+++ bacula-5.0.1-r2.ebuild 11 May 2010 06:50:19 -0000 1.2 |
24 |
@@ -1,6 +1,6 @@ |
25 |
# Copyright 1999-2010 Gentoo Foundation |
26 |
# Distributed under the terms of the GNU General Public License v2 |
27 |
-# $Header: /var/cvsroot/gentoo-x86/app-backup/bacula/bacula-5.0.1-r2.ebuild,v 1.1 2010/03/23 10:12:39 wschlich Exp $ |
28 |
+# $Header: /var/cvsroot/gentoo-x86/app-backup/bacula/bacula-5.0.1-r2.ebuild,v 1.2 2010/05/11 06:50:19 wschlich Exp $ |
29 |
|
30 |
EAPI="2" |
31 |
inherit eutils multilib |
32 |
@@ -131,6 +131,9 @@ |
33 |
# bug #310087 |
34 |
epatch "${FILESDIR}"/${PV}/${P}-as-needed.patch |
35 |
|
36 |
+ # bug #311161 |
37 |
+ epatch "${FILESDIR}"/${PV}/${P}-lib-search-path.patch |
38 |
+ |
39 |
# switch from -ltermcap to -lncurses. |
40 |
# we have to regenerate the configure script |
41 |
# and eautoreconf does not work due to the |
42 |
|
43 |
|
44 |
|
45 |
1.83 app-backup/bacula/ChangeLog |
46 |
|
47 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-backup/bacula/ChangeLog?rev=1.83&view=markup |
48 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-backup/bacula/ChangeLog?rev=1.83&content-type=text/plain |
49 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-backup/bacula/ChangeLog?r1=1.82&r2=1.83 |
50 |
|
51 |
Index: ChangeLog |
52 |
=================================================================== |
53 |
RCS file: /var/cvsroot/gentoo-x86/app-backup/bacula/ChangeLog,v |
54 |
retrieving revision 1.82 |
55 |
retrieving revision 1.83 |
56 |
diff -u -r1.82 -r1.83 |
57 |
--- ChangeLog 23 Mar 2010 10:12:39 -0000 1.82 |
58 |
+++ ChangeLog 11 May 2010 06:50:19 -0000 1.83 |
59 |
@@ -1,6 +1,17 @@ |
60 |
# ChangeLog for app-backup/bacula |
61 |
# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 |
62 |
-# $Header: /var/cvsroot/gentoo-x86/app-backup/bacula/ChangeLog,v 1.82 2010/03/23 10:12:39 wschlich Exp $ |
63 |
+# $Header: /var/cvsroot/gentoo-x86/app-backup/bacula/ChangeLog,v 1.83 2010/05/11 06:50:19 wschlich Exp $ |
64 |
+ |
65 |
+*bacula-5.0.2 (11 May 2010) |
66 |
+ |
67 |
+ 11 May 2010; Wolfram Schlich <wschlich@g.o> |
68 |
+ +files/5.0.2/bacula-dir.confd, +files/5.0.2/bacula-fd.confd, |
69 |
+ +files/5.0.2/bacula-dir.initd, +files/5.0.2/bacula-fd.initd, |
70 |
+ +files/5.0.2/bacula-5.0.2-as-needed.patch, +files/5.0.2/bacula-sd.confd, |
71 |
+ +files/5.0.2/bacula-5.0.2-lib-search-path.patch, |
72 |
+ +files/5.0.2/bacula-sd.initd, bacula-5.0.1-r2.ebuild, |
73 |
+ +bacula-5.0.2.ebuild: |
74 |
+ version bump |
75 |
|
76 |
*bacula-5.0.1-r2 (23 Mar 2010) |
77 |
|
78 |
|
79 |
|
80 |
|
81 |
1.1 app-backup/bacula/bacula-5.0.2.ebuild |
82 |
|
83 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-backup/bacula/bacula-5.0.2.ebuild?rev=1.1&view=markup |
84 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-backup/bacula/bacula-5.0.2.ebuild?rev=1.1&content-type=text/plain |
85 |
|
86 |
Index: bacula-5.0.2.ebuild |
87 |
=================================================================== |
88 |
# Copyright 1999-2010 Gentoo Foundation |
89 |
# Distributed under the terms of the GNU General Public License v2 |
90 |
# $Header: /var/cvsroot/gentoo-x86/app-backup/bacula/bacula-5.0.2.ebuild,v 1.1 2010/05/11 06:50:19 wschlich Exp $ |
91 |
|
92 |
EAPI="2" |
93 |
inherit eutils multilib |
94 |
|
95 |
IUSE="bacula-clientonly bacula-nodir bacula-nosd ipv6 logwatch mysql postgres python qt4 readline +sqlite3 ssl static tcpd X" |
96 |
# bacula-web bimagemgr brestore bweb |
97 |
KEYWORDS="~amd64 ~hppa ~ppc ~sparc ~x86" |
98 |
|
99 |
DESCRIPTION="Featureful client/server network backup suite" |
100 |
HOMEPAGE="http://www.bacula.org/" |
101 |
|
102 |
MY_PV=${PV/_beta/-b} |
103 |
MY_P=${PN}-${MY_PV} |
104 |
S=${WORKDIR}/${MY_P} |
105 |
#DOC_VER="${MY_PV}" |
106 |
#DOC_SRC_URI="mirror://sourceforge/bacula/${PN}-docs-${DOC_VER}.tar.bz2" |
107 |
#GUI_VER="${PV}" |
108 |
#GUI_SRC_URI="mirror://sourceforge/bacula/${PN}-gui-${GUI_VER}.tar.gz" |
109 |
SRC_URI="mirror://sourceforge/bacula/${MY_P}.tar.gz" |
110 |
# doc? ( ${DOC_SRC_URI} ) |
111 |
# bacula-web? ( ${GUI_SRC_URI} ) |
112 |
# bimagemgr? ( ${GUI_SRC_URI} ) |
113 |
# brestore? ( ${GUI_SRC_URI} ) |
114 |
# bweb? ( ${GUI_SRC_URI} ) |
115 |
|
116 |
LICENSE="GPL-2" |
117 |
SLOT="0" |
118 |
|
119 |
DEPEND=" |
120 |
>=sys-libs/zlib-1.1.4 |
121 |
dev-libs/gmp |
122 |
!bacula-clientonly? ( |
123 |
!bacula-nodir? ( |
124 |
postgres? ( >=virtual/postgresql-server-7.4 ) |
125 |
mysql? ( virtual/mysql ) |
126 |
sqlite3? ( dev-db/sqlite:3 ) |
127 |
virtual/mta |
128 |
) |
129 |
) |
130 |
qt4? ( |
131 |
x11-libs/qt-svg:4 |
132 |
>=x11-libs/qwt-5 |
133 |
) |
134 |
ssl? ( dev-libs/openssl ) |
135 |
logwatch? ( sys-apps/logwatch ) |
136 |
tcpd? ( >=sys-apps/tcp-wrappers-7.6 ) |
137 |
readline? ( >=sys-libs/readline-4.1 ) |
138 |
sys-libs/ncurses |
139 |
python? ( dev-lang/python[threads] )" |
140 |
# doc? ( |
141 |
# app-text/ghostscript-gpl |
142 |
# dev-tex/latex2html[png] |
143 |
# app-text/dvipdfm |
144 |
# ) |
145 |
RDEPEND="${DEPEND} |
146 |
!bacula-clientonly? ( |
147 |
!bacula-nosd? ( |
148 |
sys-block/mtx |
149 |
app-arch/mt-st |
150 |
) |
151 |
)" |
152 |
|
153 |
pkg_setup() { |
154 |
local dbnum |
155 |
declare -i dbnum=0 |
156 |
if ! use bacula-clientonly; then |
157 |
if use mysql; then |
158 |
export mydbtype=mysql |
159 |
let dbnum++ |
160 |
fi |
161 |
if use postgres; then |
162 |
export mydbtype=postgresql |
163 |
let dbnum++ |
164 |
fi |
165 |
if use sqlite3; then |
166 |
export mydbtype=sqlite3 |
167 |
let dbnum++ |
168 |
fi |
169 |
if [[ "${dbnum}" -lt 1 ]]; then |
170 |
eerror |
171 |
eerror "To use ${P} it is required to set a database in the USE flags." |
172 |
eerror "Supported databases are mysql, postgresql, sqlite3" |
173 |
eerror |
174 |
die "No database type selected." |
175 |
elif [[ "${dbnum}" -gt 1 ]]; then |
176 |
eerror |
177 |
eerror "You have set ${P} to use multiple database types." |
178 |
eerror "I don't know which to set as the default!" |
179 |
eerror "You can use /etc/portage/package.use to set per-package USE flags" |
180 |
eerror "Set it so only one database type, mysql, postgres, sqlite3" |
181 |
eerror |
182 |
die "Multiple database types selected." |
183 |
fi |
184 |
fi |
185 |
|
186 |
# create the daemon group and user |
187 |
if [ -z "$(egetent group bacula 2>/dev/null)" ]; then |
188 |
enewgroup bacula || die |
189 |
einfo |
190 |
einfo "The group 'bacula' has been created. Any users you add to this" |
191 |
einfo "group have access to files created by the daemons." |
192 |
einfo |
193 |
fi |
194 |
if ! use bacula-clientonly; then |
195 |
if [ -z "$(egetent passwd bacula 2>/dev/null)" ]; then |
196 |
enewuser bacula -1 -1 /var/lib/bacula bacula,disk,tape,cdrom,cdrw || die |
197 |
einfo |
198 |
einfo "The user 'bacula' has been created. Please see the bacula manual" |
199 |
einfo "for information about running bacula as a non-root user." |
200 |
einfo |
201 |
fi |
202 |
fi |
203 |
} |
204 |
|
205 |
src_prepare() { |
206 |
# adjusts default configuration files for several binaries |
207 |
# to /etc/bacula/<config> instead of ./<config> |
208 |
pushd src >&/dev/null || die |
209 |
for f in console/console.c dird/dird.c filed/filed.c \ |
210 |
stored/bcopy.c stored/bextract.c stored/bls.c \ |
211 |
stored/bscan.c stored/btape.c stored/stored.c \ |
212 |
qt-console/main.cpp; do |
213 |
sed -i -e 's|^\(#define CONFIG_FILE "\)|\1/etc/bacula/|g' "${f}" \ |
214 |
|| die "sed on ${f} failed" |
215 |
done |
216 |
popd >&/dev/null || die |
217 |
|
218 |
# bug #310087 |
219 |
epatch "${FILESDIR}"/${PV}/${P}-as-needed.patch |
220 |
|
221 |
# bug #311161 |
222 |
epatch "${FILESDIR}"/${PV}/${P}-lib-search-path.patch |
223 |
} |
224 |
|
225 |
src_configure() { |
226 |
local myconf='' |
227 |
|
228 |
if use bacula-clientonly; then |
229 |
myconf="${myconf} \ |
230 |
$(use_enable bacula-clientonly client-only) \ |
231 |
$(use_enable static static-fd)" |
232 |
else |
233 |
myconf="${myconf} \ |
234 |
$(use_enable static static-tools) \ |
235 |
$(use_enable static static-fd) \ |
236 |
$(use_enable !bacula-nodir build-dird) \ |
237 |
$(use_enable !bacula-nosd build-stored)" |
238 |
if ! use bacula-nodir; then |
239 |
myconf="${myconf} \ |
240 |
--with-${mydbtype} \ |
241 |
--enable-batch-insert \ |
242 |
$(use_enable static static-dir)" |
243 |
fi |
244 |
if ! use bacula-nosd; then |
245 |
myconf="${myconf} $(use_enable static static-sd)" |
246 |
fi |
247 |
fi |
248 |
|
249 |
if use qt4 && has_version '<x11-libs/qwt-5'; then |
250 |
eerror "x11-libs/qwt found in a version < 5, thus the" |
251 |
eerror "compilation of 'bat' would fail (see" |
252 |
eerror "http://bugs.gentoo.org/188477#c11 for details)." |
253 |
eerror "please either unmerge <x11-libs/qwt-5 or disable" |
254 |
eerror "the qt4 USE flag to disable building 'bat'." |
255 |
die "incompatible slotted qwt version found" |
256 |
fi |
257 |
|
258 |
myconf="${myconf} \ |
259 |
--disable-tray-monitor \ |
260 |
$(use_with X x) \ |
261 |
$(use_enable qt4 bat) \ |
262 |
$(use_enable static static-cons) |
263 |
$(use_with python) \ |
264 |
$(use_enable !readline conio) \ |
265 |
$(use_enable readline) \ |
266 |
$(use_with readline readline /usr) \ |
267 |
$(use_with ssl openssl) \ |
268 |
$(use_enable ipv6) \ |
269 |
$(use_with tcpd tcp-wrappers)" |
270 |
|
271 |
econf \ |
272 |
--libdir=/usr/$(get_libdir) \ |
273 |
--docdir=/usr/share/doc/${PF} \ |
274 |
--with-pid-dir=/var/run \ |
275 |
--sysconfdir=/etc/bacula \ |
276 |
--with-subsys-dir=/var/lock/subsys \ |
277 |
--with-working-dir=/var/lib/bacula \ |
278 |
--with-scriptdir=/usr/libexec/bacula \ |
279 |
--with-dir-user=bacula \ |
280 |
--with-dir-group=bacula \ |
281 |
--with-sd-user=root \ |
282 |
--with-sd-group=bacula \ |
283 |
--with-fd-user=root \ |
284 |
--with-fd-group=bacula \ |
285 |
--enable-smartalloc \ |
286 |
--host=${CHOST} \ |
287 |
${myconf} \ |
288 |
|| die "econf failed" |
289 |
} |
290 |
|
291 |
src_compile() { |
292 |
emake || die "emake failed" |
293 |
|
294 |
# build various GUIs from bacula-gui tarball |
295 |
# if use bacula-web || use bimagemgr || use brestore || use bweb; then |
296 |
# pushd "${WORKDIR}/${PN}-gui-${GUI_VER}" |
297 |
# local myconf_gui='' |
298 |
# if use bimagemgr; then |
299 |
# ## TODO FIXME: webapp-config? !apache? |
300 |
# myconf_gui="${myconf_gui} \ |
301 |
# --with-bimagemgr-cgidir=/var/www/localhost/cgi-bin \ |
302 |
# --with-bimagemgr-docdir=/var/www/localhost/htdocs \ |
303 |
# --with-bimagemgr-binowner=root \ |
304 |
# --with-bimagemgr-bingroup=root \ |
305 |
# --with-bimagemgr-dataowner=apache \ |
306 |
# --with-bimagemgr-datagroup=apache \ |
307 |
# " |
308 |
# fi |
309 |
# ./configure \ |
310 |
# --with-bacula="${S}" \ |
311 |
# ${myconf} \ |
312 |
# || die "configure for bacula-gui failed" |
313 |
# ## TODO FIXME: install files (see bacula-gui.spec) |
314 |
# if use bacula-web; then |
315 |
# : install |
316 |
# fi |
317 |
# if use bimagemgr; then |
318 |
# : install |
319 |
# fi |
320 |
# if use brestore; then |
321 |
# : install |
322 |
# fi |
323 |
# if use bweb; then |
324 |
# : install |
325 |
# fi |
326 |
# popd |
327 |
# fi |
328 |
|
329 |
# build docs from bacula-docs tarball |
330 |
# if use doc; then |
331 |
# pushd "${WORKDIR}/${PN}-docs-${DOC_VER}" |
332 |
# ./configure \ |
333 |
# --with-bacula="${S}" \ |
334 |
# || die "configure for bacula-docs failed" |
335 |
# emake -j1 || die "emake for bacula-docs failed" |
336 |
# popd |
337 |
# fi |
338 |
} |
339 |
|
340 |
src_install() { |
341 |
emake DESTDIR="${D}" install || die "emake install failed" |
342 |
|
343 |
# install bat when enabled (for some reason ./configure doesn't pick this up) |
344 |
if use qt4; then |
345 |
dosbin "${S}"/src/qt-console/.libs/bat || die |
346 |
fi |
347 |
|
348 |
# remove some scripts we don't need at all |
349 |
rm -f "${D}"/usr/libexec/bacula/{bacula,bacula-ctl-dir,bacula-ctl-fd,bacula-ctl-sd,startmysql,stopmysql} |
350 |
|
351 |
# rename statically linked apps |
352 |
if use static; then |
353 |
pushd "${D}"/usr/sbin || die |
354 |
mv static-bacula-fd bacula-fd || die |
355 |
mv static-bconsole bconsole || die |
356 |
if ! use bacula-clientonly; then |
357 |
mv static-bacula-dir bacula-dir || die |
358 |
mv static-bacula-sd bacula-sd || die |
359 |
fi |
360 |
if use qt4; then |
361 |
mv static-bat bat || die |
362 |
fi |
363 |
popd || die |
364 |
fi |
365 |
|
366 |
# extra files which 'make install' doesn't cover |
367 |
if ! use bacula-clientonly; then |
368 |
# the database update scripts |
369 |
diropts -m0750 |
370 |
insinto /usr/libexec/bacula/updatedb |
371 |
insopts -m0754 |
372 |
doins "${S}"/updatedb/* || die |
373 |
fperms 0640 /usr/libexec/bacula/updatedb/README || die |
374 |
|
375 |
# the logrotate configuration |
376 |
# (now unconditional wrt bug #258187) |
377 |
diropts -m0755 |
378 |
insinto /etc/logrotate.d |
379 |
insopts -m0644 |
380 |
newins "${S}"/scripts/logrotate bacula || die |
381 |
|
382 |
# the logwatch scripts |
383 |
if use logwatch; then |
384 |
diropts -m0750 |
385 |
dodir /etc/log.d/scripts/services |
386 |
dodir /etc/log.d/scripts/shared |
387 |
dodir /etc/log.d/conf/logfiles |
388 |
dodir /etc/log.d/conf/services |
389 |
pushd "${S}"/scripts/logwatch >&/dev/null || die |
390 |
emake DESTDIR="${D}" install || die "Failed to install logwatch scripts" |
391 |
popd >&/dev/null || die |
392 |
fi |
393 |
fi |
394 |
|
395 |
# remove unwanted files |
396 |
if use bacula-clientonly; then |
397 |
rm -vf "${D}"/etc/bacula/bconsole.conf |
398 |
rm -vf "${D}"/usr/sbin/bconsole |
399 |
rm -vf "${D}"/usr/libexec/bacula/bconsole |
400 |
fi |
401 |
rm -vf "${D}"/usr/share/man/man1/bacula-bwxconsole.1* |
402 |
if use bacula-clientonly || ! use qt4; then |
403 |
rm -vf "${D}"/usr/share/man/man1/bat.1* |
404 |
fi |
405 |
rm -vf "${D}"/usr/share/man/man1/bacula-tray-monitor.1* |
406 |
if use bacula-clientonly || use bacula-nodir; then |
407 |
rm -vf "${D}"/usr/share/man/man8/bacula-dir.8* |
408 |
rm -vf "${D}"/usr/share/man/man8/dbcheck.8* |
409 |
rm -vf "${D}"/usr/share/man/man1/bsmtp.1* |
410 |
rm -vf "${D}"/usr/libexec/bacula/create_*_database |
411 |
rm -vf "${D}"/usr/libexec/bacula/drop_*_database |
412 |
rm -vf "${D}"/usr/libexec/bacula/make_*_tables |
413 |
rm -vf "${D}"/usr/libexec/bacula/update_*_tables |
414 |
rm -vf "${D}"/usr/libexec/bacula/drop_*_tables |
415 |
rm -vf "${D}"/usr/libexec/bacula/grant_*_privileges |
416 |
rm -vf "${D}"/usr/libexec/bacula/*_catalog_backup |
417 |
fi |
418 |
if use bacula-clientonly || use bacula-nosd; then |
419 |
rm -vf "${D}"/usr/share/man/man8/bacula-sd.8* |
420 |
rm -vf "${D}"/usr/share/man/man8/bcopy.8* |
421 |
rm -vf "${D}"/usr/share/man/man8/bextract.8* |
422 |
rm -vf "${D}"/usr/share/man/man8/bls.8* |
423 |
rm -vf "${D}"/usr/share/man/man8/bscan.8* |
424 |
rm -vf "${D}"/usr/share/man/man8/btape.8* |
425 |
rm -vf "${D}"/usr/libexec/bacula/disk-changer |
426 |
rm -vf "${D}"/usr/libexec/bacula/mtx-changer |
427 |
rm -vf "${D}"/usr/libexec/bacula/dvd-handler |
428 |
fi |
429 |
|
430 |
# documentation |
431 |
ecompress "${D}"/usr/share/doc/${PF}/* |
432 |
# if use doc; then |
433 |
# for i in catalog concepts console developers install problems utility; do |
434 |
# dodoc "${WORKDIR}/${PN}-docs-${DOC_VER}"/manuals/en/${i}/${i}.pdf || die |
435 |
# done |
436 |
# fi |
437 |
|
438 |
# setup init scripts |
439 |
myscripts="bacula-fd" |
440 |
if ! use bacula-clientonly; then |
441 |
if ! use bacula-nodir; then |
442 |
myscripts="${myscripts} bacula-dir" |
443 |
fi |
444 |
if ! use bacula-nosd; then |
445 |
myscripts="${myscripts} bacula-sd" |
446 |
fi |
447 |
fi |
448 |
for script in ${myscripts}; do |
449 |
# copy over init script and config to a temporary location |
450 |
# so we can modify them as needed |
451 |
cp "${FILESDIR}/${PV}/${script}".confd "${T}/${script}".confd || die "failed to copy ${script}.confd" |
452 |
cp "${FILESDIR}/${PV}/${script}".initd "${T}/${script}".initd || die "failed to copy ${script}.initd" |
453 |
# set database dependancy for the director init script |
454 |
case "${script}" in |
455 |
bacula-dir) |
456 |
case "${mydbtype}" in |
457 |
sqlite3) |
458 |
# sqlite3 databases don't have a daemon |
459 |
sed -i -e 's/need "%database%"/:/g' "${T}/${script}".initd || die |
460 |
;; |
461 |
*) |
462 |
# all other databases have daemons |
463 |
sed -i -e "s:%database%:${mydbtype}:" "${T}/${script}".initd || die |
464 |
;; |
465 |
esac |
466 |
;; |
467 |
*) |
468 |
;; |
469 |
esac |
470 |
# install init script and config |
471 |
newinitd "${T}/${script}".initd "${script}" || die |
472 |
newconfd "${T}/${script}".confd "${script}" || die |
473 |
done |
474 |
|
475 |
# make sure the working directory exists |
476 |
diropts -m0750 |
477 |
keepdir /var/lib/bacula |
478 |
|
479 |
# make sure bacula group can execute bacula libexec scripts |
480 |
fowners -R root:bacula /usr/libexec/bacula |
481 |
} |
482 |
|
483 |
pkg_postinst() { |
484 |
if use bacula-clientonly; then |
485 |
fowners root:bacula /var/lib/bacula |
486 |
else |
487 |
fowners bacula:bacula /var/lib/bacula |
488 |
fi |
489 |
|
490 |
if ! use bacula-clientonly && ! use bacula-nodir; then |
491 |
einfo |
492 |
einfo "If this is a new install, you must create the ${mydbtype} databases with:" |
493 |
einfo " /usr/libexec/bacula/create_${mydbtype}_database" |
494 |
einfo " /usr/libexec/bacula/make_${mydbtype}_tables" |
495 |
einfo " /usr/libexec/bacula/grant_${mydbtype}_privileges" |
496 |
einfo |
497 |
echo |
498 |
|
499 |
ewarn |
500 |
ewarn "*** ATTENTION! IMPORTANT! ATTENTION! IMPORTANT! ATTENTION! IMPORTANT! ***" |
501 |
ewarn |
502 |
ewarn "If you're upgrading from a major release, you must upgrade your bacula catalog database." |
503 |
ewarn "Please read the manual chapter for how to upgrade your database." |
504 |
ewarn "You can find database upgrade scripts in /usr/libexec/bacula/updatedb/." |
505 |
ewarn |
506 |
ewarn "*** ATTENTION! IMPORTANT! ATTENTION! IMPORTANT! ATTENTION! IMPORTANT! ***" |
507 |
ewarn |
508 |
ebeep 5 |
509 |
epause 10 |
510 |
echo |
511 |
|
512 |
ewarn |
513 |
ewarn "*** ATTENTION! IMPORTANT! ATTENTION! IMPORTANT! ATTENTION! IMPORTANT! ***" |
514 |
ewarn |
515 |
ewarn "The bundled catalog backup script (/usr/libexec/bacula/make_catalog_backup)" |
516 |
ewarn "is INSECURE. The script needs to be called with the database access password" |
517 |
ewarn "as a command line parameter, thus, the password can be seen from any other" |
518 |
ewarn "user on the system (if not using some non-default hardened/patched kernel" |
519 |
ewarn "with /proc restrictions)!" |
520 |
ewarn |
521 |
ewarn "Our advice is to NOT USE the bundled script at all, but instead use something" |
522 |
ewarn "like this in your catalog backup job definition (example using MySQL as the" |
523 |
ewarn "catalog database):" |
524 |
ewarn |
525 |
ewarn "RunBeforeJob = \"mysqldump --defaults-file=/etc/bacula/my.cnf --opt -f -r /var/lib/bacula/bacula.sql bacula\"" |
526 |
ewarn "RunAfterJob = \"rm -f /var/lib/bacula/bacula.sql\"" |
527 |
ewarn |
528 |
ewarn "This requires you to put all database access parameters (like user, host and" |
529 |
ewarn "password) into a dedicated file (/etc/bacula/my.cnf in this example) which" |
530 |
ewarn "can (and should!) be secured by simple filesystem access permissions." |
531 |
ewarn |
532 |
ewarn "See also:" |
533 |
ewarn "http://www.bacula.org/5.0.x-manuals/en/main/main/Bacula_Security_Issues.html" |
534 |
ewarn "http://www.bacula.org/5.0.x-manuals/en/main/main/Catalog_Maintenance.html#SECTION0043140000000000000000" |
535 |
ewarn |
536 |
ewarn "NOTICE:" |
537 |
ewarn "Since version 5.0.0 Bacula bundles an alternative catalog backup script" |
538 |
ewarn "installed as /usr/libexec/bacula/make_catalog_backup.pl that is not" |
539 |
ewarn "subject to this issue as it parses the director daemon config to extract" |
540 |
ewarn "the configured database connection parameters (including the password)." |
541 |
ewarn |
542 |
ewarn "*** ATTENTION! IMPORTANT! ATTENTION! IMPORTANT! ATTENTION! IMPORTANT! ***" |
543 |
ewarn |
544 |
ebeep 10 |
545 |
epause 20 |
546 |
echo |
547 |
|
548 |
ewarn |
549 |
ewarn "Please note that SQLite v2 support as well as wxwindows (bwx-console)" |
550 |
ewarn "and gnome (gnome-console) support have been dropped from this release." |
551 |
ewarn |
552 |
ebeep 3 |
553 |
epause 5 |
554 |
echo |
555 |
fi |
556 |
|
557 |
ewarn |
558 |
ewarn "*** NOTICE! NOTICE! NOTICE! NOTICE! NOTICE! NOTICE! NOTICE! NOTICE! ***" |
559 |
ewarn |
560 |
ewarn "Support for the bacula all-in-one init script has been removed from" |
561 |
ewarn "a prior release -- if you were previously using the all-in-one init" |
562 |
ewarn "script, please switch to using the individual init scripts now:" |
563 |
ewarn |
564 |
ewarn "- bacula-dir: bacula director (for the central bacula server)" |
565 |
ewarn "- bacula-fd: bacula file daemon (for hosts to be backed up)" |
566 |
ewarn "- bacula-sd: bacula storage daemon (for hosts storing the backup data)" |
567 |
ewarn |
568 |
ewarn "*** NOTICE! NOTICE! NOTICE! NOTICE! NOTICE! NOTICE! NOTICE! NOTICE! ***" |
569 |
ewarn |
570 |
ebeep 5 |
571 |
epause 10 |
572 |
} |