Navigation Menu

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

Redis "unknown command" Error #329

Closed
faridmovsumov opened this issue Apr 27, 2016 · 3 comments
Closed

Redis "unknown command" Error #329

faridmovsumov opened this issue Apr 27, 2016 · 3 comments

Comments

@faridmovsumov
Copy link

I use Redis as session storage in my website (Laravel 4.2). Sometimes I get following errors. I guess ">" char broke the setex commands.

production.ERROR: exception 'Predis\ServerException' with message 'ERR unknown command '>'' in 

production.ERROR: exception 'Predis\ServerException' with message 'ERR unknown command 'tml>''

production.ERROR: exception 'Predis\ServerException' with message 'ERR unknown command '</div>''

These errors occurs rarely on production server and I can't reproduce them. Do you have any idea why these errors occurs and how can I prevent them?

key: laravel:xxxxxxxxxxxxxxx

value: s:217:"a:4:{s:6:"_token";s:40:"xxxxxxxxxxx";s:4:"lang";s:2:"fr";s:9:"_sf2_meta";a:3:{s:1:"u";i:1461777248;s:1:"c";i:1461777248;s:1:"l";s:1:"0";}s:5:"flash";a:2:{s:3:"old";a:0:{}s:3:"new";a:0:{}}}";

exception 'Predis\ServerException' with message 'ERR unknown command 'ml>'' in vendor/predis/predis/lib/Predis/Client.php:282

I asked this question on StackOverflow but there is no answer 😒

@nrk
Copy link
Contributor

nrk commented May 8, 2016

Strings are considered binary blobs which means their contents can't break anything when Predis serializes a command and its arguments using the Redis protocol. Actually I don't see any correlation between the arguments passed to SETEX and the characters returned in the exception message (plain HTML code), my only guess points to some kind of protocol desynchronization. Are you perhaps using persistent connections by setting the persistent connection parameter to true?

@faridmovsumov
Copy link
Author

Thanks @nrk for response. No I don't set persistent parameter to true.

@nrk
Copy link
Contributor

nrk commented May 13, 2016

@faridmovsumov I'm sorry but it's nearly impossible to get the hang of the problem you are experiencing without a trace log generated by something like xdebug, furthermore I don't know anything about Laravel so I can't help you. One thing I'm sure is that answer you got on stackoverflow is absolute non-sense. I'm closing this issue as I'm pretty sure it's hardly related to the client, but if you manage to obtain more details feel free to post them.

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

No branches or pull requests

2 participants