collectd is unable to start
-
I have issues with starting collectd in order to get my Cloudron server online again.
Im starting a new support thread since I was unable to find another reliable support thread to use.
Here is the Journalctl output
root@my:/home/yellowtent/platformdata/nginx# journalctl -u collectd -- Logs begin at Wed 2022-06-15 05:35:14 UTC, end at Wed 2022-06-15 19:17:32 UTC. -- Jun 15 05:35:14 URL collectd[71032]: ERROR: dlopen("/usr/lib/collectd/python.so") failed: /usr/lib/collectd/python.so: undefined symbol: PyFloat_Type. The > Jun 15 05:35:14 URL collectd[71032]: Error: Parsing the config file failed! Jun 15 05:35:14 URL systemd[1]: collectd.service: Main process exited, code=exited, status=1/FAILURE Jun 15 05:35:14 URL systemd[1]: collectd.service: Failed with result 'exit-code'. Jun 15 05:35:14 URL systemd[1]: Failed to start Statistics collection and monitoring daemon. -
@girish Yes. from 18.04 to 20.04, followed the guide, everything was working after the upgrade, this happend 2 days after the upgrade

(Have to wait 360 seconds to reply....)
@AniTexs I think maybe the collectd config got overwritten during the upgrade. If you run
/home/yellowtent/box/setup/start.sh, this will put the expected collectd config.Also, check the content of
/etc/default/collectd. It should contain:LD_PRELOAD=/usr/lib/python3.8/config-3.8-x86_64-linux-gnu/libpython3.8.soAfter that,
systemctl restart collectd. -
@AniTexs I think maybe the collectd config got overwritten during the upgrade. If you run
/home/yellowtent/box/setup/start.sh, this will put the expected collectd config.Also, check the content of
/etc/default/collectd. It should contain:LD_PRELOAD=/usr/lib/python3.8/config-3.8-x86_64-linux-gnu/libpython3.8.soAfter that,
systemctl restart collectd.@girish It works after inserting the LD_PRELOAD
root@my:~# /home/yellowtent/box/setup/start.sh 2022-06-16T14:58:38 ==> start: Cloudron Start media:x:500: 2022-06-16T14:58:38 ==> start: Configuring docker Synchronizing state of apparmor.service with SysV service script with /lib/systemd/systemd-sysv-install. Executing: /lib/systemd/systemd-sysv-install enable apparmor 2022-06-16T14:58:40 ==> start: Ensuring directories 2022-06-16T14:58:40 ==> start: Configuring journald 2022-06-16T14:58:41 ==> start: Setting up unbound 2022-06-16T14:58:41 ==> start: Adding systemd services Synchronizing state of unbound.service with SysV service script with /lib/systemd/systemd-sysv-install. Executing: /lib/systemd/systemd-sysv-install enable unbound Synchronizing state of cron.service with SysV service script with /lib/systemd/systemd-sysv-install. Executing: /lib/systemd/systemd-sysv-install enable cron 2022-06-16T14:58:48 ==> start: Configuring sudoers 2022-06-16T14:58:48 ==> start: Configuring collectd Job for collectd.service failed because the control process exited with error code. See "systemctl status collectd.service" and "journalctl -xe" for details. root@my:~# systemctl restart collectd Job for collectd.service failed because the control process exited with error code. See "systemctl status collectd.service" and "journalctl -xe" for details. root@my:~#The content of /etc/default/collectd
GNU nano 4.8 /etc/default/collectd # /etc/default/collectd # 0: start collectd on boot, 1: do not start collectd on boot # default: 0 DISABLE=0 # 0: start collectd in stand-alone mode, 1: monitor collectd using collectdmon # default: 1 USE_COLLECTDMON=1 # number of seconds to wait for collectd to shut down # default: 30 MAXWAIT=30 # 0: do not enable core-files, 1: enable core-files ... if collectd crashes # default: 0 ENABLE_COREFILES=0After inserting the line
# /etc/default/collectd # 0: start collectd on boot, 1: do not start collectd on boot # default: 0 DISABLE=0 # 0: start collectd in stand-alone mode, 1: monitor collectd using collectdmon # default: 1 USE_COLLECTDMON=1 # number of seconds to wait for collectd to shut down # default: 30 MAXWAIT=30 # 0: do not enable core-files, 1: enable core-files ... if collectd crashes # default: 0 ENABLE_COREFILES=0 LD_PRELOAD=/usr/lib/python3.8/config-3.8-x86_64-linux-gnu/libpython3.8.soroot@my:~# nano /etc/default/collectd root@my:~# systemctl restart collectd root@my:~# -
G girish marked this topic as a question on
-
G girish has marked this topic as solved on
-
D Dreamcatch22 referenced this topic on
-
@AniTexs I think maybe the collectd config got overwritten during the upgrade. If you run
/home/yellowtent/box/setup/start.sh, this will put the expected collectd config.Also, check the content of
/etc/default/collectd. It should contain:LD_PRELOAD=/usr/lib/python3.8/config-3.8-x86_64-linux-gnu/libpython3.8.soAfter that,
systemctl restart collectd.@girish said in collectd is unable to start:
@AniTexs I think maybe the collectd config got overwritten during the upgrade. If you run
/home/yellowtent/box/setup/start.sh, this will put the expected collectd config.Also, check the content of
/etc/default/collectd. It should contain:LD_PRELOAD=/usr/lib/python3.8/config-3.8-x86_64-linux-gnu/libpython3.8.soAfter that,
systemctl restart collectd.Similar issue after upgrading from Ubuntu 20.04 to 22.04 - but despite the reference to
libpython3.8.sobeing present in/etc/default/collectd, it seems that this file is no longer present...However, what is present is
/usr/lib/python3.10/config-3.10-x86_64-linux-gnu/libpython3.10.so- after referencing this file in/etc/default/collectd(i.e. addingLD_PRELOAD=/usr/lib/python3.10/config-3.10-x86_64-linux-gnu/libpython3.10.so), and restarting thecollectdservice, it starts running again.... but will this change persist?
-
@girish said in collectd is unable to start:
@AniTexs I think maybe the collectd config got overwritten during the upgrade. If you run
/home/yellowtent/box/setup/start.sh, this will put the expected collectd config.Also, check the content of
/etc/default/collectd. It should contain:LD_PRELOAD=/usr/lib/python3.8/config-3.8-x86_64-linux-gnu/libpython3.8.soAfter that,
systemctl restart collectd.Similar issue after upgrading from Ubuntu 20.04 to 22.04 - but despite the reference to
libpython3.8.sobeing present in/etc/default/collectd, it seems that this file is no longer present...However, what is present is
/usr/lib/python3.10/config-3.10-x86_64-linux-gnu/libpython3.10.so- after referencing this file in/etc/default/collectd(i.e. addingLD_PRELOAD=/usr/lib/python3.10/config-3.10-x86_64-linux-gnu/libpython3.10.so), and restarting thecollectdservice, it starts running again.... but will this change persist?
@necrevistonnezr said in collectd is unable to start:
... but will this change persist?
yes, that's the correct fix. I had this line in the ubuntu 20 upgrade guide, but it's missing in the ubuntu 22 guide. I have added it now.
-
I have the same issue, and i tried to add the
LD_PRELOADthink, but i got a parsing error in the file.
Does anyone have already saw that ?May 10 15:14:23 sanchezm systemd[1]: Starting Statistics collection and monitoring daemon... May 10 15:14:23 sanchezm collectd[6484]: [2023-05-10 15:14:23] plugin_load: plugin "logfile" successfully loaded. May 10 15:14:23 sanchezm collectd[6484]: Error: Parsing the config file failed! May 10 15:14:23 sanchezm systemd[1]: collectd.service: Main process exited, code=exited, status=1/FAILURE May 10 15:14:23 sanchezm systemd[1]: collectd.service: Failed with result 'exit-code'. May 10 15:14:23 sanchezm systemd[1]: Failed to start Statistics collection and monitoring daemon. May 10 15:14:25 sanchezm systemd[1]: Stopped Statistics collection and monitoring daemon.After some research, i found that the issue come from the
Import "du"in thecollectd.conffile.
Does anyone know how to fix that ?<Plugin python> # https://blog.dbrgn.ch/2017/3/10/write-a-collectd-python-plugin/ ModulePath "/home/yellowtent/box/setup/start/collectd/" LogTraces false # enable this to get traces in /var/log/collectd.log Interactive false Import "df" # Import "du" <Module du> <Path> Instance maildata Dir "/home/yellowtent/boxdata/mail" </Path> <Path> Instance boxdata Dir "/home/yellowtent/boxdata" Exclude "mail" </Path> <Path> Instance platformdata Dir "/home/yellowtent/platformdata" </Path> </Module> </Plugin> -
@mathieuepitech Interesting. du is a custom plugin we wrote. Can you tell which ubuntu version you are on? Also, the python version (3.8 or 3.10?).
@girish I just upgrade to ubuntu 20.04.6 LTS
And python 3.8.
I just check back the collectd.conf, and I don"t have anymore the module du.
I upgrade to cloudron 7.4.1.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login