Project

General

Profile

Install issue on windows

Added by Annabelle Armand almost 13 years ago

Hello,

I'm trying to install Redmine on my computer and I have some issues.
Config : PC - win 7 - 32 bits

Everything worked fine until the "rake db:migrate" command-line.

Here are the infos about my install :

- my.ini :

# CLIENT SECTION
# ----------------------------------------------------------------------
[client]
port=3307
[mysql]
default-character-set=utf8

# SERVER SECTION
# ----------------------------------------------------------------------
[mysqld]
port=3307
basedir="C:/webserver/MySQL/" 
datadir="C:/webserver/MySQL_Data/Data/" 
default-character-set=utf8
default-storage-engine=INNODB
sql-mode="STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION" 
max_connections=100
query_cache_size=0
table_cache=256
tmp_table_size=18M
thread_cache_size=8
myisam_max_sort_file_size=100G
myisam_sort_buffer_size=35M
key_buffer_size=25M
read_buffer_size=64K
read_rnd_buffer_size=256K
sort_buffer_size=256K
innodb_data_home_dir="C:/webserver/MySQL_Data/innodb_tablespace/" 
#skip-innodb
innodb_additional_mem_pool_size=2M
innodb_flush_log_at_trx_commit=1
innodb_log_buffer_size=1M
innodb_buffer_pool_size=47M
innodb_log_file_size=24M
innodb_thread_concurrency=8

- datatbase.yml :

production:
  adapter: mysql
  database: redmine
  host: localhost
  username: root
  password: ****
  encoding: utf8

- gem list :

actionmailer (2.3.5)
actionpack (2.3.5)
activerecord (2.3.5)
activeresource (2.3.5)
activesupport (2.3.5)
cgi_multipart_eof_fix (2.5.0)
gem_plugin (0.2.3)
i18n (0.4.2)
mongrel (1.1.5 x86-mingw32)
mongrel_service (0.3.4 i386-mswin32)
mysql (2.8.1 x86-mingw32)
rack (1.1.0, 1.0.1)
rails (2.3.5)
rake (0.8.7)
win32-service (0.5.2 mswin32)

- Connecting to mysql OK :

C:\webserver\Redmine>mysql -u root -p
Enter password: ****
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 22
Server version: 5.1.57-community MySQL Community Server (GPL)

Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
This software comes with ABSOLUTELY NO WARRANTY. This is free software,
and you are welcome to modify and redistribute it under the GPL v2 license

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql>

- Using redmine database, freshly created, OK :

mysql> use redmine
Database changed
mysql>

- Trying to create tables :

C:\webserver\Redmine>rake db:migrate
(in C:/webserver/Redmine)
rake aborted!
Can't connect to MySQL server on 'localhost' (10061)

Can anyone help me with this issue ?

Thanks a lot


Replies (9)

RE: Install issue on windows - Added by Alex A almost 13 years ago

Can u show mysql.conf file ?

RE: Install issue on windows - Added by Annabelle Armand almost 13 years ago

Where do I find this file ?
Is it different from the "my.ini" file ?
Thank you :)

RE: Install issue on windows - Added by Alex A almost 13 years ago

File like this

# Example mysql config file.
# Copy this file to c:/my.cnf to set global options
# 
# One can use all long options that the program supports.
# Run the program with --help to get a list of available options

# Here is entries for some specific programs
# The following values assume you have at least 32M ram

# The MySQL server
[mysqld]
bind-address=127.0.0.1
tmpdir=/tmp
character-sets-dir=/usr/local/mysql/share/charsets

#socket=MySQL
port=3306
skip-locking
default-character-set=win1251
set-variable = key_buffer=5M
set-variable = max_allowed_packet=1M
set-variable = thread_stack=128K
set-variable = flush_time=1800

# Uncomment the following rows if you move the MySQL distribution 
# to another location
basedir = /usr/local/mysql/
datadir = /usr/local/mysql/data/

# Uncomment the following rows if you are using InnoDB tables
# Create the directories ibdata and iblogs before to start the server.
# If necessary, modify the size of the files

innodb_data_file_path = ibdata1:10M
innodb_data_home_dir = /usr/local/mysql/ibdata
set-variable = innodb_mirrored_log_groups=1
innodb_log_group_home_dir = /usr/local/mysql/ibdata
set-variable = innodb_log_files_in_group=3
set-variable = innodb_log_file_size=5M
set-variable = innodb_log_buffer_size=1M
innodb_flush_log_at_trx_commit=1
innodb_log_arch_dir = /usr/local/mysql/ibdata
innodb_log_archive=0
set-variable = innodb_buffer_pool_size=10M
set-variable = lower_case_table_names =0
set-variable = innodb_additional_mem_pool_size=5M
set-variable = innodb_file_io_threads=4
set-variable = innodb_lock_wait_timeout=50

# Uncomment the following row if you are using a Max server and 
# you don't want the InnoDb tables
skip-innodb
#skip-bdb

RE: Install issue on windows - Added by Annabelle Armand almost 13 years ago

OK, this is the first file I've put in my request, "my.ini"
I've deleted comments to make it readable on the thread.
Do you wish me to post it full ?

RE: Install issue on windows - Added by Alex A almost 13 years ago

No. Compare with your config file and corret your file like this one.

RE: Install issue on windows - Added by Annabelle Armand almost 13 years ago

I've tried to correct my file with missing datas, but now, mysql server don't even launch anymore...
First I had error with "set-variable" which is a deprecated option :

110621 11:53:03 [Warning] C:\webserver\MySQL\bin\mysqld: Option '--set-variable' is deprecated. Use --variable-name=value instead.

So I used "variable-name" to avoid warning, but server still doesn't start.

