Forums / Setup & design / Disable session storing for anonymous access (crawler issues)

Disable session storing for anonymous access (crawler issues)

Author Message

Benjamin Lorteau

Tuesday 01 February 2011 5:29:19 am

Hello,

I'm running a pretty big site with eZ Publish, and my session table is constantly clogged with anonymous sessions. Thoses sessions are created by the different crawler that access site pages. I have about 150 active session of crawler, and many more inactive but stored until deletion.

Is there a way to delete anonymous session faster, or is there a way to identify search engine crawlers ?

Thanks in advance !

Solution : Upgrade to 4.4 with file based session management. Thanks Guillaume and André !

eZ Publish personal project : http://www.aeriesguard.com [fr]

Guillaume Kulakowski

Tuesday 01 February 2011 8:26:44 am

What is your eZ Publish version ?

In eZP 4.4 you can choose to store session in file system and anonymous doesn't create any session.

Other solution:

My blog : http://www.llaumgui.com (not in eZ Publish ;-))
eZC on RHEL : http://blog.famillecollet.com/pages/Config-en
eZC on Fedora : just "yum install php-channel-ezc"

Benjamin Lorteau

Tuesday 01 February 2011 9:30:10 am

I'm still running the 4.3 version.

I already thought of reducing the SessionTimeout, but I don't want to reduce real user agreement for the sake of one big MySQL table ;)

Anyway, thanks for the tips !

eZ Publish personal project : http://www.aeriesguard.com [fr]

André R.

Wednesday 02 February 2011 1:42:10 am

4.4 should be a good boost to your setup, by default it will switch to file based session handler, so if you're on some kind of cluster setup you'll need to make it use db session handler preferably before you upgrade (so it uses when the new code starts to run).

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

Benjamin Lorteau

Wednesday 02 February 2011 2:16:42 am

Hello André,

thanks for your reply, unfortunately I didn't manage to upgrade cleanly, after the upgrade I had got some pretty big SQL errors about non-existent field (even with SQL upgrade done) so I reverted to 4.3.

I'm not in cluster mode so file based session should be just fine for my setup. I will give another shot at the upgrade but for now I can't afford to pass too many time on it.

eZ Publish personal project : http://www.aeriesguard.com [fr]

Guillaume Kulakowski

Wednesday 02 February 2011 2:23:45 am

"

In eZP 4.4 you can choose to store session in file system and anonymous doesn't create any session.

"

The link: https://github.com/ezsystems/ezpublish/blob/master/doc/bc/4.4/changes-4.4.0.txt#L26

My blog : http://www.llaumgui.com (not in eZ Publish ;-))
eZC on RHEL : http://blog.famillecollet.com/pages/Config-en
eZC on Fedora : just "yum install php-channel-ezc"

Benjamin Lorteau

Monday 21 March 2011 5:48:49 am

I recently upgraded in 4.4 (with some problems though), so there's no longer a problem for me. Thanks for the tips !

eZ Publish personal project : http://www.aeriesguard.com [fr]