GNU bug report logs -
#49155
[PATCH] gnu: mysql: Support custom data dir.
Previous Next
Reported by: Aljosha Papsch <ep <at> stern-data.com>
Date: Mon, 21 Jun 2021 14:23:01 UTC
Severity: normal
Tags: patch
Done: Marius Bakke <marius <at> gnu.org>
Bug is archived. No further changes may be made.
Full log
Message #10 received at 49155-done <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Hi!
Thanks for the patch, and sorry for the slooow response...
Aljosha Papsch <ep <at> stern-data.com> skriver:
> From: Ellen Papsch <ep <at> stern-data.com>
>
> * gnu/services/databases.scm (mysql-configuration): Add datadir property.
> * gnu/services/databases.scm (mysql-configuration-file): Replace hard coded
> data dir with property from config.
> * gnu/services/databases.scm (%mysql-activation): Remove activation, it runs
> before PID 1. The data dir may reside on a file system not mounted at this
> time.
> * gnu/services/databases.scm (mysql-install-shepherd-service): Create service
> which replaces the activation. Provide mysql-install.
> * gnu/services/databases.scm (mysql-shepherd-service): Move invocation of
> mysqld to mysql-start program-file, because the invocation gotten more
> complex. Require mysql-install.
> * gnu/services/databases.scm (mysql-start): Invoke mysqld only if a lock file
> appears.
> * gnu/services/databases.scm (mysql-shepherd-services): Prepend the install
> service before the normal service.
> * gnu/services/databases.scm (mysql-upgrade-wrapper): Increase timeout to
> 20s to let the mysql install procedure finish.
I have finally applied this patch, along with a follow-up commit to make
the mysql-upgrade service also work with a custom datadir.
I also ended up dropping the 'mysql-install' service in favor of a
mysqld wrapper script that calls the mysql-install script at startup
when the "mysql" DB is missing.
Pushed in c7b266fdf2754c139803c156677bf2828c78d072.
[signature.asc (application/pgp-signature, inline)]
This bug report was last modified 2 years and 268 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.