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

improve error message for unix socket bind failure #2449

Closed
neomantra opened this issue Mar 11, 2015 · 1 comment
Closed

improve error message for unix socket bind failure #2449

neomantra opened this issue Mar 11, 2015 · 1 comment

Comments

@neomantra
Copy link
Contributor

Currently when a unix socket open fails, redis-server outputs:
# Opening socket: bind: Permission denied

Since the code path for that is exclusively for unix socket failures (https://github.com/antirez/redis/blob/unstable/src/redis.c#L1784), I suggest the error message prefix be changed to:
# Opening unix socket:

The motivation is to make operations easier. I was receiving this error and started exploring networking aspects, rather than the incorrect permissions on the unix socket file. A slightly more verbose message would have immediately narrowed the space of possible failure modes.

The downside of this change is that it would break exisitng ops/logging infrastructure that looks explicitly for the existing message prefix.

@antirez
Copy link
Contributor

antirez commented Mar 11, 2015

Thanks, fixed. I don't think we can afford to consider error logs as part of our API so while to break it without a good reason is probably not worth it, to fix errors is a good enough reason to potentially break regexp-grepping. However I'll avoid to merge in other branches if not unstable to allow enough time to notice the change. Cheers.

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

No branches or pull requests

2 participants