Redmine+Git+PostgreSQL 8.4 fails to import the Linux kernel repository

Added by Oren Laadan over 12 years ago


I'm trying to setup redmine to track a branch of the linux kernel (git repository).

A click on "Repository" (after a long server thinking time) gave an "Internal error" ("An error occurred
on the page you were trying to access. If you continue to experience problems please contact your redMine
administrator for assistance.")

The culprit was a commit with a line "Signed-off-by: �Jason Gaston <>" which
is apparently in ISO-8859-1 while redmine expected UTF-8. Searching redmine's issues I found a report
( and a suggested solution.

As suggested, I switched the setting of the encoding to ISO-8859-1 (Admin->Settings->Repositories), and
tried again. The server took (longer) time to think, and eventually spit the same error message. This
time the culprit was a different commit:

Author: Albrecht Dre<DF> <albrecht.dress@com.rmk.(none)>
Date:   Fri Jun 3 20:52:26 2005 +0100

    [PATCH] ARM: 2694/1: [s3c2410/dma] release irq properly to fix kernel oops

I tried to switch the setting back from ISO-8859-1 to UTF-8 - but the problem persists. (Interestingly,
the problem remained with this commit and not regress to the previous commit). Tried a few other
ISO-8859-? but no luck either.

It would be very useful to use redmine to manage/track development on a branch of the linux tree,
help is appreciated.

Below are the (truncated) log and the system configuration.


Processing RepositoriesController#show (for at 2009-11-20 15:47:43) [GET]
  Session ID: 1266cac274339938b895d38e081b4485
  Parameters: {"action"=>"show", "id"=>"linux-cr", "controller"=>"repositories"}

ActiveRecord::StatementInvalid (RuntimeError: ERROR     C22021  Minvalid byte sequence for encoding "UTF8": 0xdf20      
HThis error can also happen if the byte sequence does not match the encoding expected by the server, which is
controlled by "client_encoding".  
Rreport_invalid_encoding: SELECT "changesets"."id" AS t0_r0, "changesets"."repository_id" AS t0_r1,
 "changesets"."revision" AS t0_r2, "changesets"."committer" AS t0_r3, "changesets"."committed_on" AS t0_r4,
 "changesets"."comments" AS t0_r5, "changesets"."commit_date" AS t0_r6, "changesets"."scmid" AS t0_r7,
 "changesets"."user_id" AS t0_r8, "users"."id" AS t1_r0, "users"."login" AS t1_r1, "users"."hashed_password" 
 AS t1_r2, "users"."firstname" AS t1_r3, "users"."lastname" AS t1_r4, "users"."mail" AS t1_r5,
 "users"."mail_notification" AS t1_r6, "users"."admin" AS t1_r7, "users"."status" AS t1_r8,
 "users"."last_login_on" AS t1_r9, "users"."language" AS t1_r10, "users"."auth_source_id" AS t1_r11,
 "users"."created_on" AS t1_r12, "users"."updated_on" AS t1_r13, "users"."type" AS t1_r14 FROM "changesets" 
 LEFT OUTER JOIN "users" ON "users".id = "changesets".user_id
 WHERE ("changesets".repository_id = 4 AND
 ("changesets"."committer" = E'Albrecht Dre<DF> <albrecht.dress@com.rmk.(none)>'))  
 ORDER BY changesets.committed_on DESC, DESC LIMIT 1):
    /usr/lib/ruby/gems/1.8/gems/activerecord-2.1.2/lib/active_record/connection_adapters/abstract_adapter.rb:147:in `log'
    /usr/lib/ruby/gems/1.8/gems/activerecord-2.1.2/lib/active_record/connection_adapters/postgresql_adapter.rb:484:in `execute'
    /usr/lib/ruby/gems/1.8/gems/activerecord-2.1.2/lib/active_record/connection_adapters/postgresql_adapter.rb:929:in `select_raw'
    /usr/lib/ruby/gems/1.8/gems/activerecord-2.1.2/lib/active_record/connection_adapters/postgresql_adapter.rb:916:in `select'

System config:
ubuntu 8.04
apache 2.2.8

$ RAILS_ENV=production script/about
About your application's environment
Ruby version              1.8.6 (i486-linux)
RubyGems version          1.3.5
Rails version             2.1.2
Active Record version     2.1.2
Action Pack version       2.1.2
Active Resource version   2.1.2
Action Mailer version     2.1.2
Active Support version    2.1.2
Application root          /srv/redmine-0.8
Environment               production
Database adapter          postgresql
Database schema version   101