- Here is my.ini file (corrected) :

# CLIENT SECTION
# ----------------------------------------------------------------------
[client]
port=3307
[mysql]
default-character-set=utf8

# SERVER SECTION
# ----------------------------------------------------------------------
[mysqld]
bind-address=localhost
port=3307
skip-locking
default-character-set=utf8
variable-name = key_buffer=5M
set-variable = max_allowed_packet=1M
set-variable = thread_stack=128K
set-variable = flush_time=1800
basedir="C:/webserver/MySQL/" 
datadir="C:/webserver/MySQL_Data/Data/" 
default-storage-engine=INNODB
sql-mode="STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION" 
max_connections=100
query_cache_size=0
table_cache=256
tmp_table_size=18M
thread_cache_size=8
myisam_max_sort_file_size=100G
myisam_sort_buffer_size=35M
key_buffer_size=25M
read_buffer_size=64K
read_rnd_buffer_size=256K
sort_buffer_size=256K
innodb_data_file_path = innodb_tablespace:10M
innodb_data_home_dir="C:/webserver/MySQL_Data/innodb_tablespace/" 
set-variable = innodb_mirrored_log_groups=1
innodb_log_group_home_dir = "C:/webserver/MySQL_Data/innodb_tablespace/" 
set-variable = innodb_log_files_in_group=3
set-variable = innodb_log_file_size=5M
set-variable = innodb_log_buffer_size=1M
innodb_flush_log_at_trx_commit=1
innodb_log_arch_dir = "C:/webserver/MySQL_Data/innodb_tablespace/" 
innodb_log_archive=0
set-variable = innodb_buffer_pool_size=10M
set-variable = lower_case_table_names =0
set-variable = innodb_additional_mem_pool_size=5M
set-variable = innodb_file_io_threads=4
set-variable = innodb_lock_wait_timeout=50
#skip-innodb
innodb_log_buffer_size=1M
innodb_buffer_pool_size=47M
innodb_log_file_size=24M
innodb_thread_concurrency=8

- Here are the errors when starting mysqld :

110621 12:00:27 [Note] Plugin 'FEDERATED' is disabled.
110621 12:00:27  InnoDB: Initializing buffer pool, size = 47.0M
110621 12:00:27  InnoDB: Completed initialization of buffer pool
110621 12:00:27  InnoDB: Started; log sequence number 0 44233
110621 12:00:27 [ERROR] C:\webserver\MySQL\bin\mysqld: unknown variable 'variable-name=key_buffer=5M'
110621 12:00:27 [ERROR] Aborting

110621 12:00:27  InnoDB: Starting shutdown...
110621 12:00:33  InnoDB: Shutdown completed; log sequence number 0 44233
110621 12:00:33 [Note] C:\webserver\MySQL\bin\mysqld: Shutdown complete

RE: Install issue on windows: having the same problem - Added by Vlad Kamen almost 13 years ago

I am having the same problem with fresh install of Ruby 1.2.0 on top of MySQL 5.5.
Here is the log of db:migrate

C:\Redmine\redmine-1.2.0>rake db:migrate
rake/rdoctask is deprecated. Use rdoc/task instead (in RDoc 2.4.2+)
WARNING: 'task :t, arg, :needs => [deps]' is deprecated. Please use 'task :t, [
args] => [deps]' instead.
at C:/Redmine/redmine-1.2.0/lib/tasks/email.rake:170
rake aborted!
Mysql::Error: query: not connected: CREATE TABLE `schema_migrations` (`version`
varchar(255) NOT NULL) ENGINE=InnoDB

Tasks: TOP => db:migrate
(See full trace by running task with --trace)
C:/Ruby187/bin/rake:19: [BUG] Segmentation fault
ruby 1.8.7 (2011-02-18 patchlevel 334) [i386-mingw32]

This application has requested the Runtime to terminate it in an unusual way.
Please contact the application's support team for more information.

C:\Redmine\redmine-1.2.0>

RE: Install issue on windows - Added by Annabelle Armand almost 13 years ago

I still have the issue with mysqld start.
Can anyone help me with this ?
Do I have to get the my.ini file back to previous state ?
Is there something more to install to have Redmine work on Windows ?
Thank you for your help.

RE: Install issue on windows: having the same problem - Added by Annabelle Armand almost 13 years ago

Vlad Kamen wrote:

I am having the same problem with fresh install of Ruby 1.2.0 on top of MySQL 5.5.
Here is the log of db:migrate

C:Redmine

edmine-1.2.0>rake db:migrate

rake/rdoctask is deprecated. Use rdoc/task instead (in RDoc 2.4.2+)
WARNING: 'task :t, arg, :needs => [deps]' is deprecated. Please use 'task :t, [
args] => [deps]' instead.
at C:/Redmine/redmine-1.2.0/lib/tasks/email.rake:170
rake aborted!
Mysql::Error: query: not connected: CREATE TABLE `schema_migrations` (`version`
varchar(255) NOT NULL) ENGINE=InnoDB

Tasks: TOP => db:migrate
(See full trace by running task with --trace)
C:/Ruby187/bin/rake:19: [BUG] Segmentation fault
ruby 1.8.7 (2011-02-18 patchlevel 334) [i386-mingw32]

This application has requested the Runtime to terminate it in an unusual way.
Please contact the application's support team for more information.

C:Redmine

edmine-1.2.0>

The answer to your problem is in the install tutorial
("Install Redmine" chapter - Point 6)

If you encounter this error: Mysql::Error: query: not connected: CREATE TABLE `schema_migrations` (`version` varchar(255) NOT NULL) ENGINE=InnoDB :
download libmySQL.dll from here
move this .dll file to C:\webserver\Ruby\bin\

    (1-9/9)