Content
Error ActiveRecord::StatementInvalid in AccountController#login after Plugin Installation
Added by Daniel Collet about 10 years ago
Hi
Since aweek i have succefully installed openproject on a ubuntu server, with help of the installation doku and google. yesteday in the evening I was able to configure the installation, that also the plugins (meeting, costs, backlog, pdf) where installed on openproject.
This early morning OP runs normally. after 9am i could’nt login. There was this error message:
ActiveRecord::StatementInvalid in AccountController#login
app/models/user.rb:405:in `log_failed_login’
app/models/user.rb:868:in `register_failed_login_attempt_if_user_exists_for’
app/models/user.rb:860:in `prevent_brute_force_attack’
app/models/user.rb:259:in `try_to_login’
app/controllers/account_controller.rb:189:in `password_authentication’
app/controllers/account_controller.rb:184:in `authenticate_user’
app/controllers/account_controller.rb:41:in `login’
Since then, I couldn’t login as normal user, nor as admin. OP appears nomral, until I want to login. I restart the ubuntu-server, also the ruby server. Also I rebundle the OP installation. No effect.
Has somebody a idea what happens?
Greeting
Daniel
Replies (6)
I have additional information: The ubuntu rails server says:
MYSQL2:Error: Table’openproject_development.rates’ doen’t exists: SHOW FULL FIELDS FROM ‘rates’
Daniel
I have now configure the Gemfile.plugins and disabled all Plugins. Now I can Login again. I looking Forward to reactivate the plugins, what will happens….
after reinstalling the plugins the error raises again. so I will disable the cost modul.
even with disabled an rebundled configuration, I have severel errors in creating WorkPackages:
oMethodError in WorkPackagesController#create
undefined method `position’ for #WorkPackage:0x0000001fe7c808
As ubuntu and rails newbee, i have no idea how to fix it or go pack to the base installation.
Hi, good morning
We have the same problem on Ubuntu, with the latest 3.0 version
See attached file also please
ActiveRecord::StatementInvalid in AccountController#login
Mysql2::Error: Table ‘openproject_development.rates’ doesn’t exist: SHOW FULL FIELDS FROM `rates`
Rails.root: /home/openproject/openproject
Application Trace | Framework Trace | Full Trace
app/models/user.rb:873:in `reset_failed_login_count_for’
app/models/user.rb:880:in `block_user_if_too_many_recent_attempts_failed’
app/models/user.rb:862:in `prevent_brute_force_attack’
app/models/user.rb:259:in `try_to_login’
app/controllers/account_controller.rb:189:in `password_authentication’
app/controllers/account_controller.rb:184:in `authenticate_user’
app/controllers/account_controller.rb:41:in `login’
Request
Parameters:
{“utf8”=>“✓”,
“authenticity_token”=>“JMHyN60Q6fUIppHYx15qhECJkUn4O1BVwVxisLUNhGE=”,
“back_url”=>“……”,
“username”=>“admin”,
“password”=>“[FILTERED]”,
“login”=>“Login”}
Can somebody advice please?
Thanks !
Hi,
if you get such an error after you installed a plugin you had forgotten to run the migrations.
Go to the the OpenProject root folder and run the migrations.
It looks like you run OpenProject in development environment so you have to run this:
For production environment you have to run it like this:
Best
Ratzi