Ok slightly strange thing happening on all out Umbraco sites, I had to reboot our 1&1 server after upgrading the cloud memory etc... and now as soon as I login into any Umbraco site I'm logged out within 10 seconds?
I'm completely miffed? Anyone experienced anything similar before?
So I have just checked its not a server wide thing with all sites, I have tried three NopCommerce sites and a couple of ASP sites and they are fine? Its only the Umbraco sites on the server that its happening too? :S
Any pointers as to where to start looking would be great. Front end of the sites are fine, its just when you login to the Umbraco admin within a few seconds it just redirects to the login page as if I have pressed logout?
Could be cookie related? If it's logging you out, that means the umbraco context cookie has probably vanished. After logging in, find the umbraco context cookie, then after it's punted you out, check to see if its still there. If it's gone, its an issue there (not sure what might be causing it though).
Seems really weird to me, what version of Chrome are you using?
It might be worth also downloading Fiddler and seeing if there is anything obviously wrong coming back from the server, what is the cookie expiration date?
It shouldn't the Umbraco code sets the cookie to expire 1 day from server time.
// Create new cookie.
System.Web.HttpCookie c = new System.Web.HttpCookie("UserContext");
c.Name = "UserContext";
c.Value = value;
c.Expires = DateTime.Now.AddDays(1);
System.Web.HttpContext.Current.Response.Cookies.Add(c);
It might be worth trying to upload a page which outputs the server time, just to rule out that it's hasn't been set completly wrongly on the new server, but still, it seems strange, 8 seconds less than a day out..
Ian top man, you made me open my eyes on the server... Found the problem, how weird is this... BOTH servers date was a day behind, they were showing 9th! Changed it to the 10th and works perfectly :)
All sorted now Tim, thanks for the fault finding help... No one has touched the date/time on the servers so its definitely something 1&1 have done with moving the cloud servers to a new node.
Constant Automatic Logging Out?
Ok slightly strange thing happening on all out Umbraco sites, I had to reboot our 1&1 server after upgrading the cloud memory etc... and now as soon as I login into any Umbraco site I'm logged out within 10 seconds?
I'm completely miffed? Anyone experienced anything similar before?
So I have just checked its not a server wide thing with all sites, I have tried three NopCommerce sites and a couple of ASP sites and they are fine? Its only the Umbraco sites on the server that its happening too? :S
Any pointers as to where to start looking would be great. Front end of the sites are fine, its just when you login to the Umbraco admin within a few seconds it just redirects to the login page as if I have pressed logout?
Now I am even more confused... If I use Firefox, its fine and doesn't log me out? Works without a problem!!
If I use Chrome or IE I get logged out after a few seconds?? Help...
Could really use some advice from a techy if there are any on here? :S
Bump... Still happening :( Any ideas on where I could look? Nothing in UmbracoLog :S
Could be cookie related? If it's logging you out, that means the umbraco context cookie has probably vanished. After logging in, find the umbraco context cookie, then after it's punted you out, check to see if its still there. If it's gone, its an issue there (not sure what might be causing it though).
Hey Tim - Thanks for the help. The cookie is disappearing, I login and the below cookie is added (This is using Chrome)
When I'm logged out the UserContext cookie is not present? I'm miffed as to why its just started happening when these sites have been fine!
Seems really weird to me, what version of Chrome are you using?
It might be worth also downloading Fiddler and seeing if there is anything obviously wrong coming back from the server, what is the cookie expiration date?
Perhaps there is an issue with the server time?
Hi Ian.. You have something with the expiration time, have a look at this
Why on earth would it be setting the expiration to 10 seconds?
It shouldn't the Umbraco code sets the cookie to expire 1 day from server time.
It might be worth trying to upload a page which outputs the server time, just to rule out that it's hasn't been set completly wrongly on the new server, but still, it seems strange, 8 seconds less than a day out..
Ian top man, you made me open my eyes on the server... Found the problem, how weird is this... BOTH servers date was a day behind, they were showing 9th! Changed it to the 10th and works perfectly :)
Thanks for the help, really appreciate it
What Ian said, and in Firefox, what does it list the cookie expiration as (as that seems to work correctly)?
All sorted now Tim, thanks for the fault finding help... No one has touched the date/time on the servers so its definitely something 1&1 have done with moving the cloud servers to a new node.
I am hving this issue – where can I find the cookie setting code? Do I just add another day to it?
is working on a reply...