Skip to content

mariadb: explict pid file for mysqld.init - #30488

Open
grooverdan wants to merge 1 commit into
openwrt:masterfrom
grooverdan:patch-1
Open

mariadb: explict pid file for mysqld.init#30488
grooverdan wants to merge 1 commit into
openwrt:masterfrom
grooverdan:patch-1

Conversation

@grooverdan

Copy link
Copy Markdown
Contributor

📦 Package Details

Maintainer: @miska

Description:

With MariaDB upstream MDEV-37284 I hope to change pid-file to having a default value of an empty string. That won't work for the current init file.

Explicitly set the pid-file to a filename inside the same directory as the default socket.

Fixing this eliminates the only findable implementation that used the default pid-file value and its hostname based name rather than an explicit value.


🧪 Run Testing Details

  • OpenWrt Version:
  • OpenWrt Target/Subtarget:
  • OpenWrt Device:

✅ Formalities

  • I have reviewed the CONTRIBUTING.md file for detailed contributing guidelines.

If your PR contains a patch:

  • It can be applied using git am
  • It has been refreshed to avoid offsets, fuzzes, etc., using
    make package/<your-package>/refresh V=s
  • [N/A] It is structured in a way that it is potentially upstreamable
    (e.g., subject line, commit description, etc.)
    We must try to upstream patches to reduce maintenance burden.

@openwrt

openwrt Bot commented Sep 9, 2026

Copy link
Copy Markdown

Formality Check: Suggestions Available

We checked this pull request against the contribution guidelines. Here is what needs your attention:

⚠️ STYLISTIC WARNINGS & SUGGESTIONS

Package Release Audit:

  • ⚠️ Content changed in these packages, but without a PKG_RELEASE or version bump:

    • utils/mariadb

    Increment PKG_RELEASE by 1 (or bump PKG_VERSION/PKG_SOURCE_DATE and reset PKG_RELEASE to 1) so users receive the update.

Do not increment release for minor changes. Cosmetic edits (e.g., typos in comments, copyright updates, formatting/whitespace), changing the package maintainer (PKG_MAINTAINER), or updating source download info (PKG_SOURCE_URL / PKG_HASH) do not require incrementing PKG_RELEASE.


Something broken? Consider reporting an issue.
Running version 059e3de deployed on 2026-09-09 11:53:18 CEST

@openwrt-ai openwrt-ai left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed 1 new commit; see the inline comment.


Generated by Claude Code

Comment thread utils/mariadb/files/mysqld.init Outdated

@openwrt-ai openwrt-ai left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Commit checks

  • bdd77022 "mariadb: explict pid file for mysqld.init" — subject typo: explictexplicit.
  • bdd77022 — body sentence "I hope have pid-file having a default value of an empty string" is ungrammatical; the PR body's phrasing ("I hope to change pid-file to having a default value of an empty string") reads correctly.

Generated by Claude Code

Comment thread utils/mariadb/files/mysqld.init Outdated
Comment thread utils/mariadb/files/mysqld.init Outdated
With MariaDB upstream
[MDEV-37284](https://jira.mariadb.org/browse/MDEV-37284) I hope have
pid-file having a default value of an empty string. That won't work for
the current init file.

If there isn't a pid-file specified in the configuration, fall back to
explicitly set the pid-file to a filename inside the same directory as
the default socket.

Fixing this eliminates the only discoverable implementation that used
the default pid-file value and its hostname based name rather than an
explicit value.

Signed-off-by: Daniel Black <daniel@mariadb.org>

@openwrt-ai openwrt-ai left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Commit checks

  • 2c746070 — body says "If there isn't a pid-file specified in the configuration, fall back to ...", but the code falls back only when mysqld --help --verbose reports an empty pid-file, which it cannot distinguish from a configured one; today it always reports the hostname-based built-in default, so the fallback is unreachable until MDEV-37284 lands and the "eliminates ... its hostname based name" claim does not hold yet. Reword to describe the empty-default condition.

Generated by Claude Code

Comment on lines 17 to 18

pidfile=""

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: dropping pidfile="" makes mariadb_get_pidfile's [ -z "$pidfile" ] guard honour a pidfile inherited from the caller's environment, which then lands in --pid-file=; it also leaves a stray double blank line here (and another at lines 28-29).

Suggested change
pidfile=""
pidfile=""

Generated by Claude Code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants