Trying out the 7.x-3.x from 7.x-2.12" branch and started seeing this error right away on drush cc all.

EVAL failed: ERR unknown command 'EVAL' PhpRedis.php:130

Redis server version 2.4.10 (00000000:0)

Comments

joelpittet’s picture

Issue summary: View changes
pounard’s picture

Title: EVAL failed: ERR unknown command 'EVAL' PhpRedis.php:130 » Document that 3.x requires Redis server >= 2.6 and recommands Redis server >= 2.8

I thought I documented it, but the 3.x release won't work with Redis <2.6 du to the missing EVAL command.

Please see http://redis.io/commands/eval

Also not that 2.6 series will bump the required Redis version to 2.6 when the EVAL usage will be backported.

Thanks for reporting, I need to update the documentation.

joelpittet’s picture

I put it back to 2.x version immediately.

Yeah this is doc fix, as it mentioned only >=2.4

There was another minor problem that prompted the upgrade but I can't recall, I'll open a new issue if it resurfaces.

pounard’s picture

joelpittet, you can try using $conf['redis_flush_mode'] = 3; and I think it should work with Redis 2.4 (this mode enforce a sharding compatible behavior, and use a tiny subset of Redis).

joelpittet’s picture

A bit worried about trying sharding as I'm not sure what that is. I'll read up on it before I do that. Also my client is testing some stuff out this week so don't want to mess with stuff atm.

Thanks for the suggestion.

pounard’s picture

The sharding mode just deactivate a few get multiple and proceed to individual get calls, and does not uses the EVAL command to clear cache, but just mark somewhere in Redis the last flush timestamp, and proceed to real entry deletion when reading it and detects it as invalid. Its mainly the same code, without the EVAL and few additional redis calls (basically, in order to be able to use multiple Redis instances, you can't proceed to advanced commands that work on multiple keys at once).

It's safe and also unit tested, so you don't have to worry.

joelpittet’s picture

Ok I put that into play. Just had to wait till they were done testing stuff out:)

*crossing fingers* but so far things seem to be working with 2.4

JvE’s picture

It's safe and also unit tested, so you don't have to worry.

There is a pretty major side effect though:
Whenever any code tries to flush a cache with a wildcard, that entire cache bin is flushed, not just the entries that match the wildcard.
So a cache_clear_all('node_types:', 'cache', TRUE); will not only invalidate the node_types cache but also the theme_registry and everything else in the 'cache' bin.

pounard’s picture

@JvE that's true, that's something I still didn't found out the right solution for, when working in the sharded mode, but that's not true when using EVAL scripts.

DevElCuy’s picture

Setting at #4 worked like a charm, thanks @pounard!

karthid’s picture

#4 is working for me. Great Stuff. Thanks

pounard’s picture

For all people following this issue, does it really still need to be documented or the current documentation seems to be enough for you (real question being, should I close this issue or not) ?

eelkeblok’s picture

Title: Document that 3.x requires Redis server >= 2.6 and recommands Redis server >= 2.8 » Document that 3.x requires Redis server >= 2.6 and recommends Redis server >= 2.8

  • Pierre.R committed 3478823 on 7.x-3.x
    Issue #2482263: Document that 3.x requires Redis server >= 2.6 and...

pounard credited Pierre.R.

pounard’s picture

Status: Active » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.