1

Jump below for solution with Stable Release. Currently I am working on an older release of redmine with older ruby, and finally made it work, my question is still a question though, still all kind of answers & comments are accepted!

Lately i am trying to move my trac.db to redmine, and i have faced so many bugs etc.

I want to ask is there any stable version of Redmine for migrating, or any good patched migrate_from_trac.rake file?

Currently i have: Redmine 3.2.3 Ruby 2.2.0

My Gemfile:

gem 'sqlite3'
gem "rails", "4.2.5.2"
gem "jquery-rails", "~> 3.1.4"
gem "coderay", "~> 1.1.0"
gem "builder", ">= 3.0.4"
gem "request_store", "1.0.5"
gem "mime-types", (RUBY_VERSION >= "2.0" ? "~> 3.0" : "~> 2.99")
gem "protected_attributes"
gem "actionpack-action_caching"
gem "actionpack-xml_parser"
gem "roadie-rails"
gem "mimemagic"
gem 'arel', '6.0.0.beta2'
gem "activerecord-deprecated_finders", require: "active_record/deprecated_finders"

Is there anything else you need i will happily answer them too.

My final error is:

ActiveRecord::StatementInvalid: SQLite3::SQLException: near "AND": syntax error: SELECT  "session_attribute".* FROM "session_attribute" WHERE "session_attribute"."sid" =  AND "session_attribute"."name" =  LIMIT 1

Please answer or ask something, I will return you in 15 hours in worst case.

(This is my first question, so i am open for any comments, sorry for my bad english)

change.log: migrate_from_trac.rake

Fixed: set_inheritance_column & set_primary_key errors.

Fixed: add 'gem' sqlite3 to your Gemfile error.

Fixed: incorrect date time value between trac and redmine.

Stable Release Solution

Redmine-3.1.1

Ruby-2.1.5

*after you installed these, we can start.

you can also get help from these two links from redmine itself:

Redmine Install

Redmine Migrate

My Guide for proper setup:

i. Edit your database (Use database.yml)

ii. add this to your gemfile

gem "activerecord-deprecated_finders", require:active_record/deprecated_finders"

iii. add AddTrustExternalCARoot-2048.pem to your ruby: Can't access RubyGems - Due to SSL

iv. We are having trouble with generating secret token, We need to install some gems:

gem install rails -v 4.2.4
gem install jquery-rails -v 3.1.3
gem install protected_attributes
gem install actionpack-action_caching
gem install actionpack-xml_parser
gem install tzinfo-data
gem install rbpdf -v 1.18.6
gem install rack-openid

then again:

bundle install

v. If mysql server stopped. open services.msc then start

MYSQL56

service from the list.

vi. If asks sqlite3, gem install sqlite3-ruby

vii. rake redmine:migrate_from_trac RAILS_ENV=production there you go!

Trac directory []: /var/trac/myproject
Trac database adapter (sqlite, sqlite3, mysql, postgresql) [sqlite]:
Database encoding [UTF-8]:
Target project identifier []: myproject

EXPECTED RESULT:

Deleting data
Migrating components..............................
Migrating milestones..............
Migrating custom fields.......
Migrating tickets.................................
Migrating wiki...........

Components: 29/30
Milestones: 14/14
Tickets: 1275/1275
Ticket files: 106/106
Custom values: 4409/4409
Wiki edits: 102/102

The result I get:

result

Migration code isn't working fully yet.

NOTE: if you get sqlite3 error about gemfile, add your gemfile: gem 'sqlite3' and you are done.

Community
  • 1
  • 1
K. Furkan BEK
  • 233
  • 1
  • 2
  • 9

0 Answers0