PHP session stores the user information for the later use on the server across the page requests. It stores the information such as login status, shopping items, etc and that information are stored temporarily which will be deleted after the user left the website. In most cases, the session issue will show error messages. This issue can be identified by the following indications.

  • Products on the cart are cleared after the login of the user.
  • The products on the cart can be self-cleared.
  • OpenCart admin gets the message “Invalid token session. Please log in again” while logging in.
  • There will be no items stored at the product comparison.

The possible error variants for this session issue may be like

  • Warning: session_start() [function.session-start]: No such file or directory (2) in /path/public_html/system/library/session.php on line 11
  • Warning: session_start() [function.session-start]: Permission denied (14) inĀ /path/public_html/system/library/session.php on line 11
  • Warning: session_start() [function.session-start]: No space left on device (27) in /path/public_html/system/library/session.php on line 11

Solutions to fix Session Issue:

1. For no such file or directory issue, add the following code in php.ini file

session.save_path = /tmp;

2. For Permission denied issue, check the session directory permission.

3. For no space left on device issue, upgrade to the larger hosting space.