AnsweredAssumed Answered

Chinese UTF woes

Question asked by durianwool on Nov 8, 2007
Latest reply on Nov 16, 2007 by kevinr
Hi,

I just installed Alf 2.1 linux from the tomcat distro. I am installing with MySQL on a OpenSuse 10.2. Chinese (simplified) chars for filenames cannot be accepted nor displayed on the web gui nor the system.

I suspected its due to the MySQL cos HSQL works, but I can't / shouldn't use that for production right?  I tried this after failing miserably miserably at trying to migrate Alf 2.0 HSQL to Alf 2.0 MySQL. But now even a fresh install of Alf 2.1 with MySQL 5.0 still can't work propoerly (due to this Chinese problem) … so I had to rollback to Alf 2.0 with HSQL now…


I changed the db_setup.sql script as follows:

create database alfresco CHARACTER SET utf8 COLLATE utf8_general_ci;

But I still got the same prob. I even reset the MySQL 5.0 be UTF8 by default. but still failed miserably. I got an ugly error that won't even initiate alfresco:

20:33:11,294 WARN  [org.springframework.remoting.rmi.RmiRegistryFactoryBean] Could not detect RMI registry - creating new one
20:33:12,159 ERROR [org.springframework.web.context.ContextLoader] Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dictionaryRepositoryBootstrap' defined in class path resource [alfresco/core-services-context.xml]: Invocation of init method failed; nested exception is org.alfresco.error.AlfrescoRuntimeException: Failure during rollback: org.alfresco.repo.dictionary.DictionaryRepositoryBootstrap$1@166fdde
Caused by:
org.alfresco.error.AlfrescoRuntimeException: Failure during rollback: org.alfresco.repo.dictionary.DictionaryRepositoryBootstrap$1@166fdde
        at org.alfresco.repo.transaction.RetryingTran …

So I then reverted the DB back to latin1, though the alfresco DB itself is UTF8 now… Only then it initialises - but then I get back to square one that I can't put Chinese filenames and chars. Only these settings work:

mysql> status
————–
mysql  Ver 14.12 Distrib 5.0.26, for suse-linux-gnu (i686) using readline 5.1

Connection id:          1
Current database:       alfresco
Current user:           root@localhost
SSL:                    Not in use
Current pager:          less
Using outfile:          ''
Using delimiter:        ;
Server version:         5.0.26
Protocol version:       10
Connection:             Localhost via UNIX socket
Server characterset:    latin1
Db     characterset:    utf8
Client characterset:    latin1
Conn.  characterset:    latin1
UNIX socket:            /var/lib/mysql/mysql.sock
Uptime:                 20 min 17 sec

Is there some settings in Alf 2.1 community itself?!?!?!?
Argh!


BR,

Durian

Outcomes