cancel
Showing results for 
Search instead for 
Did you mean: 
resplin
Elite Collaborator
Elite Collaborator

Obsolete Pages{{Obsolete}}

The official documentation is at: http://docs.alfresco.com



InstallationCentosLinux


A few important words


This document borrows heavily from an excellent wiki post located at the following url:

http://wiki.alfresco.com/wiki/Installing_Alfresco_Community_3.2_WAR_on_Centos_5.3

Thanks goes to:


  1. Alfresco team for creating Alfresco and opensourcing the project; and
  2. the original group of wiki contributors, whom made this revision possible.

Getting started


Caution! The following instructions require root access. Please be
cognizant that you could negatively affect your system due to inadvertent
commands. Mind what you type!!


Documentation Approach


This documents presents the actual steps which were necessary to install Alfresco Comunity 3.2r war on a freshly installed CentOS 5.4 x86_64 minimal installation. The CentOS 5.4 installation was done through text based network setup and none of extra packages nor gui has been installed. i386 installation should work the same. Just refer to the i386 / i586 packages where needed (e.g. jPackage, swf-tools etc.)

The following is the plain commands entered, some relevant output presented by those and required input by the user. When file edits are necessary only the respective lines are shown with the required text. Sometimes existing lines have to be replaced by the text presented here. Some times new lines have to be added. To give reference to the location of the new lines one line before has been included in the text here.

Shell prompt is indicated by

[root@server ~]#  

Keyboard input is indicated by

<enter>

Long lines are wrapped by a backslash

\

Text ommited, e.g. from files or output is indicated by

...

Interactive application prompts, e.g. mysql, are indicated by

mysql> 

Comments for further actions or reviews are indicated by

#
# Do this or that...
#

Installation Steps


[root@server base]# system-config-securitylevel-tui
Securitylevel enabled
SELinux enforcing
Customize
other: 8080

[root@server ~]# yum update
[root@server ~]# yum install tomcat5 tomcat5-common-lib tomcat5-jasper tomcat5-jsp-2.0-api tomcat5-server-lib tomcat5-servlet-2.4-api openoffice.org-base openoffice.org-calc openoffice.org-core openoffice.org-draw openoffice.org-graphicfilter openoffice.org-impress openoffice.org-math openoffice.org-writer openoffice.org-xsltfilter openoffice.org-headless mysql-server mysql xml-commons-apis wget
[root@server ~]# yum install ImageMagick rpm-build
[root@server ~]# rpm -e --nodeps java-1.6.0-openjdk java-1.6.0-openjdk-devel
[root@server ~]# yum update
[root@server ~]# cd
[root@server ~]# mkdir alfresco
[root@server ~]# cd alfresco
[root@server alfresco]# wget http://voxel.dl.sourceforge.net/project/alfresco/Alfresco/3.2r%20Community%20Edition/alfresco-community-war-3.2r.tar.gz \
  http://voxel.dl.sourceforge.net/project/alfresco/Alfresco/3.2r%20Community%20Edition/alfresco-community-sample-extensions-3.2r.tar.gz \
  http://voxel.dl.sourceforge.net/project/alfresco/Alfresco/3.2r%20Community%20Edition/alfresco-xforms-examples-3.2r.tar.gz \
  http://voxel.dl.sourceforge.net/project/alfresco/WCM/3.2r%20Community%20Edition/alfresco-community-wcm-3.2r.tar.gz \
  http://voxel.dl.sourceforge.net/project/alfresco/Records%20Management/3.2r%20Community%20Edition/AlfrescoRMCommunity-3.2r-Linux-x86-Install \
  http://voxel.dl.sourceforge.net/project/alfresco/Records%20Management/3.2r%20Community%20Edition/alfresco-dod5015-unsupported-3.2r.amp \
  http://voxel.dl.sourceforge.net/project/alfresco/Records%20Management/3.2r%20Community%20Edition/alfresco-dod5015-share-unsupported-3.2r.amp \
  http://voxel.dl.sourceforge.net/project/alfresco/Extensions/3.2r%20Community%20Edition/vti-module-3.2r.amp \
  http://mysql.speedbone.de/Downloads/Connector-J/mysql-connector-java-5.1.10.tar.gz \
  http://mirrors.dotsrc.org/jpackage/1.7/generic/non-free/SRPMS/java-1.6.0-sun-compat-1.6.0.06-1jpp.src.rpm


#
# Now we compile and install swftools 0.9.0 as version 0.8.1 will not work with Alfresco. Currently
# version 0.9.0 is not available as rpm so we have to do all the work by ourselfs.
# I prefere to do this on a separate machine and copy the binaries to the respective folders in the
# productive machine. But for simplicity we are doing all steps here directly
#
[root@server alfresco]# yum install gcc gcc-c++ automake zlib-devel libjpeg-devel freetype-devel giflib-devel fontconfig-devel freeglut-devel 
[root@server alfresco]# wget ftp://ftp.pbone.net/mirror/atrpms.net/el5-x86_64/atrpms/stable/libmp3lame0-3.98.2-20.el5.x86_64.rpm \
  ftp://ftp.pbone.net/mirror/atrpms.net/el5-x86_64/atrpms/stable/lame-devel-3.98.2-20.el5.x86_64.rpm \
  ftp://ftp.pbone.net/mirror/ftp.freshrpms.net/pub/freshrpms/pub/dag/redhat/el5/en/x86_64/RPMS.dag/lame-3.98.2-1.el5.rf.x86_64.rpm \
  ftp://ftp.pbone.net/mirror/centos.karan.org/el5/extras/testing/x86_64/RPMS/t1lib-5.1.0-9.el5.kb.x86_64.rpm \
  http://www.swftools.org/swftools-0.9.0.tar.gz
