13 Mar

Pentaho Data Integration CMIS Input plugin

Imagine being able to extract from your Enterprise Content Management System, all the metadata of your documents using simple queries with a query language very close to the traditional SQL. Imagine using the information extracted for statistical purposes, for creating reports and, more generally, to analyse your document archives in a way unthinkable until now with the current tools available. All this is possible within the Pentaho Suite, the Open Source Business Intelligence platform, which is useful to the extraction and analysis of structured and semi-structured data.

With this goal (the extraction and analysis of data) has been designed and developed the CMIS Input plugin for Pentaho Data Integration (Kettle) that allows querying Content Management Systems that use the CMIS interoperability standard. The data, once extracted, can be stored and analyzed and perhaps presented in customized reports be published in various formats for the end user (PDF, Excel, etc..).

CMISInput

With this post I would like to introduce the CMIS Input plugin for Pentaho Data Integration, published on Google Code and realeased under LGPLv3 license.

Read more >>

 

11 Mar

Step by step installation of Alfresco Community 4.2.c on Windows Server 2008 R2 Standard 64bit… please, no bundle!

Alfresco Community 4.2.cAfter the high interest of the installation tutorial under Ubuntu plaform, in this post is shared the installation of Alfresco Community 4.2.c on Windows Server 2008 R2 Standard 64bit with Apache Tomcat 7.0.30 and PostgreSQL 9.0.10. The purpose installation is not the bundle installation but a more “robust” for an enterprise configuration. As we like and prefer the installation is a step by step list of commands and tasks… simpler to understand, to do and to test. Hope you’ll be agree.

Before starting…

In this tutorial I use a brand new Windows Server 2008 R2 Standard 64bit installation with a user called ‘alfresco’, different from the Administrator user. Connected as ‘alfresco’ user:

JDK 1.7u7

http://www.oracle.com/technetwork/java/javase/downloads/index.html

  • Download and execute ‘jdk-7u7-windows-x64.exe’.
  • Install the jdk in ‘C:AlfrescoJavajdk1.7.0_07’.
  • Install the jre in ‘C:AlfrescoJavajre7’.
  • Click on Start -> Digit ‘cmd’ and press enter.
java -version
  • Check the java version described.
  • Right click on ‘Computer’ -> Properties -> Advanced settings -> Environment variables -> New variable with name ‘JAVA_HOME’ and value ‘C:AlfrescoJavajdk1.7.0_07’ -> Press ‘Ok’ and close all.

ImageMagick 6.7.9-4

To enable image manipulation in Alfresco, we have to install and configure ImageMagick.
Official site: http://www.imagemagick.org/script/binary-releases.php#windows
Binaries: http://imagemagick.spd.co.il/binaries/

  • First of all download GhostScript 9.06 (gs906w64.exe) used to render PDF documents, from Google Code.
  • Install gs906w64.exe in ‘C:Alfrescogs9.06’.
  • Download ‘ImageMagick-6.7.9-4-Q16-windows-x64-static.exe’ from here.

ATTENTION: Other ImageMagik versions could not work.

  • Install ‘ImageMagick-6.7.9-4-Q16-windows-x64-static.exe’ in ‘C:AlfrescoImageMagick’.
  • During the installation, check flags: ‘Add application directory to your system path’ and ‘Associate supported file extensions with ImageMagick’.
  • Click on Start -> Digit ‘cmd’.
convert.exe -version
  • Check the version described.
ffmpeg
  • Check the version described.

SWFTools 0.9.1

SWFTools is a collection of utilities to work with Adobe Flash files (SWF files).
Download it from ‘http://www.swftools.org/download.html‘.

  • Download ‘swftools-0.9.1.exe’ in the Windows section.
  • Install in ‘C:AlfrescoSWFTools’ for all users.
  • Do not create shortcut or other.
  • Right click on ‘Computer’ -> Properties -> Advanced settings -> Environment variables -> Select ‘Path’ -> Modify -> Add ‘;C:AlfrescoSWFTools’ at the end -> Press ‘Ok’ and close.
  • Click on Start -> Digit ‘cmd’
pdf2swf.exe -V
  • Check the version described.

LibreOffice Windows, version 3.5.7, English (GB)

LibreOffice is used to manage office documents.
Download site: http://www.libreoffice.org/download
Previous versions: http://www.libreoffice.org/download/?nodetect

  • Download and execute ‘LibO_3.5.7_Win_x86_install_multi.msi’.
  • Install for all the users.
  • Custom installation.
  • Install in ‘C:AlfrescoLibreOffice’.
  • Leave defaults (desktop link apart).
  • Click on Start -> Digit ‘cmd’.
C:AlfrescoLibreOfficeprogramsoffice.exe
  • LibreOffice will start.

Let’s discuss about tuning. Alfresco requires that Office runs headless as a hidden process. To do that:

  • Click on Start -> Digit ‘cmd’.
