cancel
Showing results for 
Search instead for 
Did you mean: 

Alfresco dont read alfresco-global.properties!

humbertoccs
Champ in-the-making
Champ in-the-making
Hi everyone.

I just installed Alfresco Community Edition 3.2. I was following some books about customization… things like dont allow guest user, ldap authentication, etc.

I could make my Alfresco read the files inside my share folder, and block guest access, but it´s not working when i try to enable ldap authentication, so i have to edit files in WAR folder.

Here is my alfresco-global.properties.

dir.root=/opt/Alfresco/alf_data
db.name=alfresco
db.username=alfresco
db.password=alfresco
db.host=localhost
db.port=3306
ooo.exe=/opt/broffice.org3/program/soffice
img.root=/usr/local
swf.exe=/opt/Alfresco/bin/pdf2swf
db.driver=org.gjt.mm.mysql.Driver
db.url=jdbc:mysql://${db.host}:${db.port}/${db.name}
hibernate.dialect=org.hibernate.dialect.MySQLInnoDBDialect
authentication.chain=alfinst:alfrescoNtlm,ldap1:ldap

And, if it is necessary, my folder in share directory.


# ls /opt/Alfresco/tomcat/shared/classes/alfresco/extension/subsystems/Authentication/
alfrescoNtlm  ldap  passthru

# ls /opt/Alfresco/tomcat/shared/classes/alfresco/extension/subsystems/Authentication/alfrescoNtlm/
alfinst

# ls /opt/Alfresco/tomcat/shared/classes/alfresco/extension/subsystems/Authentication/alfrescoNtlm/alfinst/
alfresco-authentication-context.xml  alfresco-authentication.properties  ntlm-filter-context.xml  ntlm-filter.properties

# ls /opt/Alfresco/tomcat/shared/classes/alfresco/extension/subsystems/Authentication/ldap/
ldap1

# ls /opt/Alfresco/tomcat/shared/classes/alfresco/extension/subsystems/Authentication/ldap/ldap1/
common-ldap-context.xml  ldap-authentication-context.xml  ldap-authentication.properties

After solve this issue, i needo to know why my ldap authentication is not working, but this is another topic problem! Smiley Happy
4 REPLIES 4

mrogers
Star Contributor
Star Contributor
where have you put your alfresco-global.properties?

And if you are running on your own instance of Tomcat 6 did you set the shared class loader?

humbertoccs
Champ in-the-making
Champ in-the-making
My file is in /opt/Alfresco/tomcat/shared/classes/alfresco-global.properties.

The tomcat that is running is the one that is installed by Alfresco installation program.

humbertoccs
Champ in-the-making
Champ in-the-making
Just for the record, that´s my alfresco.log file. In this part of the file, you can see the address "qq.com", that´s address is in the file within the WAR folder. My correct properties file is posted after the log file. If i put the correct configuration in the properties file on the WAR folder, it´s loaded correctly. But, that´s not the recomendation to configure Alfresco correct?


INFO: Deploying web application archive studio.war
09:48:10,162  ERROR [authentication.ldap.LDAPInitialDirContextFactoryImpl] Unable to connect to LDAP Server; check LDAP configuration
javax.naming.CommunicationException: qq.com:389 [Root exception is java.net.ConnectException: Connection timed out]
        at com.sun.jndi.ldap.Connection.<init>(Connection.java:210)
        at com.sun.jndi.ldap.LdapClient.<init>(LdapClient.java:118)
        at com.sun.jndi.ldap.LdapClient.getInstance(LdapClient.java:1580)
        at com.sun.jndi.ldap.LdapCtx.connect(LdapCtx.java:2652)
        at com.sun.jndi.ldap.LdapCtx.<init>(LdapCtx.java:293)
        at com.sun.jndi.ldap.LdapCtxFactory.getUsingURL(LdapCtxFactory.java:175)
        at com.sun.jndi.ldap.LdapCtxFactory.getUsingURLs(LdapCtxFactory.java:193)
        at com.sun.jndi.ldap.LdapCtxFactory.getLdapCtxInstance(LdapCtxFactory.java:136)
        at com.sun.jndi.ldap.LdapCtxFactory.getInitialContext(LdapCtxFactory.java:66)


# cat /opt/Alfresco/tomcat/shared/classes/alfresco/extension/subsystems/Authentication/ldap/ldap1/ldap-authentication.properties

ldap.authentication.active=true
ldap.authentication.allowGuestLogin=false
ldap.authentication.userNameFormat=uid\=%s,dc\=alliance3,dc\=net
ldap.authentication.java.naming.factory.initial=com.sun.jndi.ldap.LdapCtxFactory
ldap.authentication.java.naming.provider.url=ldap://127.0.0.1:389
ldap.authentication.java.naming.security.authentication=simple
ldap.authentication.escapeCommasInBind=false
ldap.authentication.escapeCommasInUid=false
ldap.authentication.defaultAdministratorUserNames=
ldap.synchronization.active=true
ldap.synchronization.java.naming.security.principal=cn\=root,dc\=alliance3,dc\=net
ldap.synchronization.java.naming.security.credentials=alliance
ldap.synchronization.queryBatchSize=1000
ldap.synchronization.groupQuery=(objectclass\=groupOfNames)
ldap.synchronization.groupDifferentialQuery=(&(objectclass\=groupOfNames)(!(modifyTimestamp<\={0})))
ldap.synchronization.personQuery=(objectclass\=inetOrgPerson)
ldap.synchronization.personDifferentialQuery=(&(objectclass\=inetOrgPerson)(!(modifyTimestamp<\={0})))
ldap.synchronization.groupSearchBase=ou\=Groups,dc\=alliance3,dc\=net
ldap.synchronization.userSearchBase=ou\=Users,dc\=alliance3,dc\=net
ldap.synchronization.modifyTimestampAttributeName=modifyTimestamp
ldap.synchronization.timestampFormat=yyyyMMddHHmmss'Z'
ldap.synchronization.userIdAttributeName=uid
ldap.synchronization.userFirstNameAttributeName=givenName
ldap.synchronization.userLastNameAttributeName=sn
ldap.synchronization.userEmailAttributeName=mail
ldap.synchronization.userOrganizationalIdAttributeName=o
ldap.synchronization.defaultHomeFolderProvider=personalHomeFolderProvider
ldap.synchronization.groupIdAttributeName=cn
ldap.synchronization.groupType=groupOfNames
ldap.synchronization.personType=inetOrgPerson
ldap.synchronization.groupMemberAttributeName=member

humbertoccs
Champ in-the-making
Champ in-the-making
Guys, that the deal…

1. I was using Alfresco 3.2… so i upgrade it to Alfresco_Community_Edition_3.3 (last version).

2. I didnt have put 755 permissions on the files .properties and .xml inside my share folder.

After this two modifications, everything seems to work.

Thanks.