Letsencrypt-auto fails


#1

Hello!

A cronjob is runninnt every day at a certain time executing
/usr/bin/letsencrypt-auto renew >> /var/log/le-renew.log

Today I found this in the logfile:

2018-10-22 10:40:12,566:DEBUG:certbot.main:certbot version: 0.27.0
2018-10-22 10:40:12,567:DEBUG:certbot.main:Arguments: [’–version’]
2018-10-22 10:40:12,567:DEBUG:certbot.main:Discovered plugins: PluginsRegistry(PluginEntryPoint#apache,PluginEntryPoint#manual,PluginEntryPoint#nginx,PluginEntryPoint#null,PluginEntryP
oint#standalone,PluginEntryPoint#webroot)
2018-10-22 10:40:12,577:DEBUG:certbot.log:Exiting abnormally:
Traceback (most recent call last):
File “/opt/eff.org/certbot/venv/bin/letsencrypt”, line 11, in
sys.exit(main())
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot/main.py”, line 1345, in main
args = cli.prepare_and_parse_args(plugins, cli_args)
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot/cli.py”, line 1243, in prepare_and_parse_args
_plugins_parsing(helpful, plugins)
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot/cli.py”, line 1458, in _plugins_parsing
helpful.add_plugin_args(plugins)
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot/cli.py”, line 840, in add_plugin_args
plugin_ep.plugin_cls.inject_parser_options(parser_or_group, name)
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot/plugins/common.py”, line 81, in inject_parser_options
return cls.add_parser_arguments(add)
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot_apache/configurator.py”, line 159, in add_parser_arguments
a2018-10-22 10:40:12,566:DEBUG:certbot.main:certbot version: 0.27.0
2018-10-22 10:40:12,567:DEBUG:certbot.main:Arguments: [’–version’]
2018-10-22 10:40:12,567:DEBUG:certbot.main:Discovered plugins: PluginsRegistry(PluginEntryPoint#apache,PluginEntryPoint#manual,PluginEntryPoint#nginx,PluginEntryPoint#null,PluginEntryP
oint#standalone,PluginEntryPoint#webroot)
2018-10-22 10:40:12,577:DEBUG:certbot.log:Exiting abnormally:
Traceback (most recent call last):
File “/opt/eff.org/certbot/venv/bin/letsencrypt”, line 11, in
sys.exit(main())
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot/main.py”, line 1345, in main
args = cli.prepare_and_parse_args(plugins, cli_args)
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot/cli.py”, line 1243, in prepare_and_parse_args
_plugins_parsing(helpful, plugins)
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot/cli.py”, line 1458, in _plugins_parsing
helpful.add_plugin_args(plugins)
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot/cli.py”, line 840, in add_plugin_args
plugin_ep.plugin_cls.inject_parser_options(parser_or_group, name)
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot/plugins/common.py”, line 81, in inject_parser_options
return cls.add_parser_arguments(add)
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot_apache/configurator.py”, line 159, in add_parser_arguments
add(“handle-modules”, default=cls.OS_DEFAULTS[“handle_modules”],
KeyError: ‘handle_modules’
2018-10-22 10:40:12,577:ERROR:certbot.log:An unexpected error occurred:dd(“handle-modules”, default=cls.OS_DEFAULTS[“handle_modules”],
KeyError: ‘handle_modules’
2018-10-22 10:40:12,577:ERROR:certbot.log:An unexpected error occurred:

Don’t know what’s wrong. Can somebody help?


#2

One more time:

2018-10-22 13:23:29,879:DEBUG:certbot.main:certbot version: 0.27.0
2018-10-22 13:23:29,880:DEBUG:certbot.main:Arguments: []
2018-10-22 13:23:29,880:DEBUG:certbot.main:Discovered plugins: PluginsRegistry(PluginEntryPoint#apache,PluginEntryPoint#manual,PluginEntryPoint#nginx,PluginEntryPoint#null,PluginEntryP
oint#standalone,PluginEntryPoint#webroot)
2018-10-22 13:23:29,892:DEBUG:certbot.log:Exiting abnormally:
Traceback (most recent call last):
File “./certbot”, line 11, in
sys.exit(main())
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot/main.py”, line 1345, in main
args = cli.prepare_and_parse_args(plugins, cli_args)
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot/cli.py”, line 1243, in prepare_and_parse_args
_plugins_parsing(helpful, plugins)
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot/cli.py”, line 1458, in _plugins_parsing
helpful.add_plugin_args(plugins)
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot/cli.py”, line 840, in add_plugin_args
plugin_ep.plugin_cls.inject_parser_options(parser_or_group, name)
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot/plugins/common.py”, line 81, in inject_parser_options
return cls.add_parser_arguments(add)
File “/opt/eff.org/certbot/venv/lib/python2.7/site-packages/certbot_apache/configurator.py”, line 159, in add_parser_arguments
add(“handle-modules”, default=cls.OS_DEFAULTS[“handle_modules”],
KeyError: ‘handle_modules’
2018-10-22 13:23:29,892:ERROR:certbot.log:An unexpected error occurred:

The certificates expire in four days. Now how do I get new ones, when certbot fails?


#3

It seams to be that issue: Error during renewal : KeyError: 'handle_modules' / https://github.com/certbot/certbot/issues/6344

It’s fixed in Certbot 0.27.1 (and yours is 0.27.0)


#4

Thank you so much! This fixed my issue.