B
B
brar2020-04-21 23:32:17
linux
brar, 2020-04-21 23:32:17

Why did the /run/php directory stop being created after a reboot?

Debian 10 OS.
Haven't rebooted the server for about a month. Reloaded today.
php-fpm stopped working. Digging through the logs, I realized that he could not create a directory for himself in /run/.

I do:
mkdir /run/php && systemctl reststart php7.3-fpm
Everything starts. But since the system deletes everything in /run on reboot, the php directory is not created after the reboot.

At the same time, I did not change anything in the configs for a long time. After the kernel updates rebooted the server, everything started.
The only thing I sin on is updates during the last month. But on the other hand, this is debian, not arch or gentoo, to break it like that.

I found a solution - add a line to the php7.3-fpm.service unit:
RuntimeDirectory=php

Everything is working. But the question still remains why this happened. Indeed, quite after some future update, the php7.3-fpm.service unit file will be overwritten.

Answer the question

In order to leave comments, you need to log in

3 answer(s)
S
Sanes, 2020-04-21
@Sanes

Could this be related?
ISPmanager deletes /var/run/mariadb after server restart?

S
Sergey, 2020-04-21
@KingstonKMS

The user under which the unit is running does not have write permissions to /run

P
pfg21, 2020-04-21
@pfg21

finish the systemd.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question