From: dashezup <dashezup@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: [ISSUE] mariadb "operation not permitted" error while installing
Date: Sun, 16 May 2021 16:33:02 +0200 [thread overview]
Message-ID: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-30932@inbox.vuxu.org> (raw)
[-- Attachment #1: Type: text/plain, Size: 2200 bytes --]
New issue by dashezup on void-packages repository
https://github.com/void-linux/void-packages/issues/30932
Description:
<!-- Don't request update of package. We have a script for that. https://alpha.de.repo.voidlinux.org/void-updates/void-updates.txt . However, a quality pull request may help. -->
### System
* xuname:
`Void 5.11.12_1 x86_64 GenuineIntel notuptodate FFFFF`
* package:
`mariadb-10.5.9_1`
### Expected behavior
install mariadb without showing errors.
### Actual behavior
shows this error because the INSTALL script runs `mysql_install_db` with mysql user which runs `chown`
```
chown: changing ownership of '/usr/lib/mysql/plugin/auth_pam_tool_dir/auth_pam_tool': Operation not permitted
Couldn't set an owner to '/usr/lib/mysql/plugin/auth_pam_tool_dir/auth_pam_tool'.
It must be root, the PAM authentication plugin doesn't work otherwise..
chown: changing ownership of '/usr/lib/mysql/plugin/auth_pam_tool_dir': Operation not permitted
Cannot change ownership of the '/usr/lib/mysql/plugin/auth_pam_tool_dir' directory
to the 'mysql' user. Check that you have the necessary permissions and try again.
```
### Steps to reproduce the behavior
`xbps-install mariadb`
### Solutions
1. run `mysql_install_db` with root instead of mysql in INSTALL script, it would be like this https://github.com/dashezup/void-packages/commit/4689aa1a92b8e3361213a93386075a4a0ed05ca5
btw I'm a bit confused about the `UPDATE` variable for INSTALL script
> $UPDATE: set to yes if package is being upgraded, no if package is being installed or removed.
so how did it not being triggered when the package was "removed"? (I know it shouldn't)
2. not run `mysql_install_db` at all. may mention the command in INSTALL.msg, and may include one for update as well just like what [the arch linux package do](https://github.com/archlinux/svntogit-packages/blob/packages/mariadb/trunk/mariadb.install)
3. `chown mysql:mysql /usr/lib/mysql/plugin/auth_pam_tool_dir/auth_pam_tool /usr/lib/mysql/plugin/auth_pam_tool_dir` in post_install() or somewhere else, so that the mysql user will be able to chown for that two files.
@Veganizer hey check this
next reply other threads:[~2021-05-16 14:33 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-16 14:33 dashezup [this message]
2021-05-17 4:30 ` Veganizer
2021-05-29 19:17 ` [ISSUE] [CLOSED] " Johnnynator
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-30932@inbox.vuxu.org \
--to=dashezup@users.noreply.github.com \
--cc=ml@inbox.vuxu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).