Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

General Questions

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Unable to login (login page shown again) [solved]


Reply

5 Posts   867 Views

Avatar
MarijnKampf

19 June 2013 at 5:37am Community Member, 164 Posts

I can no longer login to my Silverstripe 3.0 admin section. I've tried adding a default password to the _config.php, but this doesn't work either. The login page simply re-appears without an error message (if I use an incorrect login an error is displayed).

Any ideas on how to get back into the CMS?

Avatar
Bereusei

19 June 2013 at 4:18pm Community Member, 94 Posts

Did you get an erroroutput via email, if you set this in _config.php:

SS_Log::add_writer(new SS_LogEmailWriter('your@email.com'), SS_Log::ERR);

Avatar
MarijnKampf

24 June 2013 at 11:35pm Community Member, 164 Posts

I've tried adding the following to the live _config.php whilst login in:

define('SS_ENVIRONMENT_TYPE', 'dev');
SSViewer::set_source_file_comments(true);
ini_set('display_errors', 1);
error_reporting(E_ALL);
Director::set_environment_type("dev");

Is the email log likely to pick up more error messages that this?

Avatar
MarijnKampf

1 July 2013 at 8:37pm Community Member, 164 Posts

Finally back from holiday so I've got FTP access again. I've tried adding the email logging, but this doesn't seem to be achieving anything, I don't think any errors are generated at all when the login is cancelled/redirected back.

I've tried copying the tables Member and MemberPassword from my local staging website (where I can login) to the live version, but this didn't make any change either.

I've also tried re-uploading all cms and framework files in case one of them didn't transfer completely, but still no luck.

Anyone any ideas of what else I could try?

Avatar
MarijnKampf

17 July 2013 at 4:01am Community Member, 164 Posts

Finally managed to find an error message. after adding debugging info to the _config.php again on the live server - the email one didn't show anything.

      define('SS_ENVIRONMENT_TYPE', 'dev');
      ini_set('display_errors', 1);
      error_reporting(E_ALL);
      Director::set_environment_type("dev");

I found the following error code at the bottom of the source:

</html><!DOCTYPE html><html><head><title>GET /Security/login?BackURL=%2Fadmin%2Fpages</title><link rel="stylesheet" type="text/css" href="http://www.example.com/framework/css/debug.css" /></head><body><div class="info warning"><h1>[Warning] Unknown: write failed: No space left on device (28)</h1><h3>GET /Security/login?BackURL=%2Fadmin%2Fpages</h3><p>Line <strong>0</strong> in <strong>Unknown</strong></p></div><h3>Trace</h3><ul></ul></div></body></html><!DOCTYPE html><html><head><title>GET /Security/login?BackURL=%2Fadmin%2Fpages</title><link rel="stylesheet" type="text/css" href="http://www.example.com/framework/css/debug.css" /></head><body><div class="info warning"><h1>[Warning] Unknown: Failed to write session data (files). Please verify that the current setting of session.save_path is correct (/tmp)</h1><h3>GET /Security/login?BackURL=%2Fadmin%2Fpages</h3><p>Line <strong>0</strong> in <strong>Unknown</strong></p></div><h3>Trace</h3><ul></ul></div></body></html>

[Warning] Unknown: write failed: No space left on device (28)
[Warning] Unknown: Failed to write session data (files). Please verify that the current setting of session.save_path is correct (/tmp)

Clearing space on the /tmp folder allowed me to login again. This also explains the fact that I could mysteriously login again a couple of weeks ago as the /tmp folder is automatically cleared after rebooting the server.