Deluge daemon fails to start with rpcserver error

General support for problems installing or using Deluge
StarNamer
New User
New User
Posts: 3
Joined: Mon Aug 27, 2018 10:20 pm

Deluge daemon fails to start with rpcserver error

Post by StarNamer »

I've been running a Deluge daemon for a couple of years, but recently noticed it had stopped and when I tried to start it, it doesn't.

The log file (/var/log/deluge/daemon.log) contains the single line:

Code: Select all

[ERROR   ] 23:11:00 rpcserver:378 [('SSL routines', 'SSL_CTX_use_certificate', 'ee key too small')]
I've tried uninstalling (with purge) and reinstalling, but with no change. I suspect the "purge" didn't actually clear the config.

What the simplest way to fix, hopefully without losing the current history?

Thanks
shamael
Compulsive Poster
Compulsive Poster
Posts: 667
Joined: Sat Oct 08, 2016 9:28 am

Re: Deluge daemon fails to start with rpcserver error

Post by shamael »

Deluge/Libtorrent version?
Have you tried to set the loggin to debug level? So far the msg doen't ring a bell but maybe with more details...
StarNamer
New User
New User
Posts: 3
Joined: Mon Aug 27, 2018 10:20 pm

Re: Deluge daemon fails to start with rpcserver error

Post by StarNamer »

Deluged version (from the daemon.log) is 1.3.15.

The debug log has a message "Daemon already running or port not available", but "netstat -a | grep 58846" shows nothing using the port. "ps ax|grep del" finds deluge-web but nothing else.

Code: Select all

