Laravel Error: ERR unknown command 'EVAL'

6673
Share:
laravel-error-err-unknown-command-eval

Background

Earlier today, I'm experiencing an error after uploading Laravel application to production server. Google'd the error message and comes with minimal match. Well, I guess because it's OS and Redis version specific issue. The error itself says: ERR unknown command 'EVAL'.

Laravel Redis Error

Investigation

My development box runs Linux Mint 18.1 Serena with PHP 7 and redis-server 3.0.6 installed. Meanwhile, my production server uses Centos 6, PHP 5.6, and redis-server 2.4.0. The error message mentioned about unknown redis command: EVAL. After a quick read on https://redis.io/commands/eval, I know what the root cause of this error. My redis-server on production needs to be updated to be able to run Laravel 5.4. Running yum update says "No Packages marked for Update".

Workaround

Well, because I kind of need this application immediately, I just change my CACHE_DRIVER and SESSION_DRIVER to memcached. And my application runs happily ever after.

Notes to Myself

Be careful when choosing framework version. Sometimes newest framework version also uses newer library, meanwhile official distibution's repositories doesn't always release newer one.

Tags
Share:

0 comment

Leave a reply

Your email address will not be published. Required fields are marked *