C:AlfrescoLibreOfficeprogramsoffice.exe "-accept=socket,host=localhost,port=8101;urp;StarOffice.ServiceManager" -nologo -headless
  • To check the Office processes: open the task manager where there are two different processes called “soffice.exe *32” and “soffice.bin *32”.
  • Select “soffice.exe *32” and terminate the process. Also the other will be terminated.
  • Click on Start -> Digit ‘notepad++.exe C:AlfrescoLibreOfficestart_oo.bat’ and create a new file.
@echo off

rem -----------------------------
rem -                           -
rem - START Resident OpenOffice -
rem -                           -
rem -----------------------------

C:AlfrescoLibreOfficeprogramsoffice "-accept=socket,host=localhost,port=8101;urp;StarOffice.ServiceManager" -nologo -headless
  • Save and exit.
  • Click on Start -> Digit ‘C:AlfrescoLibreOfficestart_oo.bat’.

ATTENTION: A command window will be opened with no content and never closed. Don’t worry, close it and everything will be fine.

  • Open the task manager and check again the two processes: “soffice.exe *32” and “soffice.bin *32”.

ATTENTION: Restarting the system, the Office headless processes will not restart. Remeber to execute the ‘start_oo.bat’ script otherwise no preview or Office documents will be managed by Alfresco.

PostgreSQL 9.0.10

Download from  ‘http://www.enterprisedb.com/products-services-training/pgdownload#windows‘.

  • Execute the installation.
  • Install in ‘C:AlfrescoPostgreSQL9.0’.
  • Set data folder as ‘C:AlfrescoPostgreSQL9.0data’.
  • Choose your own password.
  • Press next, next, next…
  • No added packages with StackBuilder.

Now it’s time to customize the PostgreSQL installation for Alfresco.

  • Click on Start -> PostgreSQL 9.0 -> SQL shell (psql)
  • Login as default user
CREATE ROLE alfresco WITH PASSWORD 'alfresco' LOGIN;
CREATE DATABASE alfresco WITH OWNER alfresco;
  • q to exit
  • Click on Start -> PostgreSQL 9.0 -> SQL shell (psql)
  • Login as ‘alfresco’ user on the ‘alfresco’ db with password ‘alfresco’.
ALTER USER alfresco WITH PASSWORD 'alfresco';
  • q to exit

Tomcat 7.0.30

Download from ‘http://tomcat.apache.org/‘.

  • Download ‘Tomcat 7.0’ -> Quick Navigation -> Archives -> 7.0.30 -> bin -> apache-tomcat-7.0.30-windows-x86.zip
  • Unzip it in ‘C:Alfresco’ and rename ‘apache-tomcat-7.0.32’ in ‘tomcat’.
  • Click on Start -> Digit ‘cmd’
cd C:Alfrescotomcatbin
startup.bat
  • A command window will be opened with inside all the execution logs of the Tomcat start.
  • At the end, after few seconds, open a browser to the url: http://localhost:8080/
  • To stop the Tomcat server, in the command window, execute:
shutdown.bat

Let’s customize the Tomcat installation for Alfresco.

  • Click on Start -> Digit ‘C:Alfrescotomcatconf’.
  • Copy ‘catalina.properties’ in ‘catalina.properties.orig’.
  • Click on Start -> Digit ‘notepad++.exe C:Alfrescotomcatconfcatalina.properties’
  • Replace the ‘shared.loader’ line, initially set empty, to this value
