Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unix domain socket doesn't have the right file permission #9266

Closed
Anricx opened this issue Jan 2, 2018 · 2 comments
Closed

Unix domain socket doesn't have the right file permission #9266

Anricx opened this issue Jan 2, 2018 · 2 comments

Comments

@Anricx
Copy link

Anricx commented Jan 2, 2018

Bug report

System info: Ubuntu 16.04

Steps to reproduce:

  1. install influxdb by
curl -sL https://repos.influxdata.com/influxdb.key | sudo apt-key add -
source /etc/lsb-release
echo "deb https://repos.influxdata.com/${DISTRIB_ID,,} ${DISTRIB_CODENAME} stable" | sudo tee /etc/apt/sources.list.d/influxdb.list
  1. edit /etc/influxdb/influxdb.conf enable http service over unix domain socket

  2. restart influxdb

influxdb default run with user influxdb and create unix domain socket influxdb.sock without write permission, finally it will cause nginx could connect this socket!

so i have 2 chooses:

  1. custom influxdb to run with root or my nginx user group.
  2. or execute chmod a+x influxdb.sock evenytime influxdb restart.
@Anricx Anricx changed the title Unix domain socket doesn's have the right file permission Unix domain socket doesn't have the right file permission Jan 2, 2018
@jsternberg
Copy link
Contributor

Can you show me the output of ls -l /var/run/influxdb.sock?

@jsternberg
Copy link
Contributor

Ok, I think I misunderstood this question. The problem is that the unix socket created by InfluxDB is 0755 and that doesn't allow writes or queries from those outside of the influxdb group when attempting to use nginx as a query.

I'm going to switch this to a feature request since this isn't a bug in the packaging or the software as I thought it was. But, it might be nice to be able to call the equivalent of chmod and chown on the socket that is created automatically which could probably be added as an extra configuration option.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants