Forums | Mahara Community

Support /
Users timing out


anonymous profile picture
Deleted user
Posts: 78

14 October 2009, 5:04 AM

We currently have around 200 learners using Mahara to some degree or other. A problem we are experiencing is that learners are working with blogs and editing text in views and are being timed out, subsequently losing all that they have done. Which file do I need to edit to address this?

Thanks Kevin 

Whoops, I forgot the other little problem as well. When users are editing something in a view and enlarge the text box to full screen, the information they add does not always stick, thus when they return to the view there is nothing to save.

Grateful fo any help here 

anonymous profile picture
Deleted user
Posts: 1643

14 October 2009, 9:14 PM

Hi,

On the Admin -> Site Options page, there is a Session Timeout field. Try upping that from the default (which I think is 30 in Mahara 1.1) to something nice and large, like 240 (four hours).

The full screen text boxes is a TinyMCE problem, it might have been fixed when we upgraded TinyMCE for Mahara 1.2. In any event, it's a bit counter intuitive - you type in what you want, then you close the window by clicking the X. The text is then transferred back to the other box, so you can hit 'save'. Silly, I know Embarassed 

anonymous profile picture
Deleted user
Posts: 6

05 November 2009, 3:49 AM

Was this problem solved? I am having a similar problem. Everytime I am editing a view, switching tabs between the available items to drag drop, a modal dilaog appears telling me that "Your session has timed out, please enter login details to continue" and it doesn't even accepts my correct password.

 I am stuck, please help.

anonymous profile picture
Deleted user
Posts: 16

05 November 2009, 1:44 PM

I had a similar problem.  I discovered that although Mahara has some ini session timeout settings (similar to CakePHP), just like CakePHP, the php.ini settings of your server seem to force this behavior where the timeout is not the same as you may set in Mahara.

If you're on a hosted environment and cannot adjust your php.ini ... Mahara comes with a .htaccess file that is in the root directory of the mahara installation.  Simply add the follow lines to that .htaccess file:

 

php_value session.gc_maxlifetime 3600

php_value session.gc_divisor 1

php_value session.gc_probability 1

Hope this helps.
RRM 

 

anonymous profile picture
Deleted user
Posts: 6

06 November 2009, 3:50 AM

Hi, thanks for your reply.

I am indeed on a shared hosting environment and donot have access to php.ini. Even the .htacess has some directives disabled so cannot set these variables. Is there another possibility for fixing this?

Nathan Friend's profile picture
Posts: 12

21 February 2012, 6:31 AM

Hi,

I've set our server settings as follows:

session.gc_maxlifetime 14000

session.gc_divisor 1

session.gc_probability 1

I've also set the session lifetime setting in Mahara admin to 14000.

 

Howver timeout is still very short.  Please advise.

Nathan Friend's profile picture
Posts: 12

02 March 2012, 5:44 AM

Any advice on what to try next?

Iñaki Arenaza's profile picture
Posts: 253

03 March 2012, 3:47 PM

If you are using PHP as a web server module (Apache or IIS) and you changed your settings in the global php.ini, make sure you restart your web service.

In addition to that, you can add a new file in your Mahara installation directory (let's call it phpinfo.php) and add the following to it:

<?php
phpinfo();
?>

Then point your browser to http://your.mahara.site/phpinfo.php

You should get a very long page with all the PHP settings, including the session settings you have supposedly changed. Make sure they are actually what they should be.

Once you're done, you can remove the phpinfo.php file.

Saludos.
Iñaki.

Nathan Friend's profile picture
Posts: 12

07 March 2012, 2:51 AM

Hi Iñaki,

Apache service was restarted.  Here's my session settings, it looks like the updated values have been accepted.  Still getting the time out though.

session

Session Support enabled
Registered save handlers files user mm
Registered serializer handlers php php_binary wddx

 

DirectiveLocal ValueMaster Value
session.auto_start Off Off
session.bug_compat_42 Off Off
session.bug_compat_warn On On
session.cache_expire 180 180
session.cache_limiter nocache nocache
session.cookie_domain no value no value
session.cookie_httponly On On
session.cookie_lifetime 0 0
session.cookie_path / /
session.cookie_secure Off Off
session.entropy_file /dev/urandom /dev/urandom
session.entropy_length 16 16
session.gc_divisor 1 1
session.gc_maxlifetime 14400 14400
session.gc_probability 1 1
session.hash_bits_per_character 5 5
session.hash_function 1 1
session.name PHPSESSID PHPSESSID
session.referer_check no value no value
session.save_handler files files
session.save_path /var/lib/php5 /var/lib/php5
session.serialize_handler php php
session.use_cookies On On
session.use_only_cookies On On
session.use_trans_sid 0 0

Cheers,

 

Nathan.

Nathan Friend's profile picture
Posts: 12

07 March 2012, 4:02 AM

I've traced the source of the session timeouts to our loadbalaner hardware loosing the session persistence.  I've changed the configuration and now users don't get logged out.  Success! 

 

 

10 results