shared.loader=${catalina.base}/shared/classes,${catalina.base}/shared/lib/*.jar
  • Save and exit.
  • Copy ‘server.xml’ in ‘server.xml.orig’.
  • Click on Start -> Digit ‘notepad++.exe C:Alfrescotomcatconfserver.xml’
  • Add ‘URIEncoding=”UTF-8″‘ to:
<Connector port="8080" protocol="HTTP/1.1"...
  • Save and exit.
  • Click on Start -> Digit ‘C:Alfrescotomcatconf’.
  • Copy ‘context.xml’ in ‘context.xml.orig’.
  • Click on Start -> Digit ‘notepad++.exe C:Alfrescotomcatconfcontext.xml’
  • Add this line between the ‘<Context>’ starting and closing tag.
<Valve className="org.apache.catalina.authenticator.SSLAuthenticator" securePagesWithPragma="false" />
  • Save and exit.
  • From the Alfresco package ‘alfresco-community-4.2.c.zip’ extract the ‘postgresql-9.0-802.jdbc4’ from the ‘web-serverlib’ folder and copy it in ‘C:Alfrescotomcatlib’.

Alfresco Community 4.2.c

  • Click on Start -> Digit ‘C:Alfrescotomcat’
  • Create folder ‘endorsed’.
  • Create folder ‘shared’.
  • Create folder ‘shared/classes’.
  • Create folder ‘shared/lib’.
  • Unzip the ‘alfresco-community-4.2.c.zip’ package in ‘C:Alfrescotomcat’.
  • Move all the content of the folder ‘web-server/endorsed’ in ‘endorsed’.
  • Move all the content of the folder ‘web-server/shared’ in ‘shared’.
  • Move all the content of the folder ‘web-server/webapps’ in ‘webapps’.
  • Delete the file ‘README.txt’.
  • Delete the folder ‘web-server’.
  • Right click on ‘Computer’ -> Properties -> Advanced settings -> Environment variables -> Select ‘Path’ -> Modify -> Add ‘C:Alfrescotomcatbin’ -> Press ‘Ok’ and close.
  • Click on Start -> Digit ‘C:Alfrescotomcatsharedclasses’
  • Copy ‘alfresco-global.properties.sample’ in ‘alfresco-global.properties’
  • Click on Start -> Digit ‘notepad++.exe C:Alfrescotomcatsharedclassesalfresco-global.properties’.
  • Change the settings as described below, leaving all the rest not modified.
...
dir.root=C:\Alfresco\alf_data
# IMPORTANT: Leave the comment on the dir.keystore property.
...
db.username=alfresco
db.password=alfresco
...
#
# External locations
#-------------
# LibreOffice installation
ooo.exe=C:\Alfresco\LibreOffice\program\soffice.exe
ooo.enabled=true
jodconverter.officeHome=C:\Alfresco\LibreOffice
jodconverter.portNumbers=8101
jodconverter.enabled=true
# ImageMagick installation
img.root=C:\Alfresco\ImageMagick
img.exe=C:\Alfresco\ImageMagick\convert.exe
# SWFTools exe
swf.exe=C:\Alfresco\SWFTools\pdf2swf.exe
...
db.schema.update=true
...
db.driver=org.postgresql.Driver
db.url=jdbc:postgresql://localhost:5432/alfresco
...
index.recovery.mode=AUTO
...
authentication.chain=alfrescoNtlm1:alfrescoNtlm
...
alfresco.rmi.services.host=0.0.0.0
...
  • Save and exit.

Now it’s time to define the start/stop script.

  • Click on Start -> Digiti ‘notepad++.exe C:Alfrescoalfresco.bat’
  • Of course create it with this content.
@echo off

rem ---------------------------
rem -                         -
rem - Start and Stop Alfresco -
rem -                         -
rem ---------------------------

set ALF_HOME=C:Alfresco
set CATALINA_HOME=%ALF_HOME%tomcat
set JAVA_OPTS=%JAVA_OPTS% -Xms512m -Xmx768m -Xss768m -server -XX:MaxPermSize=256M

if /I "%1"=="start" goto :start
if /I "%1"=="stop" goto :stop
echo Usage: alfresco.bat [start stop]
goto :end

:start
%CATALINA_HOME%binstartup.bat
goto :end

:stop
%CATALINA_HOME%binshutdown.bat
goto :end

:end
  • Save and exit.
  • Click on Start -> Digit ‘cmd’ -> Right click on ‘cmd’ and execute it as administrator.
cd C:Alfresco
alfresco.bat start
  • A command window will be opened with inside all the execution logs of the Alfresco start.
  • Some minutes should be enough…
  • During bootstrap no error should appear.
  • At the end, open a browser and access to the url ‘http://localhost:8080/share’.

Last but not least, remember to copy ‘C:AlfrescotomcatbinWin32NetBIOSx64.dll’ in ‘C:WindowsSystem32’. This is usefull to make work the CIFS access to Alfresco on this Windows platform.

That’s all…

08 Mar

New A.A.A.R. Alfresco audit analysis and reporting v1.2 release

New release!

Release 1.2

Thanking to the contribution of some users with interesting practical cases, a new version 1.2 of the A.A.A.R. – Alfresco audit analisys and reporting has been released.

Here some useful links for the interested of you.

07 Mar

Liferay 6.1.1 CE GA2 IDE on JBoss 7 with Eclipse Juno… problems until now!

Eclipse_IconIn this post is shared the installation of Liferay 6.1.1 Community Edition GA2 IDE on Ubuntu 12.04 LTS 64bit with JBoss Application Server 7.1 Community Edition and PostgreSQL 8.4.15. The post is based on the installation tutorial described in the ‘Step by step installation of Liferay 6.1.1 CE GA2 on Ubuntu 12.04 LTS 64bit and JBoss 7… no bundle please!‘ and supposes you have the same environment installed and working in your system.

Unfortunately lot’s of problems are presents and documented here. Hope will be solved soon but until now this way of developing on Liferay with JBoss is not so easy yet.

As we like and prefer, the installation is a step by step list of commands and tasks… simpler to understand, to do and to test. Hope you’ll be agree.

Sources

In this paragraph are collected the used sources for the installation. I suggest to download and store them in a safe repository for future purposes (re-installation, maintainance, etc.).

  • Eclipse IDE for Java EE Developers – Juno release from Eclipse Downloads (‘eclipse-jee-juno-SR1-linux-gtk-x86_64.tar.gz’).
  • Plugin server-manager-web from Liferay Plugin 6.1 GA (‘server-manager-web-6.1.0.1-ce-ga1-….war’).
  • Liferay 6.1.1 GA2 on Tomcat Bundle from Liferay Portal Download (‘liferay-portal-tomcat-6.1.1-ce-ga2-….zip’).
  • Liferay SDK from Liferay Portal Download (‘liferay-plugins-sdk-6.1.1-ce-ga2-….zip’).

Eclipse Juno installation

Connect to the server (or the virtual machine like in our case) as ‘liferay’ user. We discourage the use of the root user for security reasons.

  • Open a terminal and execute:
cd /home/liferay/Desktop/
cp /mnt/.../eclipse-jee-juno-SR1-linux-gtk-x86_64.tar.gz .
tar zxvf eclipse-jee-juno-SR1-linux-gtk-x86_64.tar.gz
rm -rf eclipse-jee-juno-SR1-linux-gtk-x86_64.tar.gz
  • Let’s run eclipse and use it.
/home/liferay/Desktop/eclipse/eclipse &
  • In the menus bar: Help -> Check for update. Update, if requested, and restart.

Eclipse EGit installation

To have a professional version control of your source code you need a CVS, SVN, Git (or similar) module installed on Eclipse. Here we prefer EGit Eclipse that you can install as described below.

Liferay IDE installation

Liferay IDE, like all the Liferay suite, it’s very well documented here. Liferay IDE installation is documented here and it’s described below.

Add Liferay server as remote

Until now Liferay on JBoss is not supported using the Liferay IDE because only a Tomcat Server can be added to the list of Liferay servers. Reading around in the web and in the Liferay’s forum should be possibile to add a Liferay server as remote. We’ll see that it is possibile… but it doesn’t work properly. But let’s see how to do it.

  • Move the ‘server-manager-web-6.1.0.1-ce-ga1-….war’ file in ‘/opt/liferay/deploy’. This is a hot deploy and the file will be delete in few seconds.
  • To check the installation: open a browser and access to ‘http://localhost:8080/server-manager-web/status’ (login:test@liferay.com, password:test).
  • Below an example of correct result:
{"error":"","status":0,"output":""}

.

service liferay stop
nano /opt/liferay/jboss/standalone/configuration/standalone.xml

.

...
<subsystem xmlns="urn:jboss:domain:logging:1.1">
 ...
 <logger category="org.quartz"><level name="ERROR"/></logger>
 ...
  • Unzip the Liferay Tomcat bundle (‘liferay-portal-tomcat-6.1.1-ce-ga2-….zip’) in /opt/dummyLiferay
chown -R liferay:liferay /opt/dummyLiferay
/opt/dummyLiferay/tomcat-7.0.27/bin/startup.sh
  • Wait while liferay startup with success…
/opt/dummyLiferay/tomcat-7.0.27/bin/shutdown.sh
  • Unzip Liferay SDK (‘liferay-plugins-sdk-6.1.1-ce-ga2-….zip’) in /opt/liferay-plugins-sdk-6.1.1
chown -R liferay:liferay /opt/liferay-plugins-sdk-6.1.1
service liferay start
  • In Eclipse go to New Liferay SDK in the Liferay icon menu.
  • Location: ‘/opt/liferay-plugins-sdk-6.1.1’ and click Ok.
  • In Eclipse go to New Liferay Server in the Liferay icon menu.
  • Location: ‘/opt/liferay-plugins-sdk-6.1.1’ and click Ok.
  • Select ‘Remote Liferay Server’ -> Next
  • Select Liferay Bundle Type to Tomcat 7 and Liferay Bundle Directory set to ‘/opt/dummyLiferay/tomcat-7.0.27’ -> Next
  • Set Password to ‘test’ -> Validate connection -> Next -> Finish

In many tests, the INFO and WARN messages in the console are fast and so many. But restarting everything work… don’t know why.

My personal compliments… Liferay on JBoss and PostgreSQL is installed with success!

Unfortunately lot’s of problems are presents and documented here when you try to release something developed. Hope will be solved soon but until now this way of developing on Liferay with JBoss is not so easy yet.

02 Mar

A.A.A.R. Alfresco audit analysis and reporting frequently asked questions

Thanking to the contribution of some users a new FAQ page for A.A.A.R. (Alfresco audit analysis and reporting) has been released. I’m sure will be usefull for most of the people are currently using the solution, in P.O.C., production environment or only to see how it works.

Waiting for your feedback to make it grow up… 🙂