I'm trying to install gitlab on my apache2 server using this tutorial : http://blog.florentlim.com/how-to-install-gitlab-on-debian-7-wheezy-on-apache2-http-server/ Everything seemed to go correctly, I've done every step, without any major problems.

But now when I try to connect on my gitlab page, it shows up a "error 500 page". Looking at my gilab production.log , it looks like gilab can't connect on the /var/run/redis/redis.socket file, and sure enough, there is no such file. And I don't know why... I verified my /etc/redis/redis.conf file, the TCP port is set to 0, and I've got the lines

unixsocket /var/run/redis/redis.sock
unixsocketperm 770

So why does redis refuses to create my socket?

Any help would be appreciated. Thanks

  • 2
    Does /var/run/redis/ exist? Does whatever user is redis running have permission to write in the directory?
    – Stefan
    Aug 7, 2015 at 11:49
  • 1
    ok, I'm feeling really dumb on this one. It was a permission issue indeed. Thanks
    – aramir
    Aug 7, 2015 at 13:27
  • Also, I found that I needed to run the redis-server using sudo in order for the socket file to be created.
    – Jim
    Jan 13, 2017 at 5:21

1 Answer 1


I had a similar issue but on a derivative of Arch Linux.

Redis had to be installed for OpenVAS and I was getting a permission error after attempting to start the service like this:

systemctl start redis.service

The error was visible using:

journalctl -xeu redis.service

as recommended by the systemctl command output.

When it attempted to create the Unix socket in /run (also linked from /var/run) it would fail because it could not create the file. I could manually created a redis subdirectory under /run using sudo and change the owner to the redis user then started redis but the directory kept disappearing later.

I tried re-installing with pacman because I was a bit lost but that didn't seem to help.

Solution in my case

After running

sudo systemctl enable redis.service

I can start the service and /run/redis (also linked as /var/run/redis) is present with a PID and Unix socket file as configured with the unixsocket entry in my config file.

I can confirm it's accessible with:

redis-cli -s /run/redis/redis.sock

After a reboot it's still good.

You must log in to answer this question.

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