Welcome Guest, Not a member yet? Register   Sign In
session.save_path ERROR
#1

I was on version 3.0.6 and just upgraded to the latest version of CI hoping that my implementation of AWS Elasticache using Memcached for $_SESSION would work without the errors I was getting on 3.0.6.

I am getting a continued error every time I login to our website:

ERROR - 2017-01-08 16:03:56 --> Severity: Warning --> Unknown: Failed to write session data (user). Please verify that the current setting of session.save_path is correct (*****.******.*****:11211) Unknown 0

What's strange is that the Elasticache is working and the session.save_path is correct. What could be causing this error and how can I correct?

Thanks,

Joe
Reply
#2

Further update on this. It appears the ERROR is a php error, not a CI error: https://bugs.php.net/bug.php?id=71070. However, I am getting errors from the Session_memcached_driver.php even though I have the memcached.ini file locking set to FALSE. Specifically, the CI errors are coming from Session_memcached_driver.php line 365, Session: Error while trying to free lock for '.$this->_lock_key and Session_memcached_driver.php line 342, Session: Unable to obtain lock for '.$this->_key_prefix.$session_id.' after 30 attempts, aborting.'

Therefore, the question would be why is CI not observing the no lock setting for memcached?
Reply
#3

Because:

1. CI doesn't use the Memcached session handler; it has its own implementation.
2. Locking is a MUST and you're not allowed to disable it, by design. This is the main reason why CI_Session was rewritten for CI3 in the first place.

The error means that write() returned FALSE - nothing else, you'd have to dig into it to see why.
Reply




Theme © iAndrew 2016 - Forum software by © MyBB