/********************************************************************
* Redmine 数据库连接错误
* 说明:
* OpenMediaVault上的Redmine出现连接错误,目前不知道是我自己不小心
* 把mysql的密码修改了,还是因为被攻击了,先记录一下。
*
* 2016-8-17 深圳 南山平山村 曾剑锋
*******************************************************************/ 一、参考文档:
. 完整过程解决 ERROR (): Access denied for user 'mysql'@'localhost' (using password: NO)
http://blog.csdn.net/nel0511/article/details/13091163 二、错误现象:
root@workflow:/etc# ruby /usr/share/redmine/bin/rails server -p3000 webrick -e production &
[]
root@workflow:/etc# => Booting WEBrick
=> Rails 3.1. application starting in production on http://0.0.0.0:3000
=> Run `rails server -h` for more startup options
=> Notice: server is listening on all interfaces (0.0.0.0). Consider using 127.0.0.1 (--binding option)
=> Ctrl-C to shutdown server
Exiting
/usr/lib/ruby/vendor_ruby/mysql2/client.rb::in `connect': Access denied for user 'root'@'localhost' (using password: YES) (Mysql2::Error)
from /usr/lib/ruby/vendor_ruby/mysql2/client.rb::in `initialize'
from /usr/lib/ruby/vendor_ruby/active_record/connection_adapters/mysql2_adapter.rb::in `new'
from /usr/lib/ruby/vendor_ruby/active_record/connection_adapters/mysql2_adapter.rb::in `mysql2_connection'
from /usr/lib/ruby/vendor_ruby/active_record/connection_adapters/abstract/connection_pool.rb::in `new_connection'
from /usr/lib/ruby/vendor_ruby/active_record/connection_adapters/abstract/connection_pool.rb::in `checkout_new_connection'
from /usr/lib/ruby/vendor_ruby/active_record/connection_adapters/abstract/connection_pool.rb::in `acquire_connection'
from /usr/lib/ruby/vendor_ruby/active_record/connection_adapters/abstract/connection_pool.rb::in `block in checkout'
from /usr/lib/ruby/1.1./monitor.rb::in `mon_synchronize'
from /usr/lib/ruby/vendor_ruby/active_record/connection_adapters/abstract/connection_pool.rb::in `checkout'
from /usr/lib/ruby/vendor_ruby/active_record/connection_adapters/abstract/connection_pool.rb::in `block in connection'
from /usr/lib/ruby/1.1./monitor.rb::in `mon_synchronize'
from /usr/lib/ruby/vendor_ruby/active_record/connection_adapters/abstract/connection_pool.rb::in `connection'
from /usr/lib/ruby/vendor_ruby/active_record/connection_adapters/abstract/connection_pool.rb::in `retrieve_connection'
from /usr/lib/ruby/vendor_ruby/active_record/connection_handling.rb::in `retrieve_connection'
from /usr/lib/ruby/vendor_ruby/active_record/connection_handling.rb::in `connection'
from /usr/lib/ruby/vendor_ruby/active_record/model_schema.rb::in `table_exists?'
from /usr/lib/ruby/vendor_ruby/active_record/attribute_methods/primary_key.rb::in `get_primary_key'
from /usr/lib/ruby/vendor_ruby/active_record/attribute_methods/primary_key.rb::in `reset_primary_key'
from /usr/lib/ruby/vendor_ruby/active_record/attribute_methods/primary_key.rb::in `primary_key'
from /usr/lib/ruby/vendor_ruby/active_record/mass_assignment_security/attribute_assignment.rb::in `attributes_protected_by_default'
from /usr/lib/ruby/vendor_ruby/active_model/mass_assignment_security.rb::in `block in protected_attributes_configs'
from /usr/lib/ruby/vendor_ruby/active_model/mass_assignment_security.rb::in `yield'
from /usr/lib/ruby/vendor_ruby/active_model/mass_assignment_security.rb::in `protected_attributes'
from /usr/lib/ruby/vendor_ruby/active_model/mass_assignment_security.rb::in `block in attr_protected'
from /usr/lib/ruby/vendor_ruby/active_model/mass_assignment_security.rb::in `each'
from /usr/lib/ruby/vendor_ruby/active_model/mass_assignment_security.rb::in `attr_protected'
from /usr/share/redmine/app/models/custom_field.rb::in `<class:CustomField>'
from /usr/share/redmine/app/models/custom_field.rb::in `<top (required)>'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `require'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `block in require'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `load_dependency'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `require'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `require_or_load'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `load_missing_constant'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `const_missing'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `load_missing_constant'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `const_missing'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `load_missing_constant'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `const_missing'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `load_missing_constant'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `const_missing'
from /usr/share/redmine/lib/redmine/field_format.rb::in `field_attributes'
from /usr/share/redmine/lib/redmine/field_format.rb::in `<class:Base>'
from /usr/share/redmine/lib/redmine/field_format.rb::in `<module:FieldFormat>'
from /usr/share/redmine/lib/redmine/field_format.rb::in `<module:Redmine>'
from /usr/share/redmine/lib/redmine/field_format.rb::in `<top (required)>'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `require'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `block in require'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `load_dependency'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `require'
from /usr/share/redmine/lib/redmine.rb::in `<top (required)>'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `require'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `block in require'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `load_dependency'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `require'
from /usr/share/redmine/config/initializers/-redmine.rb::in `<top (required)>'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `load'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `block in load'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `load_dependency'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `load'
from /usr/lib/ruby/vendor_ruby/rails/engine.rb::in `block in load_config_initializer'
from /usr/lib/ruby/vendor_ruby/active_support/notifications.rb::in `instrument'
from /usr/lib/ruby/vendor_ruby/rails/engine.rb::in `load_config_initializer'
from /usr/lib/ruby/vendor_ruby/rails/engine.rb::in `block ( levels) in <class:Engine>'
from /usr/lib/ruby/vendor_ruby/rails/engine.rb::in `each'
from /usr/lib/ruby/vendor_ruby/rails/engine.rb::in `block in <class:Engine>'
from /usr/lib/ruby/vendor_ruby/rails/initializable.rb::in `instance_exec'
from /usr/lib/ruby/vendor_ruby/rails/initializable.rb::in `run'
from /usr/lib/ruby/vendor_ruby/rails/initializable.rb::in `block in run_initializers'
from /usr/lib/ruby/1.1./tsort.rb::in `block in tsort_each'
from /usr/lib/ruby/1.1./tsort.rb::in `block ( levels) in each_strongly_connected_component'
from /usr/lib/ruby/1.1./tsort.rb::in `block ( levels) in each_strongly_connected_component_from'
from /usr/lib/ruby/1.1./tsort.rb::in `each_strongly_connected_component_from'
from /usr/lib/ruby/1.1./tsort.rb::in `block in each_strongly_connected_component_from'
from /usr/lib/ruby/vendor_ruby/rails/initializable.rb::in `each'
from /usr/lib/ruby/vendor_ruby/rails/initializable.rb::in `tsort_each_child'
from /usr/lib/ruby/1.1./tsort.rb::in `call'
from /usr/lib/ruby/1.1./tsort.rb::in `each_strongly_connected_component_from'
from /usr/lib/ruby/1.1./tsort.rb::in `block in each_strongly_connected_component'
from /usr/lib/ruby/1.1./tsort.rb::in `each'
from /usr/lib/ruby/1.1./tsort.rb::in `call'
from /usr/lib/ruby/1.1./tsort.rb::in `each_strongly_connected_component'
from /usr/lib/ruby/1.1./tsort.rb::in `tsort_each'
from /usr/lib/ruby/1.1./tsort.rb::in `tsort_each'
from /usr/lib/ruby/vendor_ruby/rails/initializable.rb::in `run_initializers'
from /usr/lib/ruby/vendor_ruby/rails/application.rb::in `initialize!'
from /usr/share/redmine/config/environment.rb::in `<top (required)>'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `require'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `block in require'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `load_dependency'
from /usr/lib/ruby/vendor_ruby/active_support/dependencies.rb::in `require'
from /usr/share/redmine/config.ru::in `block in <main>'
from /usr/lib/ruby/vendor_ruby/rack/builder.rb::in `instance_eval'
from /usr/lib/ruby/vendor_ruby/rack/builder.rb::in `initialize'
from /usr/share/redmine/config.ru:in `new'
from /usr/share/redmine/config.ru:in `<main>'
from /usr/lib/ruby/vendor_ruby/rack/builder.rb::in `eval'
from /usr/lib/ruby/vendor_ruby/rack/builder.rb::in `new_from_string'
from /usr/lib/ruby/vendor_ruby/rack/builder.rb::in `parse_file'
from /usr/lib/ruby/vendor_ruby/rack/server.rb::in `build_app_and_options_from_config'
from /usr/lib/ruby/vendor_ruby/rack/server.rb::in `app'
from /usr/lib/ruby/vendor_ruby/rails/commands/server.rb::in `app'
from /usr/lib/ruby/vendor_ruby/rack/server.rb::in `wrapped_app'
from /usr/lib/ruby/vendor_ruby/rack/server.rb::in `start'
from /usr/lib/ruby/vendor_ruby/rails/commands/server.rb::in `start'
from /usr/lib/ruby/vendor_ruby/rails/commands/commands_tasks.rb::in `block in server'
from /usr/lib/ruby/vendor_ruby/rails/commands/commands_tasks.rb::in `tap'
from /usr/lib/ruby/vendor_ruby/rails/commands/commands_tasks.rb::in `server'
from /usr/lib/ruby/vendor_ruby/rails/commands/commands_tasks.rb::in `run_command!'
from /usr/lib/ruby/vendor_ruby/rails/commands.rb::in `<top (required)>'
from /usr/share/redmine/bin/rails::in `require'
from /usr/share/redmine/bin/rails::in `<main>' []+ Exit ruby /usr/share/redmine/bin/rails server -p3000 webrick -e production 三、解决办法:
修改数据库root密码。

Redmine 数据库连接错误的更多相关文章

  1. kettle菜鸟学习笔记3----kettle数据库连接错误及解决

    数据库连接测试时,所有的参数信息都填写正确,却报错了. 或者,没有进行数据库连接测试,直接保存了当前数据库连接,然后在浏览,选择目标表时报错: 或者其他别的关于数据库连接的错误…… 第一个要考虑的就是 ...

  2. win下安装Redmine常见错误解决方案

    成长型公司,最近需要项目管理的软件,所以在windows的服务器上搭建了redmine,其中也遇到了两个坑,现记录下来. Redmine是用Ruby开发的基于web的项目管理软件,是用ROR框架开发的 ...

  3. web页面过一段时间再次访问时显示数据库连接错误

    这个问题是我之前遇到的,过了很久才想着去解决它,因为这也没多大影响,无非就是再访问一次的问题,后来有一次观察网站的运行情况时,发现这个问题还挺严重,如果一直用,就不会出现问题,如果中间歇一会,再用就会 ...

  4. SQL数据库 开启时出现 数据库连接错误2,error:40的问题。如何解决

    错误如下:(原因是sql server服务停止) 解决这个问题,就需要启动sql server服务:主要有三种方法: 一.(后台启动服务) 1.开始->控制面板: 2.管理工具 3.服务 4.把 ...

  5. 网站配置好了,在本地能登录系统,但是挂在IIS上就无法登录了,提示数据库连接错误

    我用的VS2010开发的网站,但是挂在本机的IIS上的时候就无法登录了,提示错误如下:

  6. Java数据库连接错误集

    com.mysql.jdbc.exceptions.jdbc4.MySQLNonTransientConnectionException: No operations allowed after co ...

  7. .NET 通过entity framework报数据库连接错误:ORA-01017: invalid username/password; logon denied

    如题,答案为:[ORA-01017].NET程序连接数据库失败 转载文章内容如下: 遇到问题 使用 C#/.NET 开发的一个客户端程序,需要连接 ORACLE 数据库,使用 Oracle.Manag ...

  8. Foxpro数据库连接错误解决方法--【VFP DBF文件不是一个有效的路径。 确定路径名称拼写是否正确,以及是否连接到文件存放的服务器】

    直接访问vfp dbf文件时报错: 错误描述: 'd:\vfpData\test.dbf'不是一个有效的路径. 确定路径名称拼写是否正确,以及是否连接到文件存放的服务器. 解决办法:Data Sour ...

  9. oracle数据库连接错误解决办法

    ORA-28547 连接服务器失败,可能是Oracle Net 管理错误 原文地址:http://www.linuxidc.com/Linux/2014-11/109686.htm 上周去给客户培训O ...

随机推荐

  1. Java并发编程实战 读书笔记(二)

    关于发布和逸出 并发编程实践中,this引用逃逸("this"escape)是指对象还没有构造完成,它的this引用就被发布出去了.这是危及到线程安全的,因为其他线程有可能通过这个 ...

  2. java验证身份证号码是否有效源代码 wn25的头像 wn25 23 2015-01-04 20:09 6 基本信息 Java × 1 浏览

    原文:http://www.open-open.com/code/view/1420373343171 1.描述 用java语言判断身份证号码是否有效,地区码.出身年月.校验码等验证算法 2.源代码 ...

  3. 创建注记图层C# IFeatureWorkspaceAnno

    http://blog.csdn.net/mydriverc/article/details/1675613     //IFeatureWorkspaceAnno Example     //The ...

  4. 使用图片作为textview组件的背景

    <TextView android:layout_gravity="center" android:layout_width="100dp" androi ...

  5. ARM汇编指令MCR/MRC学习

    MCR指令将ARM处理器的寄存器中的数据传送到协处理器的寄存器中.假设协处理器不能成功地运行该操作.将产生没有定义的指令异常中断. 指令的语法格式: MCR{<cond>} p15, 0, ...

  6. [WASM] Create a New Rust/Webpack Project using the rust-webpack Template

    Previous to this post, we set up our own Rust/wasm project from scratch. The Rust/wasm team ships a ...

  7. Linux下的ELF可执行文件的格式解析 (转)

    LInux命令只是和Kernel一起被编译进操作系统的存在于FS的ELF格式二进制文件,或者权限足够的脚本,或者一个软链 ELF(Executable and Linking Format)是一种对象 ...

  8. LOCAL_CFLAGS参数说明

    1.-Wall 是打开警告开关 2.-O 代表默认优化,可选:-O0不优化,-O1低级优化,-O2中级优化,-O3高级优化,-Os代码空间优化 3.-g 是生成调试信息,生成的可执行文件具有和源代码关 ...

  9. HDOJ 1217 Arbitrage(拟最短路,floyd算法)

    Arbitrage Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others) Total ...

  10. 【转载】VS工具使用——代码生成函数关系图

    小引:        在上篇文章<VS工具使用--代码图>中,我向大家介绍了我对工具"代码图"的发现和认识.真是感觉当自己的眼睛不再被蒙蔽的时候,会发现整个世界的美好. ...