Weekly renew failed, but success if run from shell

Hi,

OS: FreeBSD 12.2-RELEASE-p6 GENERIC amd64

Apache installed using pkg: apache24-2.4.46_2

Certbot installed using pkg: py37-certbot-1.14.0,1, py37-certbot-apache-1.14.0

/etc/periodic.conf:
weekly_certbot_enable="YES"
weekly_certbot_service="apache24"

When I run certbot renew, everything went fine, all certs renewed. However when initiated by periodic/weekly, it said:

Error while running apachectl graceful.
apache24 not running? (check /var/run/httpd.pid).

...right after challenges performed.

Of course I can run apachectl graceful manually without any errors. What did I miss?

Thanks!

1 Like

Welcome to the Let's Encrypt Community, Albert :slightly_smiling_face:

Are you meaning apachectl -k graceful ?

https://httpd.apache.org/docs/current/programs/apachectl.html

Are you using a --pre-hook in certbot to stop apache (e.g. apachectl -k stop) then using the webroot authenticator?

Does apachectl -S show any problems?

No. I did not touch prehook or posthook whatsoever. Just as the periodic.conf as mentioned before.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.