[root@server alfresco]# rpm -i lame-3.98.2-1.el5.rf.x86_64.rpm libmp3lame0-3.98.2-20.el5.x86_64.rpm \
  t1lib-5.1.0-9.el5.kb.x86_64.rpm lame-devel-3.98.2-20.el5.x86_64.rpm
[root@server alfresco]# tar xzf swftools-0.9.0.tar.gz
[root@server alfresco]# cd swftools-0.9.0
[root@server swftools-0.9.0]# ./configure
  ...
  checking for Python.h... nope
  checking for missing libraries...
  configure: creating ./config.status
  config.status: creating Makefile.common
  config.status: WARNING:  'Makefile.common.in' seems to ignore the --datarootdir setting
  config.status: creating Makefile
  config.status: creating lib/Makefile
  config.status: creating lib/action/Makefile
  config.status: creating src/Makefile
  config.status: creating lib/pdf/Makefile
  config.status: creating swfs/Makefile
  config.status: creating lib/art/Makefile
  config.status: creating lib/readers/Makefile
  config.status: creating config.h
  
[root@server swftools-0.9.0]# make
[root@server swftools-0.9.0]# make install
[root@server swftools-0.9.0]# whereis pdf2swf
  pdf2swf: /usr/local/bin/pdf2swf
[root@server swftools-0.9.0]# cd ..


#
# Download sun java jdk 6 from sun.com scripting not possible as requires one time auth code 😞
#


[root@server alfresco]# chmod 755 jdk-6u20-linux-x64-rpm.bin
[root@server alfresco]# ./jdk-6u20-linux-x64-rpm.bin
...
Do you agree to the above license terms? [yes or no]
yes<enter>
...
For more information on what data Registration collects and
how it is managed and used, see:
http://java.sun.com/javase/registration/JDKRegistrationPrivacy.html

Press Enter to continue.....
<enter>
Done.

[root@server alfresco]# mkdir -p /usr/src/redhat/SOURCES

[root@server alfresco]# rpm -ivh java-1.6.0-sun-compat-1.6.0.06-1jpp.src.rpm
warning: java-1.6.0-sun-compat-1.6.0.06-1jpp.src.rpm: Header V3 DSA signature: NOKEY, key ID c431416d
    1:java-1.6.0-sun-compat  warning: user mockbuild does not exist - using root
warning: group mockbuild does not exist - using root
warning: user mockbuild does not exist - using root
warning: group mockbuild does not exist - using root
warning: user mockbuild does not exist - using root
warning: group mockbuild does not exist - using root
########################################### [100%]

[root@server alfresco]# cd /usr/src/redhat/SPECS/
[root@server SPECS]# vi java-1.6.0-sun-compat.spec

%define buildver        20
...
%config(noreplace) %{_jvmdir}/%{jredir}/lib/security/cacerts
%config(noreplace) %{_jvmdir}/%{jredir}/lib/security/blacklist
%config(noreplace) %{_jvmdir}/%{jredir}/lib/security/javaws.policy
%config(noreplace) %{_jvmdir}/%{jredir}/lib/security/trusted.libraries

[root@server SPECS]# rpmbuild -bb java-1.6.0-sun-compat.spec
[root@server SPECS]# rpm -Uvh /usr/src/redhat/RPMS/x86_64/java-1.6.0-sun-compat-1.6.0.20-1jpp.x86_64.rpm
[root@server SPECS]# java -version
java version '1.6.0_20'
Java(TM) SE Runtime Environment (build 1.6.0_20-b02)
Java HotSpot(TM) 64-Bit Server VM (build 16.3-b01, mixed mode)

[root@server SPECS]# alternatives --config java

There are 2 programs which provide 'java'.

   Selection    Command
-----------------------------------------------
    1           /usr/lib/jvm/jre-1.4.2-gcj/bin/java
*+ 2           /usr/lib/jvm/jre-1.6.0-sun/bin/java

Enter to keep the current selection[+], or type selection number:<enter>

[root@server SPECS]# cd ~/alfresco
[root@server alfresco]# vi /etc/sysconfig/tomcat5
# If you wish to further customize your tomcat environment,
# put your own definitions here
# (i.e. LD_LIBRARY_PATH for some jdbc drivers)
# Just do not forget to export them 🙂

JAVA_OPTS='$JAVA_OPTS -Xms1g -Xmx512m -XX:MaxPermSize=512M'

[root@server alfresco]# mkdir base
[root@server alfresco]# cd base
[root@server base]# tar xzf ../alfresco-community-war-3.2r.tar.gz
[root@server base]# chkconfig mysqld on
[root@server base]# service mysqld start
[root@server base]# mysql -u root -p