Letsencrypt could not find usable nginx binary

Hi,

I can sucessfully execute a --dry-run. But when using cron it fails with the error below along with python errors. My $PATH is setup fine. /sbin/nginx. My nginx configs are also ok and successful.

My domain is: revbill.dynu.net

I ran this command: cerbot renew -q >> /var/log/cron 2>&1

It produced this output: “letsencrypt could not find usable nginx binary” and python2.7/main.py errors.

My web server is (include version): Nginx 1.16.1

The operating system my web server runs on is (include version): Centos 7

My hosting provider, if applicable, is: n/a

I can login to a root shell on my machine (yes or no, or I don’t know): Yes

I’m using a control panel to manage my site (no, or provide the name and version of the control panel): No! I am using a local VM on PC.

The version of my client is (e.g. output of certbot --version or certbot-auto --version if you’re using Certbot): 1.0.0

Thank you!

1 Like

CRON has its’ own PATH (which may differ).
Also, please confirm (and show us) the active nginx file location:
which nginx

3 Likes

Indeed. I discovered via my resarch CRON has it’s own PATH. Having input the PATH into CRON it now works as intended.

Thank you!

2 Likes

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