codeigniter会话同时交换多个请求

I am having an ecommerce website running in codeigniter. The sessions are working fine on normal case. The problem starts when, say for example if two users are there on my website and assume that they are logged in, and when they click any action like add to cart or proceed to checkout or place the order the same time the login sessions are swapped.

Could anyone please help me on this! I have searched a lot on this but couldn't find a good solution.

I am using the config file like this

$config['sess_driver'] = 'files';
$config['sess_cookie_name'] = 'ci_session';
$config['sess_expiration'] = 7200;
$config['sess_encrypt_cookie']  = TRUE;
$config['sess_save_path'] = sys_get_temp_dir();
$config['sess_match_ip'] = TRUE;
$config['sess_time_to_update'] = 300;
$config['sess_regenerate_destroy'] = FALSE;

I won;t be able to use the sess_driver as database since it will affect my website performance i believe.

Thanks in advance!.

As you are saying that users have logged in, which means there is a 'Log In' button through which users are logging in your system. So the controller where your login function has been mentioned, you can create a constructor and load your session library there, like below :

public function __construct()
{ 
  $this->load->library('session'); 
}

And make sure there is 'Logout' button too in your system, where the sessions can be destroyed on click of 'Logout' button. You can just give this a try. Just thought this might help.