News:

Want to get involved in developing SMF? Why not lend a hand on our GitHub!

Main Menu

"Session verification failed..." error after host migration

Started by Bendyman, December 18, 2017, 09:48:05 PM

Previous topic - Next topic

Bendyman

There are a lot of topics with this error but unfortunately none helps me (or I'm blind).
Symptoms: trying to log in, forum saying "wrong password" when it's 100% not, second try always work, but when i try to enter at admin settings it saying
QuoteSession verification failed. Please try logging out and back in again
So i have two hosting accounts at the same hosting provider, first works fine, but after i migrated it to second it doing this. I even wiped first one and restored it from the same backup files, still forks fine (that was stupid, do not repeat).
I found a temporary fix, problem goes away when i disable "Use database driven sessions" manually using phpMyAdmin (databaseSession_enable set to 0) cause i can't enter forum settings. All users probably have same problems with login or any actions, i didn't check.
What's causing it and how to fix without disabling database driven sessions? SMF version 2.0.11
And just in case no one knows, how bad it is to use forum without database driven sessions?

Both hosts have that message in error logs that got my attention, is it any relevant? I am quite a noob.
Quote2: Unknown: Failed to write session data (user). Please verify that the current setting of hxxp:session.save [nonactive]_path is correct (/tmp/sessions_php54)

shawnb61

First thing I'd check is the message "Failed to write session data (user). Please verify that the current setting of session.save_path is correct (/tmp/sessions_php54)".   I'd open a ticket with your host & make sure that your tmp directory is configured correctly.   I don't think that's *the* problem, but it's *a* problem... 

I have questions about moving the forum to another account on the same host:
- Did you move the database as well?
- Did you run repair_settings.php after the move to get all your settings fixed & lined up in the new location?
- Did you move it to a different subdomain? 
- Did you move it to a different subfolder?

Last questions I have are about your cookies...
- Are you using the same cookie name in the old & new locations?
- Have you cleared your cookies?
- Does clearing your cookie improve things?
A question worth asking is born in experience & driven by necessity. - Fripp

Bendyman

Thanks, i will verify after dealing with *the* problem, i even don't know what tmp directory is for

- Did you move the database as well?
Yes, exported and then imported using phpMyAdmin
- Did you run repair_settings.php after the move to get all your settings fixed & lined up in the new location?
Yes, fixed locations as well as DB server, name, username and password
- Did you move it to a different subdomain? 
Different domain, not subdomain
- Did you move it to a different subfolder?
No, same folder with changed name because of another domain

- Are you using the same cookie name in the old & new locations?
No, changed using repair_settings.php as well
- Have you cleared your cookies?
Yes
- Does clearing your cookie improve things?
No

shawnb61

A few more questions....
- What version of SMF are you running?
- Does this happen on all themes? 
- Does this happen on the SMF default curve theme?
- What mods do you have installed?

Normally clearing cookies clears these session issues, as it forces SMF to abandon the old session.  One thing I might suggest is deleting all your old sessions from before the move.  But the fact that clearing the cookie doesn't help makes me doubt that will work...  Might still be worth trying, though, if you're game. 

A question worth asking is born in experience & driven by necessity. - Fripp

Bendyman

 - What version of SMF are you running?
SMF 2.0.11, i was thinking about update, just to test if it can fix issue
- Does this happen on all themes? 
It have only default one
- Does this happen on the SMF default curve theme?
Yes, SMF default curve theme with changed header image on top of page
- What mods do you have installed?
SimplePortal   2.3.5
markItUp! for SMF   0.5.3

QuoteNormally clearing cookies clears these session issues, as it forces SMF to abandon the old session.  One thing I might suggest is deleting all your old sessions from before the move.  But the fact that clearing the cookie doesn't help makes me doubt that will work...  Might still be worth trying, though, if you're game. 
I tried clearing tables from DB - smf_sessions, and 2 another (don't remember exactly) as it was mentioned in another topic with this error. That didn't help, sorry, i've should mention it before.

I didn't install this forum, i just looking for it, so that an issue, i clearly don't know everything. May be i should update\clean install to make sure everything is perfect, don't know how to do it, need time to figure out.

Aleksi "Lex" Kilpinen

If you wish to try making it it a clean install, you can follow the the large upgrade procedure and end up with a clean set of files and updated forum at one go. It will remove installed mods and revert code changes, but all members and posts will stay.
Upgrading SMF
Slava
Ukraini!
"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum. Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

How you can help SMF


Bendyman

I've done both, "Upgrading" to latest 2.0.15 and "upload a fresh set of files", second just in case. Problem stayed but symptoms changed, now instead saying wrong password and letting me in on second try it saying "Session verification failed..." error immediately after login try. And whether i just noticed or it's new, showing this message at bottom of all pages when "database driven sessions" is on.
Quote from: messageConnection Problems Sorry, SMF was unable to connect to the database. This may be caused by the server being busy. Please try again later.
Database is clearly ok cause it showing all topics, messages and works fine when i turn off "database driven sessions" with the same DB login info.
I am basically gave up at this point, and either continue to use it with "database driven sessions" off or ask hosting provider to move payment on the first account, so i don't need to migrate at all.

Aleksi "Lex" Kilpinen

Are you using a custom a theme, or does that session verification error come with the default theme?
- Edit: Sorry, rereading your earlier responses, yes. Default theme.

Did you get your host to look at the error about session data?
Slava
Ukraini!
"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum. Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

How you can help SMF

Bendyman

No i don't, should i? Not sure if they can or should help.
As i said earlier i just gave up and forum working with database driven sessions off. So problem not solved, i use work around.
You can probably close topic if you want, or how you used to do it here :)

GigaWatt

Marking this as solved. If you want to solve the database driven sessions problem in the future, write in this thread or open a new one ;).
"This is really a generic concept about human thinking - when faced with large tasks we're naturally inclined to try to break them down into a bunch of smaller tasks that together make up the whole."

"A 500 error loosely translates to the webserver saying, "WTF?"..."

Advertisement: