session.gc_maxlifetime = 1440 ; after this number of seconds, stored data will be seen as 'garbage' and cleaned up by the gc process
默认是 1440 秒,24分钟
使用 session 注意的存储路径问题
看看 php.ini 里对于 session 的设置
[session] session.save_handler = files ; handler used to store/retrieve data session.save_path = /tmp ; argument passed to save_handler in the case of files, this is the path where data files are stored