O'Reilly logo

Mastering Redis by Jeremy Nelson

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

32-bit Redis

In the official documentation on Redis.io's website on Memory Optimization3, one suggestion is to compile Redis in 32-bit mode instead of using the default 64 bit instance.

32-bit Redis

Using a 32-bit Redis instances for datasets under 3 GB is smaller than the same dataset in the 64-bit version of Redis. This can be illustrated in the following tests. We'll launch two Redis instances, INSTANCE64 and INSTANCE32. We'll create a quick Python function, test_redis_32k_65k, in a Python command line to create 100,000 keys using a UUID as a string value:

>>>def test_redis_32k_64k():
  for i in range(100000):
    key = "uuid:{}".format(i)
 value = uuid.uuid4() ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required