Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed calling MemcachedSessionModule::gc() #5034

Open
OskHa opened this issue Mar 17, 2015 · 13 comments
Open

Failed calling MemcachedSessionModule::gc() #5034

OskHa opened this issue Mar 17, 2015 · 13 comments

Comments

@OskHa
Copy link

OskHa commented Mar 17, 2015

It seams that the garbage collection is not working.

/hhvm/php.ini

session.save_handler = memcached
session.save_path = "xx.xx.xx:11211"
session.gc_maxlifetime = 1209600
session.gc_probability = 1
session.gc_divisor = 10000

;memcached.sess_locking = on
;memcached.sess_lock_wait = 150000
memcached.sess_prefix = "xxx."
@daniele-rapagnani
Copy link

I'll second this one, we are experiencing this problems on our servers too.
We tried to investigate the issue to no avail.

@etcook
Copy link

etcook commented Apr 1, 2015

+1

1 similar comment
@dng-dev
Copy link

dng-dev commented Apr 2, 2015

+1

@jeroneemou
Copy link

+1
having the same issue, HHVM 3.5

@therealssj
Copy link

+1 same issue here 3.6.3

@jwatzman
Copy link
Contributor

jwatzman commented May 4, 2015

PHP is refcounted... I assume the "GC" referred to in these options is the cycle collector? If so, HHVM does not implement a cycle collector. There are some experiments on changes to its memory management strategy that might get a cycle collector as part of that, but they're still super experimental and might not pan out at all.

Can you elaborate on what the exact problem is that you're seeing? It's not like we leak everything, refcounting ensures that most data get collected. Does MemcachedSessionModule create a lot of cyclic references?

@paulbiss
Copy link
Contributor

paulbiss commented May 4, 2015

I'm not entirely sure what gc() is supposed to do on this class but it looks unimplemented.

public function gc($maxLifetime) {
return true;
}

@jwatzman
Copy link
Contributor

jwatzman commented May 4, 2015

Ah, I was fixated on these INI options

session.gc_maxlifetime = 1209600
session.gc_probability = 1
session.gc_divisor = 10000

which I think are unrelated to the original report?

@jeroneemou
Copy link

This is my exact use case:
msm_error

@nikic
Copy link
Contributor

nikic commented May 5, 2015

@jwatzman Those ini options are for controlling the GC of sessions only (unrelated to the normal value CC). They specify how often (gc_probability/gc_divisor) the session GC collects sessions that have exceeded gc_maxlifetime.

@kenliao94
Copy link

+1

1 similar comment
@basselalaraaj
Copy link

+1

@cosmok
Copy link

cosmok commented Aug 17, 2015

+1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests