Skip to content
This repository has been archived by the owner on Jan 15, 2019. It is now read-only.

[dev.icinga.com #3727] On second login: Uncaught Doctrine_Hydrator_Exception thrown: #1037

Closed
icinga-migration opened this issue Feb 21, 2013 · 8 comments

Comments

@icinga-migration
Copy link

This issue has been migrated from Redmine: https://dev.icinga.com/issues/3727

Created by smarx on 2013-02-21 19:34:53 +00:00

Assignee: mfrosch
Status: Resolved (closed on 2013-03-17 11:57:32 +00:00)
Target Version: 1.8.3
Last Update: 2013-03-17 11:57:32 +00:00 (in Redmine)

Icinga Version: 1.8.4
Icinga Web Version: 1.8.2
IDO Version: 1.8.4
OS Version: RHEL 6.4
DB Type: MySQL
DB Version: 5.1.67
Browser Version: Chromium 24.0.1312.52 (175374)

On a freshly installed icinga-web (with added lconf_mod) 1.8.2 running on the latest ido-utils with mysql and icinga 1.8.4 (installed on RHEL 6.4), I can login as root:password. After logging out and logging in again the following error is thrown:

Uncaught Doctrine_Hydrator_Exception thrown:
Couldn't hydrate. Found non-unique key mapping named 'org.icinga.ext.appstate' for the field named 'upref_key'.

I have appended the stacktrace.

Because I found something similar in here regarding the postgres-db (Issue:3530), I did the following:

I dropped the icinga_web database, I reinstalled the schema and the lconf-extensions and then I was able to log in again. ( Just to do sth., I added the lconf-credentials to root) I logged out and the same error occured on the second try to login.

I mention the lconf_mod part only for being complete in description, the error seems unrelated to lconf_mod. I will try to reproduce this without the lconf_mod-extensions.

Attachments

  • stacktrace smarx - 2013-02-21 19:34:54 +00:00 - stacktrace

Changesets

2013-03-17 09:29:14 +00:00 by mfrosch f20a872

Disabled storing user preferences into the session data (refs #3727)

2013-03-17 10:33:11 +00:00 by mfrosch 168115c

Disabled storing user preferences into the session data (refs #3727)

Relations:

@icinga-migration
Copy link
Author

Updated by smarx on 2013-02-21 19:38:05 +00:00

Ok, just tried completely without the lconf stuff: same bug.

@icinga-migration
Copy link
Author

Updated by mfrosch on 2013-02-22 15:38:33 +00:00

  • Status changed from New to Assigned
  • Assigned to set to mfrosch

Interesting problem, I'll have a look inside the code.

Did this bug came up with 1.8.2, or was this your first installation?

@icinga-migration
Copy link
Author

Updated by mfrosch on 2013-02-22 17:39:41 +00:00

Looks like the error happens when the nsm_user_preferences table does not have a entry for appstate yet and tries to insert it, which could happen twice when the server is a bit slow...

@icinga-migration
Copy link
Author

Updated by chrisjx on 2013-02-25 23:49:59 +00:00

Newbie, here... but I'm getting this same error on first login.

New Install...
Ubuntu: 12.04.2 LTS
Icinga: 1.8.4
Icinga-web: 1.8.2 (using the root/password login)
MySQL: 5.5.29

I can't be sure my configuration is correct...

@icinga-migration
Copy link
Author

Updated by smarx on 2013-02-26 21:36:56 +00:00

After this happens again and again to me, especially on installs on VMWare ESX or VirtualBox, we found some sort of quickfix, that helped at least to get a login again, and I could log out and log in again flawlessly after that (stopped trying after 3rd try ;-) ):

mysql -u root -p icinga_web -e 'delete from nsm_user_preference where upref_id=2;'

did that magic. Hope this helps.

@icinga-migration
Copy link
Author

Updated by mfriedrich on 2013-03-08 10:11:07 +00:00

  • Target Version set to 1.8.3

@icinga-migration
Copy link
Author

Updated by mfrosch on 2013-03-17 10:18:08 +00:00

We isolated the error to be caused by saving user preference cache into the user's session.

This will be disabled in 1.8.3

@icinga-migration
Copy link
Author

Updated by mfrosch on 2013-03-17 11:57:32 +00:00

  • Category set to Architecture
  • Status changed from Assigned to Resolved
  • Done % changed from 0 to 100

Pushed to next/r1.8

As said before we disabled caching into session data for all user preferences.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant