Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 13 May 2004 21:15:13 -0400
From:      Michael Edenfield <kutulu@kutulu.org>
To:        Ben Bangert <ben@knowledgetap.com>
Cc:        Lars.Koeller@Uni-Bielefeld.DE
Subject:   Re: FreeBSD Port: bacula-1.32f5 updating destroys prior bacula conf files
Message-ID:  <20040514011513.GA51312@wombat.localnet>
In-Reply-To: <7DEC7598-A53D-11D8-AFB0-0003937C4014@knowledgetap.com>
References:  <7DEC7598-A53D-11D8-AFB0-0003937C4014@knowledgetap.com>

next in thread | previous in thread | raw e-mail | index | archive | help

--PNTmBPCT7hxwcZjr
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

* Ben Bangert <ben@knowledgetap.com> [040513 20:28]:
> Ummmmm
>=20
> I ran portupgrade the other day on bacula. Christ was that a mistake. I=
=20
> had the absurd idea that as portupgrade has always done with every port=
=20
> thus upgraded, it would save a copy of the conf files for the port.=20
> Prolly to .old or something.

If upgrading the port removed your config files, then the port is most
likely to blame, not portupgrade.  The only backups (AFAIK) that
portupgrade keeps are old shared libraries, and if requested, a backup
of the old packages.

The way most ports work (and SHOULD work), the port installs a "sample"
copy of the config files as filename.conf.{sample,dist,default,etc}.  If
there is no live copy of the config file present, and a config file is
required, this sample is copied over.  Since the live config file is
never part of the pkg-plist, it doesn't get removed during a pkg_delete
or make deinstall.

The bacula port looks like it does the exact opposite, for some reason.
It includes the following in it's post-install target:

        if [ -f ${PREFIX}/etc/bconsole.conf.new ]; then \
                ${ECHO_CMD} "etc/console.conf.new" >> ${TMPPLIST}; \
        elif [ -f ${PREFIX}/etc/bconsole.conf ]; then \
                ${MV} ${PREFIX}/etc/bconsole.conf ${PREFIX}/etc/bconsole.co=
nf.sample; \
                ${ECHO_CMD} "etc/bconsole.conf.sample" >> ${TMPPLIST}; \
        fi

If I'm reading that correctly, if there's an existing config file it
will get moved out of the way on upgrade, and then (since it's now in
the pkg-plist), REMOVED on uninstall. =20

--Mike

--PNTmBPCT7hxwcZjr
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (FreeBSD)

iD8DBQFApB2hCczNhKRsh48RAsuMAJ9wTih7dODvESfS5LVBSkfcxxuIuwCgrJDo
H93nZXdw8M99zstbr245wso=
=3SLt
-----END PGP SIGNATURE-----

--PNTmBPCT7hxwcZjr--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040514011513.GA51312>