[INFO    ] 18:56:41 daemon:127 Deluge daemon 1.3.15
[DEBUG   ] 18:56:41 daemon:128 options: {'profile': False, 'read_only_config_keys': None, 'loglevel': 'debug', 'quiet': False, 'ui_interface': None, 'listen_interface': None, 'logfile': '/var/log/deluge/daemon.log', 'config': None, 'port': None, 'pidfile': None, 'donot': True}
[DEBUG   ] 18:56:41 daemon:129 args: []
[DEBUG   ] 18:56:41 core:78 Core init..
[DEBUG   ] 18:56:41 core:84 read_only_config_keys: []
[INFO    ] 18:56:41 core:87 Starting libtorrent 1.1.5.0 session..
[DEBUG   ] 18:56:41 configmanager:111 Getting config 'core.conf'
[DEBUG   ] 18:56:41 config:199 Setting 'info_sent' to 0.0 of <type 'float'>
[DEBUG   ] 18:56:41 config:199 Setting 'lsd' to True of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'send_info' to False of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'move_completed_path' to /var/lib/deluge/Downloads of <type 'str'>
[DEBUG   ] 18:56:41 config:199 Setting 'enc_in_policy' to 1 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'queue_new_to_top' to False of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'ignore_limits_on_local_network' to True of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'rate_limit_ip_overhead' to True of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'daemon_port' to 58846 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'torrentfiles_location' to /var/lib/deluge/Downloads of <type 'str'>
[DEBUG   ] 18:56:41 config:199 Setting 'max_active_limit' to 8 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'utpex' to True of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'max_active_downloading' to 3 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'max_active_seeding' to 5 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'allow_remote' to False of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'max_half_open_connections' to 50 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'download_location' to /var/lib/deluge/Downloads of <type 'str'>
[DEBUG   ] 18:56:41 config:199 Setting 'compact_allocation' to False of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'max_upload_speed' to -1.0 of <type 'float'>
[DEBUG   ] 18:56:41 config:199 Setting 'cache_expiry' to 60 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'prioritize_first_last_pieces' to False of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'auto_managed' to True of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'enc_level' to 2 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'max_connections_per_second' to 20 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'dont_count_slow_torrents' to False of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'random_outgoing_ports' to True of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'dht' to True of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'new_release_check' to False of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'enc_out_policy' to 1 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'max_upload_slots_global' to 4 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'seed_time_limit' to 180 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'cache_size' to 512 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'share_ratio_limit' to 2.0 of <type 'float'>
[DEBUG   ] 18:56:41 config:199 Setting 'max_download_speed' to -1.0 of <type 'float'>
[DEBUG   ] 18:56:41 config:199 Setting 'geoip_db_location' to /usr/share/GeoIP/GeoIP.dat of <type 'str'>
[DEBUG   ] 18:56:41 config:199 Setting 'natpmp' to True of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'stop_seed_at_ratio' to False of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'peer_tos' to 0x00 of <type 'str'>
[DEBUG   ] 18:56:41 config:199 Setting 'listen_interface' to  of <type 'str'>
[DEBUG   ] 18:56:41 config:199 Setting 'upnp' to True of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'max_download_speed_per_torrent' to -1 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'outgoing_ports' to [0, 0] of <type 'list'>
[DEBUG   ] 18:56:41 config:199 Setting 'enabled_plugins' to [] of <type 'list'>
[DEBUG   ] 18:56:41 config:199 Setting 'random_port' to True of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'autoadd_enable' to False of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'max_connections_global' to 200 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'enc_prefer_rc4' to True of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'listen_ports' to [6881, 6891] of <type 'list'>
[DEBUG   ] 18:56:41 config:199 Setting 'max_upload_slots_per_torrent' to -1 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'stop_seed_ratio' to 2.0 of <type 'float'>
[DEBUG   ] 18:56:41 config:199 Setting 'seed_time_ratio_limit' to 7.0 of <type 'float'>
[DEBUG   ] 18:56:41 config:199 Setting 'max_upload_speed_per_torrent' to -1 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'copy_torrent_file' to False of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'del_copy_torrent_file' to False of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'move_completed' to False of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'proxies' to {'peer': {'username': '', 'password': '', 'hostname': '', 'type': 0, 'port': 8080}, 'web_seed': {'username': '', 'password': '', 'hostname': '', 'type': 0, 'port': 8080}, 'tracker': {'username': '', 'password': '', 'hostname': '', 'type': 0, 'port': 8080}, 'dht': {'username': '', 'password': '', 'hostname': '', 'type': 0, 'port': 8080}} of <type 'dict'>
[DEBUG   ] 18:56:41 config:199 Setting 'add_paused' to False of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'max_connections_per_torrent' to -1 of <type 'int'>
[DEBUG   ] 18:56:41 config:199 Setting 'remove_seed_at_ratio' to False of <type 'bool'>
[DEBUG   ] 18:56:41 config:199 Setting 'autoadd_location' to /var/lib/deluge/Downloads of <type 'str'>
[DEBUG   ] 18:56:41 config:199 Setting 'plugins_location' to /var/lib/deluge/.config/deluge/plugins of <type 'str'>
[DEBUG   ] 18:56:41 config:394 Config /var/lib/deluge/.config/deluge/core.conf version: 1.1 loaded: {'info_sent': 0.0, 'lsd': True, 'send_info': True, 'move_completed_path': u'/var/lib/deluge/Downloads', 'enc_in_policy': 1, 'queue_new_to_top': False, 'ignore_limits_on_local_network': False, 'rate_limit_ip_overhead': True, 'daemon_port': 58846, 'natpmp': True, 'max_active_limit': -1, 'utpex': True, 'max_active_downloading': 8, 'max_active_seeding': -1, 'allow_remote': False, 'max_half_open_connections': 50, 'download_location': u'/var/lib/deluge/Downloads', 'compact_allocation': False, 'max_upload_speed': 50.0, 'cache_expiry': 60, 'prioritize_first_last_pieces': False, 'auto_managed': True, 'enc_level': 2, 'max_connections_per_second': 20, 'dont_count_slow_torrents': True, 'random_outgoing_ports': True, 'max_upload_slots_per_torrent': -1, 'new_release_check': True, 'enc_out_policy': 1, 'outgoing_ports': [0, 0], 'seed_time_limit': 180, 'cache_size': 512, 'share_ratio_limit': 2.0, 'max_download_speed': -1.0, 'geoip_db_location': u'/usr/share/GeoIP/GeoIP.dat', 'torrentfiles_location': u'/var/lib/deluge/Downloads', 'stop_seed_at_ratio': True, 'peer_tos': u'0x00', 'listen_interface': u'', 'upnp': True, 'max_download_speed_per_torrent': -1, 'max_upload_slots_global': 4, 'enabled_plugins': [], 'random_port': False, 'autoadd_enable': False, 'max_connections_global': -1, 'enc_prefer_rc4': True, 'listen_ports': [6881, 6891], 'dht': True, 'stop_seed_ratio': 2.0, 'seed_time_ratio_limit': 7.0, 'max_upload_speed_per_torrent': -1, 'copy_torrent_file': False, 'del_copy_torrent_file': False, 'move_completed': False, 'proxies': {u'peer': {u'username': u'', u'password': u'', u'type': 0, u'hostname': u'', u'port': 8080}, u'web_seed': {u'username': u'', u'password': u'', u'type': 0, u'hostname': u'', u'port': 8080}, u'tracker': {u'username': u'', u'password': u'', u'type': 0, u'hostname': u'', u'port': 8080}, u'dht': {u'username': u'', u'password': u'', u'type': 0, u'hostname': u'', u'port': 8080}}, 'add_paused': False, 'max_connections_per_torrent': -1, 'remove_seed_at_ratio': False, 'autoadd_location': u'/var/lib/deluge/Downloads', 'plugins_location': u'/var/lib/deluge/.config/deluge/plugins'}
[DEBUG   ] 18:56:41 alertmanager:53 AlertManager initialized..
[DEBUG   ] 18:56:41 pluginmanagerbase:65 Plugin manager init..
[DEBUG   ] 18:56:41 configmanager:111 Getting config 'core.conf'
[DEBUG   ] 18:56:41 pluginmanagerbase:124 Found plugin: Extractor 0.6 at /usr/lib/python2.7/dist-packages/deluge/plugins/Extractor-0.6.egg
[DEBUG   ] 18:56:41 pluginmanagerbase:124 Found plugin: Execute 1.3 at /usr/lib/python2.7/dist-packages/deluge/plugins/Execute-1.3.egg
[DEBUG   ] 18:56:41 pluginmanagerbase:124 Found plugin: Blocklist 1.3 at /usr/lib/python2.7/dist-packages/deluge/plugins/Blocklist-1.3.egg
[DEBUG   ] 18:56:41 pluginmanagerbase:124 Found plugin: AutoAdd 1.5 at /usr/lib/python2.7/dist-packages/deluge/plugins/AutoAdd-1.5.egg
[DEBUG   ] 18:56:41 pluginmanagerbase:124 Found plugin: Label 0.2 at /usr/lib/python2.7/dist-packages/deluge/plugins/Label-0.2.egg
[DEBUG   ] 18:56:41 pluginmanagerbase:124 Found plugin: Notifications 0.2 at /usr/lib/python2.7/dist-packages/deluge/plugins/Notifications-0.2.egg
[DEBUG   ] 18:56:41 pluginmanagerbase:124 Found plugin: WebUi 0.1 at /usr/lib/python2.7/dist-packages/deluge/plugins/WebUi-0.1.egg
[DEBUG   ] 18:56:41 pluginmanagerbase:124 Found plugin: Scheduler 0.3 at /usr/lib/python2.7/dist-packages/deluge/plugins/Scheduler-0.3.egg
[DEBUG   ] 18:56:41 torrentmanager:127 TorrentManager init..
[DEBUG   ] 18:56:41 configmanager:111 Getting config 'core.conf'
[DEBUG   ] 18:56:41 config:306 Registering function for max_connections_per_torrent key..
[DEBUG   ] 18:56:41 torrentmanager:910 max_connections_per_torrent set to -1..
[DEBUG   ] 18:56:41 config:306 Registering function for max_upload_slots_per_torrent key..
[DEBUG   ] 18:56:41 torrentmanager:916 max_upload_slots_per_torrent set to -1..
[DEBUG   ] 18:56:41 config:306 Registering function for max_upload_speed_per_torrent key..
[DEBUG   ] 18:56:41 torrentmanager:921 max_upload_speed_per_torrent set to -1..
[DEBUG   ] 18:56:41 config:306 Registering function for max_download_speed_per_torrent key..
[DEBUG   ] 18:56:41 torrentmanager:926 max_download_speed_per_torrent set to -1..
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert torrent_finished_alert
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert torrent_paused_alert
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert torrent_checked_alert
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert tracker_reply_alert
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert tracker_announce_alert
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert tracker_warning_alert
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert tracker_error_alert
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert storage_moved_alert
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert storage_moved_failed_alert
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert torrent_resumed_alert
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert state_changed_alert
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert save_resume_data_alert
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert save_resume_data_failed_alert
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert file_renamed_alert
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert metadata_received_alert
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert file_error_alert
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert file_completed_alert
[DEBUG   ] 18:56:41 alertmanager:97 Registered handler for alert fastresume_rejected_alert
[DEBUG   ] 18:56:41 filtermanager:105 FilterManager init..
[DEBUG   ] 18:56:41 configmanager:111 Getting config 'core.conf'
[DEBUG   ] 18:56:41 config:306 Registering function for autoadd_enable key..
[DEBUG   ] 18:56:41 autoadd:124 _on_autoadd_enable
[DEBUG   ] 18:56:41 config:306 Registering function for autoadd_location key..
[DEBUG   ] 18:56:41 autoadd:131 _on_autoadd_location
[DEBUG   ] 18:56:41 configmanager:111 Getting config 'core.conf'
[INFO    ] 18:56:41 rpcserver:369 Starting DelugeRPC server localhost:58846
[INFO    ] 18:56:41 rpcserver:377 Daemon already running or port not available..
[ERROR   ] 18:56:41 rpcserver:378 [('SSL routines', 'SSL_CTX_use_certificate', 'ee key too small')]
"systemctl status deluged.service" shows:

