Bug 277598 - databases/mysql81-server: failed to start after pkg install
Summary: databases/mysql81-server: failed to start after pkg install
Status: New
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Jochen Neumeister
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-03-09 16:22 UTC by Denis Shaposhnikov
Modified: 2024-03-10 13:46 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (joneum)


Attachments
the fix (555 bytes, patch)
2024-03-10 13:46 UTC, Denis Shaposhnikov
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Denis Shaposhnikov 2024-03-09 16:22:46 UTC
Hi,

after `pkg install mysql81-server`, `service mysql-server start` failed to start the server. In the log I see

mysqld: Can't create/write to file '/var/db/mysql_tmpdir/ibe7JpUJ' (OS errno 13 - Permission denied)

And I see `/var/db/mysql_tmpdir` owned by root, instead of mysql user. Looks like the reason is pkg-plist, which has

@dir %%ETCDIR%%/keyring
@dir %%MY_SECDIR%%
@dir %%MY_TMPDIR%%

instead of

@dir(mysql,mysql,0750) %%ETCDIR%%/keyring
@dir(mysql,mysql,0750) %%MY_SECDIR%%
@dir(mysql,mysql,0750) %%MY_TMPDIR%%

like `databases/mysql80-server` has.
Comment 1 Denis Shaposhnikov 2024-03-10 13:46:43 UTC
Created attachment 249072 [details]
the fix