I am trying to install collectd using

apt-get install collectd

in debian jessie. It always hangs at the same place, after setting up ca-certificates it will reach "Setting up collectd" and then stop forever. Control C and other gentle ways to halt installation do nothing at this point. In contrast, I am able to install collectd on my physical computer or in ubuntu container. However, I must have collectd in an lxd container on debian. Since it worked in ubuntu, I tried forcing it to install from the ubuntu repositories instead by adding the same repos my ubuntu container was using, configuring the keys, and then forcing it to install the exact same version using

apt-get install collectd=4.10.1-2.1ubuntu7 --force-yes -y

No luck, it hung at the same point.

After this, if I try to update apt tells me to run dpkg --configure -a

Are there any configuration files I can change before installing collectd to possibly make this work on a fresh debian jessie system, or alternatively are there any logs I can use to identify why it is hanging? The default apt logs have nothing useful since they just repeat the information displayed when trying to install in the first place, without specifying where the hang began.

My next step would be trying to set up jessie in virtualbox / a physical computer to see if the problem replicates there to identify if this is an LXC specific issue, or more general.

The specific lxd container image being used as a base is debian/jessie/amd64 from the remote images.linuxcontainers.org

2 Answers 2


Edit /etc/apt/sources.list add the following line:

deb http://ftp.de.debian.org/debian sid main 


aptitude update
aptitude install collectd

Once the package is installed on your system, run the below command in order to start the service.

service collectd start

Your problem is that collectd is trying to install policykit-1, and this last is hanging forever. The only solution I found until now but still have no time to test is to modify the security priviledge of LXD for each host.

# lxc config set guest 'security.privileged' true

OR I found another solution for this issue, knowing that policykit-1 installation on debian8 is not stable! You just need to install it from the jessie-backports repository. I successfully installed it with the following command:

# grep jessie-backports /etc/apt/sources.list || sudo bash -c "echo \"deb http://http.debian.net/debian jessie-backports main\" >>/etc/apt/sources.list"

# apt-get install -y -t jessie-backports policykit-1

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .