title: Laravel4 losing session on refresh
body: <p>We have a Laravel project that uses default Auth module for login, but on some computers, users won't stay logged for long. Sometimes the session is lost right after login, so even if it logs successful login attempt, next refresh doesn't get authenticated. </p>
  
  <p>We have tried removing redirect after login as well as various session storages (namely 'file' and 'cookies'), but on some computers (no matter which browser), the problem never occurs while on others it persists.</p>
  
  <p>Possible cause is that sometimes every instance of the same request gets new session, this behavior is random as far as we were able to find out. </p>
  
  <p>The only way to replicate the problem was to switch Laravel session storage to cookies, send a few requests, switch it back to file, afterwards sessions tend to get lost until a cookie set by laravel for session storage with random-looking name and content size a bit over 1kb is manually removed.<br></p>
  
  <p>We are using Laravel 4.1 and native PHP server (php artisan serve)</p>
  
  <p>From what I've googled so far, neither renaming primary key in Users to 'id' nor removing every redirect helped.</p>
  
  <p>The problem persists even is the whole page contains nothing but <code>/singin/</code> route and <code>Auth::check()</code> in a template.</p>
  
  <p>Tested browsers are Opera/Chrome/Firefox on OS X 10.5.8 and 10.9, which don't work and Ubuntu 13.10 and another 10.9 OS X that always work.</p>
  
  <p>Could this be a bug in the webserver we are using for development? Has anyone else seen this happening?</p>
  
  <p>Thanks for eveny advice</p>