Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

Humongous sessions

  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
7 years 3 months ago #146166 by DenisChenu
Replied by DenisChenu on topic Humongous sessions

bruce78 wrote:

jelo wrote: Till LimeSurvey is mostly use in small surveys with not many concurrent probands the session misdesign will be last for a long time.


Sure, I can imagine that... I guess there are no plans to speed up the session design in version 3?

Big session is here since a lot of year then hard to remove (because a lot of functionality depend from this session).

Using cache seems a good idea to do some part of session : but
1. all this part must be cut before with User dependant VS not user dependant (we must cache only 'not user dependant')
2. A good obsolete system for caching

More than 2 week of complete work just for Expression Manager StartSurvey, and surely a lot of bug after.

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
More
7 years 3 months ago #146186 by bruce78
Replied by bruce78 on topic Humongous sessions

DenisChenu wrote: My /tmp/ and php/temp are already mounted on RAM : then use the default sqlite db : this is very longer for me ...


I'm guessing your talking about using one of ramfs or tmpfs and mounting the directory in fstab? These two posts seem to go over this idea... is this what you're referring to?

DenisChenu wrote: Using cache seems a good idea to do some part of session : but
1. all this part must be cut before with User dependant VS not user dependant (we must cache only 'not user dependant')
2. A good obsolete system for caching
More than 2 week of complete work just for Expression Manager StartSurvey, and surely a lot of bug after.


I can imagine it would be a lot of work... I guess for larger surveys, the trick is to optimise the machine first which is probably easier right now...
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
7 years 3 months ago - 7 years 3 months ago #146190 by DenisChenu
Replied by DenisChenu on topic Humongous sessions

bruce78 wrote: I'm guessing your talking about using one of ramfs or tmpfs and mounting the directory in fstab?

/tmpfs, yes.

But sorry : on this test server : on a hd, then seems sqlite is slower than files ?

Currently i use for this server, default config of debian7 : session.save_path /var/lib/php5/sessions
I have memcache enable, maybe i can test a memcache session :)

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
Last edit: 7 years 3 months ago by DenisChenu. Reason: fix quote
The topic has been locked.
More
7 years 3 months ago #146193 by bruce78
Replied by bruce78 on topic Humongous sessions

DenisChenu wrote: But sorry : on this test server : on a hd, then seems sqlite is slower than files ?


Correct, the sqlite is slower than the HDD

DenisChenu wrote: Currently i use for this server, default config of debian7 : session.save_path /var/lib/php5/sessions
I have memcache enable, maybe i can test a memcache session :)


I suspect memcache would be a great improvement for large surveys - what changes need to be made to the LS code to test this/implement this?
The topic has been locked.
More
7 years 3 months ago #146195 by bruce78
Replied by bruce78 on topic Humongous sessions
This guide for using memcache with Magento seems to also rely on a yii-syle config file... I wonder if it's really as simple as editing the config file as per the example...
Code:
'session' =>
   array (
      'save' => 'memcache',
      'save_path' => 'tcp://<memcache ip or host>:<memcache port>'
),
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
7 years 3 months ago - 7 years 3 months ago #146196 by DenisChenu
Replied by DenisChenu on topic Humongous sessions
I test directly with
Code:
php_value session.save_handler memcache
php_value session.save_path tcp://127.0.0.1:11211?persistent=1&amp;weight=1&amp;timeout=1&amp;retry_interval=15
in my virtualhost file (and validate if it's OK)

Not really more speed, maybe the gap is not big due to session contruction and not session save/load system.

For Yii config : i don't see save_handler in www.yiiframework.com/doc/api/1.1/CHttpSession , then unsure you can set it in config.

PS : looking at memcache log : save /load are really speed, but no real HTML construction improvment.

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
Last edit: 7 years 3 months ago by DenisChenu.
The topic has been locked.
More
7 years 3 months ago #146197 by bruce78
Replied by bruce78 on topic Humongous sessions

DenisChenu wrote: Not really more speed, maybe the gap is not big due to session contruction and not session save/load system.

PS : looking at memcache log : save /load are really speed, but no real HTML construction improvment.


Do you think memcache made an improvement in load times/session speed once you loaded a large survey on the 2nd, 3rd and 4th times etc?
The topic has been locked.
  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
7 years 3 months ago #146201 by DenisChenu
Replied by DenisChenu on topic Humongous sessions
Hi,

Tested :
- newtest/Y on a long survey : still between 5 and 6 seconds for memcache an file (on MY server with MY config: i really think all server/config can be different)
- with this survey : click next/previous : less than 1 second for each : memcache seems slowest by 0.1/0.2 seconds , but can be something else at samùe time , my server do others thing ;)

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
More
7 years 3 months ago #146202 by bruce78
Replied by bruce78 on topic Humongous sessions
Got you... I'm testing out SSDs and I'll add in memcache too...
The topic has been locked.
More
7 years 2 months ago #146720 by bruce78
Replied by bruce78 on topic Humongous sessions
Ok, so I've now changed sever and have got an ssd drive instead of a hdd and as a result everything is much faster... I've also got nginx infront of apache which probably helps... Anyway, lots more ideas to explore in the future but I think the ssd is the big difference here...

Thanks for your help and best wishes for 2017!
The following user(s) said Thank You: DenisChenu
The topic has been locked.
More
5 years 3 months ago #178511 by bruce78
Replied by bruce78 on topic Humongous sessions

DenisChenu wrote: Hi,

Tested :
- newtest/Y on a long survey : still between 5 and 6 seconds for memcache an file (on MY server with MY config: i really think all server/config can be different)
- with this survey : click next/previous : less than 1 second for each : memcache seems slowest by 0.1/0.2 seconds , but can be something else at samùe time , my server do others thing ;)


Hey Denis, I started a new thread with some findings based on this discussion from a couple of years ago...
The following user(s) said Thank You: DenisChenu
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose