cancel
Showing results for 
Search instead for 
Did you mean: 

Alfresco 4 + MS Office 2010 Sharepoint issue.

jalxm
Champ in-the-making
Champ in-the-making
Hello all,

I have installed MS Office 2010 on my laptop with WIndows 7 Ultimate 64bit (SP1)
Then I read instructions in http://docs.alfresco.com/4.0/topic/com.alfresco.enterprise.doc/concepts/SharePoint-onlineedit.html

1. Installed patch KB907306 http://www.microsoft.com/downloads/details.aspx?familyid=17C36612-632E-4C04-9382-987622ED1D64&displa...
2. Added keys in regedit with value 2 for both
"HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\WebClient\Parameters\BasicAuthLevel" (REG_DWORD)
“HKEY_CURRENT_USER\Software\Microsoft\Office\14.0\Common\Internet\BasicAuthLevel” (REG_DWORD)

3. Restarted windows.
4. Added properties in alfresco-global.properties

### Sharepoint ###
vti.server.port=7070
vti.alfresco.deployment.context=/alfresco
vti.alfresco.alfresoHostWithPort=http://127.0.0.1:8080
vti.share.shareHostWithPort=http://127.0.0.1:8080
vti.share.shareContext=/share

5. Start alfresco.
6. Open Start->Sharepoint->Microsoft SharePoint Workspace 2010
And click on Create-> Sharepoint Workspace
7. Added path http://localhost:7070/alfresco and click Ok button
8. I have got login form to enter login/password
I put my credentials for admin and received error message about Sharepoint Workspace synchronization error.

9. In tomcat logs I saw exceptions

2012-02-05 12:32:39,852  WARN  [web.actions.VtiSoapAction] [346428597@qtp-802590979-0] Failure executing Vti request
java.lang.NullPointerException
   at org.alfresco.module.vti.web.ws.GetWebEndpoint.execute(GetWebEndpoint.java:78)
   at org.alfresco.module.vti.web.actions.VtiSoapAction.execute(VtiSoapAction.java:77)
   at org.alfresco.module.vti.web.VtiRequestDispatcher.doActions(VtiRequestDispatcher.java:238)
   at org.alfresco.module.vti.web.VtiRequestDispatcher.service(VtiRequestDispatcher.java:147)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
   at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
   at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1221)
   at org.alfresco.module.vti.web.VtiFilter.doFilter(VtiFilter.java:190)
   at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1212)
   at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:399)
   at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
   at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:766)
   at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
   at org.mortbay.jetty.Server.handle(Server.java:326)
   at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
   at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:945)
   at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756)
   at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)
   at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
   at org.mortbay.jetty.bio.SocketConnector$Connection.run(SocketConnector.java:228)
   at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)
2012-02-05 12:32:39,905  WARN  [web.actions.VtiSoapAction] [346428597@qtp-802590979-0] Failure executing Vti request
java.lang.NullPointerException
   at org.alfresco.module.vti.web.ws.WebUrlFromPageUrlEndpoint.execute(WebUrlFromPageUrlEndpoint.java:76)
   at org.alfresco.module.vti.web.actions.VtiSoapAction.execute(VtiSoapAction.java:77)
   at org.alfresco.module.vti.web.VtiRequestDispatcher.doActions(VtiRequestDispatcher.java:238)
   at org.alfresco.module.vti.web.VtiRequestDispatcher.service(VtiRequestDispatcher.java:147)
   at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
   at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
   at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1221)
   at org.alfresco.module.vti.web.VtiFilter.doFilter(VtiFilter.java:190)
   at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1212)
   at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:399)
   at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
   at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:766)
   at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
   at org.mortbay.jetty.Server.handle(Server.java:326)
   at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
   at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:945)
   at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756)
   at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)
   at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
   at org.mortbay.jetty.bio.SocketConnector$Connection.run(SocketConnector.java:228)
   at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)

Last community Alfresco 4.0.c installed.

Could you help me with the following issue?…
20 REPLIES 20

kbonnet
Champ in-the-making
Champ in-the-making
This can be solved be connecting the proxy with Tomcat using AJP instead of HTTP. The java at the sharepoint page does at request.getScheme() to retrieve http/https. This is returning the wrong one in the setup of ssl termination at the proxy. When you use AJP it returns the good one. You need mod_jk at the proxy side and an additional jetty package to handle AJP at the alfresco side. If someone is still suffering from thus problem i can elaborate.

Koen

jvanluyten
Champ in-the-making
Champ in-the-making
Hello kbonnet,

We are running into the same issue, could you elaborate a bit more please?

I understand the part involving mod_jk but i am totally unaware of jetty usages.

kbonnet
Champ in-the-making
Champ in-the-making
Hi jvanluyten,

to be sure:
- You are running Alfresco, including Sharepoint access, behind an Apache reverse proxy
- In Office you can access the Sharepoint urls, but you cant browse folders
- You are proxying the VTI/Sharepoint requests over http to Alresco


I found that in this setup there is a method in the webview page that uses "request.getScheme()". Because you're proxying over http, this returns "http" and therefor the links in the webview are not valid. To check this, you can go to the page of the web view:

https://[ALFRESCO SERVER]:7070/alfresco/[SITE NAME]/_vti_bin/owssvr.dll?location=documentLibrary&dialogview=FileOpen&FileDialogFilterValue=*.doc*;*.dot;*.htm;*.html;*.url;*.rtf;*.mht;*.mhtml;*.xml

If you view source of that page and check the html/javascript for the folder lines you will see weird urls.

I solved this with the help of this issue: https://issues.alfresco.com/jira/browse/ALF-11338

There is a reply that suggests to use AJP between the proxy and Alfresco VTI. Be default, Jetty doesnt support this, so you have to enable it. You will have to download the Jetty AJP package, put it in /webapps/alfresco/WEB-INF/lib/. Next, you can override the VTI bean to use the AJP class. But the following bean in your extension root (e.g. custom-vti-context.xml):

<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE beans PUBLIC '-//SPRING//DTD BEAN//EN' 'http://www.springframework.org/dtd/spring-beans.dtd'>
<beans>
    <bean id="vtiServerConnector" class="[b]org.mortbay.jetty.ajp.Ajp13SocketConnector[/b]">
        <property name="port">
             <value>${vti.server.port}</value>
        </property>
        <property name="headerBufferSize">
             <value>8192</value>
        </property>
    </bean>
</beans>

Now, in your proxy config, you no longer to proxyPass to Alfresco on port 7070 (or whatever you configured), but you make it an JkMount /* workerName. This is default mod_jk config.

This did the trick for you. You have to keep in mind that the internal Alfresco Server does no longer support Sharepoint over http. All requests have to pass the proxy. In some use cases this is not Ok, but for me it was.

I would like to hear if this helped you!

Koen

kbonnet
Champ in-the-making
Champ in-the-making
jvanluyten,

is this working ok for you? We ran into some other problems and i'm curious what your experience is now.

Koen

102020
Champ on-the-rise
Champ on-the-rise
In my case, I didn't have to do any deep mods. This is what I did and what I'm running (so far as we are still building the system up).

-Currently running 3 servers, all Windows 2008 Ent R2.
-Running Alfresco Community 4.2.b
-We were using it on MSSQL Server 2008 R2, but obviously, once an update comes around, you have to pay attention to any table changes and modify, so we ditched that and went to a stand alone PostgreSQL 9.2

Essentially we have the application server (tomcat), cifs server (still working on correct domain permissions), and database server. I took the admin training so trying to follow the best practice from the enterprise edition.

When doing a fresh install, firstly we install office 2010 (full suite), including sharepoint protocols. Actually by doing this, it resolved the .doc and .docx preview issue (as it's supposed to render through LibreOffice), it was a 'randomly odd' fix since no config was changed for it to work. When it was Alf 3.4 and OpenOffice, seems there were a lot less troubles.

Then go through your regular install process, I did advanced in my case to repoint postgresql to the other server. Once this was completed, I stopped the server, deleted the db and the content repo. Then I modified alfresco-global to point to our network share.
dir.root=C:/Alfresco/alf_data
dir.contentstore=\\\\xxx.xxx.xxx.xxx\\share
dir.contentstore.deleted=\\\\xxx.xxx.xxx.xxx\\share
Then booted the server up and let it recreate the db and content share.

Once I had the share working, shut down the server again and setup LDAP, modifying the alfresco-global again, using:
### LDAP Integration ###
authentication.chain=alfinst:alfrescoNtlm,ldap1:ldap-ad
ldap.authentication.active=true
ldap.authentication.allowGuestLogin=false
ldap.authentication.userNameFormat=%s@YOURDOMAINNAMEHERE.COM
ldap.authentication.java.naming.factory.initial=com.sun.jndi.ldap.LdapCtxFactory
ldap.authentication.java.naming.provider.url=ldap://YOURFQDNDOMAINNAMEHERE.COM:389
ldap.authentication.java.naming.security.authentication=simple
ldap.authentication.escapeCommasInBind=false
ldap.authentication.escapeCommasInUid=false
ldap.authentication.defaultAdministratorUserNames=Administrator,admin
ldap.synchronization.active=true
ldap.synchronization.java.naming.security.authentication=simple
ldap.synchronization.java.naming.security.principal=administrator@YOURDOMAINNAMEHERE.COM
ldap.synchronization.java.naming.security.credentials=YOURDOMAINPWHERE
ldap.synchronization.queryBatchSize=1000
ldap.synchronization.attributeBatchSize=1000
ldap.synchronization.groupQuery=(objectclass\=group)
ldap.synchronization.groupDifferentialQuery=(&(objectclass\=group)(!(modifyTimestamp<\={0})))
ldap.synchronization.personQuery=(&(objectclass\=user)(userAccountControl\:1.2.840.113556.1.4.803\:\=512))
ldap.synchronization.personDifferentialQuery=(&(objectclass\=user)(userAccountControl\:1.2.840.113556.1.4.803\:\=512)(!(modifyTimestamp<\={0})))
ldap.synchronization.groupSearchBase=ou\=CFGroups,dc\=YOURDOMAINHERE,dc=COM
ldap.synchronization.userSearchBase=ou\=CFUsers,dc=\YOUROMAINHERE,dc=COM
ldap.synchronization.modifyTimestampAttributeName=modifyTimestamp
ldap.synchronization.timestampFormat=yyyyMMddHHmmss'.0Z'
ldap.synchronization.userIdAttributeName=sAMAccountName
ldap.synchronization.userFirstNameAttributeName=givenName
ldap.synchronization.userLastNameAttributeName=sn
ldap.synchronization.userEmailAttributeName=mail
ldap.synchronization.userOrganizationalIdAttributeName=company
ldap.synchronization.defaultHomeFolderProvider=largeHomeFolderProvider
ldap.synchronization.groupIdAttributeName=cn
ldap.synchronization.groupDisplayNameAttributeName=displayName
ldap.synchronization.groupType=group
ldap.synchronization.personType=user
ldap.synchronization.groupMemberAttributeName=member
ldap.synchronization.enableProgressEstimation=true

Once that was done, booted back up, ldap successfully logged in, next onto the Sites.
Created a test site, uploaded random content> .pdf, .doc, .docx
Made sure the rendering was working (I honestly don't understand how installing office 2010 made the rendering work…never bothered to find out either)

After this was to test the share point. Now in Windows XP, it just works, Windows Vista/7 you need to make the following registry changes:

Change or create the following registry key and set its value to 2.
"HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\WebClient\Parameters\BasicAuthLevel" (REG_DWORD)

Change or create the following registry key and set its value to 2:
“HKEY_CURRENT_USER\Software\Microsoft\Office\14.0\Common\Internet\BasicAuthLevel” (REG_DWORD)

Once you do this (reboot app server), when your in article preview, you should see an 'edit online' button now.
On the windows 7 systems, you also need to install: http://www.microsoft.com/downloads/details.aspx?familyid=17C36612-632E-4C04-9382-987622ED1D64&displa...

Reboot your workstation once installed. Now when you edit online, you should be good to go. Worked in my seutp anyways!

johseb
Champ in-the-making
Champ in-the-making
I have Office 2013 and in my case de registry key is not the same. could you indicate me what the correct one for me.
Thank you.

102020
Champ on-the-rise
Champ on-the-rise
Also I just read some of the comments, we are also behind a proxy (however it's a transparent proxy), but you should try going into IE, Tools > Options > Connections > LAN settings | and if you have proxy values in there, select 'bypass proxy server for local addresses', as really, proxying the internal LAN may be overkill for most.

kbonnet
Champ in-the-making
Champ in-the-making
Hi 102020,

Do you also run your Alfresco Sharepoint access behind an Apache HTTPD reverse proxy? If so, i would like to see your httpd.conf.

Thanks for your message!

Koen

102020
Champ on-the-rise
Champ on-the-rise
Yes we do, however never had issues with it. We use ClearOS for our r-proxy

kbonnet
Champ in-the-making
Champ in-the-making
Hi 102020,

Could it be that ClearOS is your regular (forward) proxy? Is it specifically configured for handling Alfresco traffic and possibly SSL termination or authentication? If you dont have such kind of requirements, i'd say it's not a reverse proxy which is essential in this post.

Thanks anyway for thinking with us!

Koen