Code: Select all

● deluged.service - Deluge Bittorrent Client Daemon
   Loaded: loaded (/etc/systemd/system/deluged.service; enabled; vendor preset: enabled)
   Active: inactive (dead) since Tue 2018-08-28 18:56:41 BST; 7min ago
  Process: 20349 ExecStart=/usr/bin/deluged -d -l /var/log/deluge/daemon.log -L debug (code=exited, status=0/SUCCESS)
 Main PID: 20349 (code=exited, status=0/SUCCESS)

Aug 28 18:56:41 capella systemd[1]: Started Deluge Bittorrent Client Daemon.
StarNamer
New User
New User
Posts: 3
Joined: Mon Aug 27, 2018 10:20 pm

Re: Deluge daemon fails to start with rpcserver error

Post by StarNamer »

It seems that both daemon.cert and daemon.pkey in the ssl folder needed updating. I copied versions created from a docker installation and the service started fine.
shamael
Compulsive Poster
Compulsive Poster
Posts: 667
Joined: Sat Oct 08, 2016 9:28 am

Re: Deluge daemon fails to start with rpcserver error

Post by shamael »

thx for your feedback ;)
efhalo
New User
New User
Posts: 4
Joined: Fri Sep 07, 2018 7:34 pm

Re: Deluge daemon fails to start with rpcserver error

