sonyboy.dk

Tools, tip, tricks and other stuff I might come up with

Apache2 hangs with ‘Digest: generating secret for digest authentication’

without comments

I was running Apache2+SSL on a VM (Virtual Machine).

After enabling SSL and trying to add another SSL site, apache would refuse to restart and the following error would show up in /var/log/apache2.log

Digest: generating secret for digest authentication

After doing some research, it turns out that the VM did not have enough entropy to generate much of anything. Increasing this is easy, but may not be completely secure.

$ cat /proc/sys/kernel/random/entropy_avail
139

I found that rng-tools could help me solve this.

apt-get install rng-tools

Start the service

rngd -r /dev/urandom -o /dev/random

After running rngd, the entropy will increase at a gradual rate.

cat /proc/sys/kernel/random/entropy_avail
2220

If you want this to survive a reboot, you’ll need to put it in a startup script.

Related posts:

  1. Apache2 – No space left on device

Written by Sonyboy

October 20th, 2009 at 2:31 pm

Posted in Howto

Tagged with ,

Leave a Reply