Roundcube Community Forum

News and Announcements => General Discussion => Topic started by: LoJo on December 27, 2015, 09:53:00 AM

Title: /temp size growing
Post by: LoJo on December 27, 2015, 09:53:00 AM
Hello,
I have a roundcube 1.1.3 install (I will update to 1.1.4 soon)
The /temp folder is growing : ther is files since 2011!
However, $config['temp_dir_ttl'] is set to 48h in the config file.

- why ?
- is there a soluce to autoclean /temp ?
- can I simply erase /temp content without a bad side effect ?

Thanks ;-)
Title: Re: /temp size growing
Post by: alec on December 28, 2015, 03:00:48 AM
Looks like you have session garbage collector disabled in PHP config. Enable it or use bin/gc.sh script from cron.
Title: Re: /temp size growing
Post by: LoJo on December 28, 2015, 03:21:42 AM
Hello,
RC is installed on a shared web hosting.
I can use a web cron to run php scripts, but not bash scripts.
Is there a alternate solution ?

Thanks

[edit]
I upgraded to RC 1.1.4

I just verified my phpinfo(), and I have :

session.gc_divisor   100
session.gc_maxlifetime   1440
session.gc_probability   0
Title: Re: /temp size growing
Post by: alec on December 28, 2015, 05:48:21 AM
Hello,
RC is installed on a shared web hosting.
I can use a web cron to run php scripts, but not bash scripts.
Is there a alternate solution ?
Remove first line and this is a PHP script.
Quote
session.gc_divisor   100
session.gc_maxlifetime   1440
session.gc_probability   0
session.gc_probability  1
Title: [SOLVED] /temp size growing
Post by: LoJo on December 28, 2015, 12:14:16 PM
session.gc_divisor   100
session.gc_maxlifetime   1440
session.gc_probability   0
session.gc_probability  1

Hello,
I added this line in the index.php file :
Code: [Select]
ini_set('session.gc_probability','1');
And my /temp folder is now empty ;-)

Is the index.php file the better place to put that line ?
Is it better to put it in program/include/iniset.php ?

Thanks !