Post by efhalo »

Same problem on debian. What is the exact fix?
efhalo
New User
New User
Posts: 4
Joined: Fri Sep 07, 2018 7:34 pm

Re: Deluge daemon fails to start with rpcserver error

Post by efhalo »

I reinstall and now:

Traceback (most recent call last):
File "/usr/local/bin/deluged", line 11, in <module>
load_entry_point('deluge', 'console_scripts', 'deluged')()
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 484, in load_entry_point
return get_distribution(dist).load_entry_point(group, name)
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 2707, in load_entry_point
return ep.load()
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 2325, in load
return self.resolve()
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 2331, in resolve
module = __import__(self.module_name, fromlist=['__name__'], level=0)
ImportError: No module named main
efhalo
New User
New User
Posts: 4
Joined: Fri Sep 07, 2018 7:34 pm

Re: Deluge daemon fails to start with rpcserver error

Post by efhalo »

sorry it was my fault, now i have the original problem:

Code: Select all

[ERROR   ] 09:38:26 config:390 No JSON object could be decoded
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/deluge/config.py", line 388, in load
    self.__config.update(json.loads(data[start:end]))
  File "/usr/lib/python2.7/json/__init__.py", line 339, in loads
    return _default_decoder.decode(s)
  File "/usr/lib/python2.7/json/decoder.py", line 364, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/lib/python2.7/json/decoder.py", line 382, in raw_decode
    raise ValueError("No JSON object could be decoded")
ValueError: No JSON object could be decoded
[ERROR   ] 09:38:26 rpcserver:378 [('SSL routines', 'SSL_CTX_use_certificate', 'ee key too small')]
efhalo
New User
New User
Posts: 4
Joined: Fri Sep 07, 2018 7:34 pm

Re: Deluge daemon fails to start with rpcserver error

Post by efhalo »

The workaround: del key files from: /home/USER/.config/deluge/ssl/
reukiodo
New User
New User
Posts: 8
Joined: Sun Nov 04, 2018 9:42 pm

Re: Deluge daemon fails to start with rpcserver error

Post by reukiodo »

efhalo wrote:The workaround: del key files from: /home/USER/.config/deluge/ssl/
This worked for me, although I had a LOT of daemon.cert and daemon.pkey files everywhere:

/var/lib/deluged/config.old/ssl/
~/.config/deluge/ssl/
~/.config/deluge.old/ssl/
Post Reply