[Fedora-packaging] Upgrading databases as part of the RPM postinst script?

Gianluca Sforna giallu at gmail.com
Wed May 9 08:28:39 UTC 2007


On 08 May 2007 15:30:09 -0500, Jason L Tibbitts III <tibbs at math.uh.edu> wrote:
> >>>>> "MV" == Maxim Veksler <hq4ever at gmail.com> writes:
>
> MV> As part of the software (binaries) upgrade process my rpm will
> MV> need to update database scheme (and possibly some configurations
> MV> data) inside a mysql database.
>
> I would recommend not even attempting to do that kind of thing.  How
> do you know the database is running at the time, or even that it's on
> the same machine?

That is quite the same situation I am facing right now with mantis: in
older releases, users was forced to browse a specific page to update
the schema.
Now I proposed upstream the addition of a script for performing the
same updates from the command line, so I could add it in a scriptlet:
of course it could fail for many reasons, but if you have a working
installation then the configuration files has all the information
required to connect to the database.

I don't know if a similar solution is applicable at all in your
situation, because it mostly depends on how the schema update is
implemented upstream




More information about the packaging mailing list