0

I've set my values in my PHP.ini as shown below. Redis works and the sessions work. Now what I really wonder is How do I know that sessions are being handles & stored at Redis? I've searched everywhere and I cant find how would I validate that is working with Redis.

I need to be able to check somehow that the sessions are stored there.

session.save_handler = redis
session.save_path = "tcp://host1:6379"
extension=redis.so

my PHP info shows

session.name    PHPSESSID   PHPSESSID
Jonathan Thurft
  • 4,087
  • 7
  • 47
  • 78

1 Answers1

3

If your sessions were being successfully managed by redis, you would see new keys being added to redis when a session is created.

You can ask redis to list its keys on the command line:

$ redis-cli keys "*"
1) "some-redis-session-keys"
2) "should-be-in-this-list"
Carl Zulauf
  • 39,378
  • 2
  • 34
  • 47