cancel
Showing results for 
Search instead for 
Did you mean: 

Alfresco and Mysql

nezha
Champ in-the-making
Champ in-the-making
hi;
i followed this procedure
1/ Install MySSQL using mysql-installer-community-5.6.10.1.msi
>   Full install

2/ Add environment Variables
> Path (C:\Program files\mySQL\MySqlServer 5.6\Bin)

3/ Open Cmd.exe and log into MySQL
> Mysql –u root –p

4/ Create Alfresco database
>   Create database alfresco;

5/ Create user
>Create user ‘alfresco’@’localhost’ identified by ‘alfresco’

6/ Grant permissions
> Grant all privileges on *.* to ‘alfresco’@’localhost’
> With grant option;

7/ Install Alfresco community 4.2.c (install Settings below)
> Install all components except the Postgresql
> Folder – C:\alfresco

Database Config
> URL    - jdbc:mysql://localhost:3306/alfresco?useUnicode=yes&characterEncoding=UTF-8
> JDBC Driver   - org.gjt.mm.mysql.Driver
> DB name - alfresco
> DB user   - alfresco
> Password   - *******

8/ Updating properties
> open C:\Alfresco40a\tomcat\shared\classes\ alfresco-global.properties.sample
> check Dir.root=c:\alfresco\alf_data
> uncomment url and Driver sections (updating to suit)
> uncomment db username and password (updating to suit)
> Insert index type index.subsystem.name=lucene (if using lucene indexs)

9/ Rename alfresco-global.properties.sample to alfresco-global.properties
> alfresco-global.properties.sample to alfresco-global.properties

10/ Apply MySQL Connector
> Copy Connector J 5.1.23.Jar to [Dir.root]\tomcat\lib

11/ restore mysql database in CMD
> mysql –u alfresco –p PASSWORD alfresco

but when i tried to log in my Alfresco i got this error:
Le serveur distant est indisponible ou vos informations d'identification n'ont pas été reconnues.
i think the problme is how to migrate database from alfresco to mysql please someone can helpe???
5 REPLIES 5

mrogers
Star Contributor
Star Contributor
Cant see anything wrong with that.  

Except step 11 which is nothing to do with restore.    Or was that the command you typed in which case the password is alfresco not PASSWORD.

Have you then started alfresco at missing stap 12.

And what was in your alfresco.log file?

nezha
Champ in-the-making
Champ in-the-making
thinks for your answer ;
yes i restard alfresco but the same error this is my alfresco.log content:
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in class path resource [alfresco/hibernate-context.xml]: Invocation of init method failed; nested exception is org.hibernate.HibernateException: Hibernate Dialect must be explicitly set
   at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1420)
   at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)
   at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)
   at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:291)
   at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
   at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:288)
   at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:190)
   at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:322)
   … 88 more
Caused by: org.hibernate.HibernateException: Hibernate Dialect must be explicitly set
   at org.hibernate.dialect.DialectFactory.determineDialect(DialectFactory.java:67)
   at org.hibernate.dialect.DialectFactory.buildDialect(DialectFactory.java:47)
   at org.hibernate.cfg.SettingsFactory.determineDialect(SettingsFactory.java:426)
   at org.hibernate.cfg.SettingsFactory.buildSettings(SettingsFactory.java:128)
   at org.hibernate.cfg.Configuration.buildSettings(Configuration.java:2079)
   at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1304)
   at org.springframework.orm.hibernate3.LocalSessionFactoryBean.newSessionFactory(LocalSessionFactoryBean.java:860)
   at org.springframework.orm.hibernate3.LocalSessionFactoryBean.buildSessionFactory(LocalSessionFactoryBean.java:779)
   at org.springframework.orm.hibernate3.AbstractSessionFactoryBean.afterPropertiesSet(AbstractSessionFactoryBean.java:211)
   at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1477)
   at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1417)
   … 95 more
NB:in my mysql database ther'is no table??

mrogers
Star Contributor
Star Contributor
the "dialect" is normally a "red herring"   you can set it if you like,  but the root cause tends to be an inability to connect to the database.   Once the connection is made then the dialect can be determined.

nezha
Champ in-the-making
Champ in-the-making
how the connection will be established

nezha
Champ in-the-making
Champ in-the-making
im beginner in this software this is my first time
i installed alfresco.exe community version 32bit
I use the advanced configuration at the begining of the installation and choose MYSQL as my database
i configure the file property
the main question is:
is that ennogh to use alfresco with mysql???
thinks for helping