Renew client not running in cron


#1

Hi,

I have searched for the same issue, but not found any like it yet, so i try to post it here…

I use this command to manualy update my sertificate:

 letsencrypt-auto --renew-by-default --redirect -d www.domain.com,domain.com

but when i put it in a cron job, nothing happens and there is no indication of it running in cron log, systemlog or letsencrypt log…

the crontab look like this:
0 0 1 * * /letsencrypt/letsencrypt-auto --renew-by-default --redirect -d www.domain.com,domain.com

I have tryed to put in in a script and set the script to run as a cronjob, but same thing happens…

Other cron jobs runs perfectly and are logged…

Any ideas?


#2

That’s only running on the 1st of the month at midnight. Are you looking back far enough in the logs ?


#3

Hi,

Yes, i tried to alter the date of the month to tomorrow each day i tested and tried to run it every minute for a while, but stil no luck… :frowning:


#4

Have you got it set to email you any output ? (set at the top of the cron job usually).

Is the /letsencrypt folder really directly of root ?


#5

Is the /letsencrypt folder really directly of root ? - What you mean?

ah… the mailto=“xxx”, i’ll test it when i get back home from work… :slight_smile:


#6

You have it as

/letsencrypt/letsencrypt-auto

rather than

/home/user//letsencrypt/letsencrypt-auto

hence just checking that the path is correct.

Yes, that’s the one :slight_smile: although if you are seeing nothing in the logs that sounds more of a cron issue, rather than one of not being able to find the file or anything.


#7

Yes it’s located at the root. :slight_smile:

the path is correct and i can run the /letsencrypt/letsencrypt-auto manualy with the same path.

when i put root in the mailto, i got this line in syslog:

Jan 6 18:12:01 ubuntu CRON[24145]: (root) CMD (/letsencrypt/letsencrypt-auto --renew-by-default --redirect -d www.domain.com,domain.com)

but there is no log in letsencrypts log…

now i found the mail where this was sendt to me:

Updating letsencrypt and virtual environment dependencies…
Requesting root privileges to run with virtualenv: /root/.local/share/letsencrypt/bin/letsencrypt --renew-by-default --redirect -d www.domain.com,domain.com
No installers seem to be present and working on your system; fix that or try running letsencrypt with the “certonly” command

tryed to run the same line but with certonly, but still nothing loged in letsencrypt’s log. same mail stil comming to root…

is there anything i have missed in the instalation?