Going to have a play around with an open-source collaboration and content management solution called Alfresco. It’s supposed to be an alternative to Sharepoint, and has commercial and community (called Labs) versions.
First off, download the installer (I’m chucking on 3.1) http://wiki.alfresco.com/wiki/Labs_3_Final_download_files
Detailed installation/configuration instructions are here (PDF)
There’s also a more detailed guide to installing it on Ubuntu here.
I’ve done a vanilla 8.04 Server build (VM), and setup a static IP, software sources and openssh-server. I’m doing this stuff over an ssh terminal session.
1. Copy the installer to the local system (I’ve copied it to /home/Alfresco)
2. Install a bunch of stuff with:
apt-get install imagemagick mysql-server 'openoffice.org-headless' xvfb swftools sun-java6-jdk sun-java6-jre nfs-common portmap There’s a bit there, about 00MB, so you may want to grab a coffee depending on your download speed. Oh, and you’ll need to setup the MySQL password, and agree to give Sun your first-born for using Java.
3. Now the fun bit - install!
chmod 777 Alfresco-Labs-3Stable-Linux-x86-Install
./Alfresco-Labs-3Stable-Linux-x86-Install
Just leave stuff on defaults.
4. cd /opt/Alfresco
pico /opt/Alfresco/alfresco.sh
edit the following:
ALF_HOME=@@ALFRESCO_DIR@@
to
ALF_HOME=/opt/Alfresco
and
export JAVA_HOME="@@JAVA_HOME@@"
to
export JAVA_HOME="/usr/lib/jvm/java-6-sun-1.6.0.07"
(You’ll need to check that these paths are correct for your setup)
5. run pico /opt/Alfresco/virtual_alf.sh and do the same
6. Test MySQL is running: mysql -u root -p
7. Type exit
8. Add Alfresco user to MySQL mysql -p < /opt/Alfresco/extras/databases/mysql/db_setup.sql
9. Check the database is there:
mysql -p
show databases;
you should get
+--------------------+
| Database |
+--------------------+
| information_schema |
| alfresco |
| mysql |
+--------------------+
3 rows in set (0.00 sec)
Now type
quit
10. Change settings from HSQL to MySQL
cd /opt/Alfresco/tomcat/shared/classes/alfresco/extension/
pico custom-repository.properties
Change the dir.root to the absolute path of the data folder:
dir.root=/opt/Alfresco/alf_data
Add comments to HSQL connection options Remove comments from MySQL connection options So it looks like below:
.....
# Derby connection
#
#db.driver=org.apache.derby.jdbc.EmbeddedDriver
#db.url=jdbc:derby:alf_data/derby_data/alfresco;create=true
#
# HSQL connection
#
#db.driver=org.hsqldb.jdbcDriver
#db.url=jdbc:hsqldb:file:alf_data/hsql_data/alfresco;ifexists=true;shutdown=true;
#
# MySQL connection (This is default and requires mysql-connector-java-5.0.3-bin.jar, which ships with the Alfresco server)
#
db.driver=org.gjt.mm.mysql.Driver
db.url=jdbc:mysql://localhost/alfresco
......
11. Now we need to edit another file:
pico custom-hibernate-dialect.properties
Make looky like this:
.......
#
# Derby dialect
#
#hibernate.dialect=org.hibernate.dialect.DerbyDialect
#
# HSQL dialect
#
#hibernate.dialect=org.hibernate.dialect.HSQLDialect
#
# MySQL dialect (default)
#
hibernate.dialect=org.hibernate.dialect.MySQLInnoDBDialect
#
# PostgreSQL dialect
#
......
12. Start the site:
/opt/Alfresco/alfresco.sh start
and browse to the site:
http://192.168.0.1:8080/share
/opt/Alfresco/virtual_alf.sh start
13. Set it to start automatically:
This will start alfresco when the server boots up The code was from http://blog.khax.net/2009/02/26/alfresco-setup-in-ubuntu-810-with-git/
create a file
pico initialize.sh
Add these lines
#!/bin/sh
ALF_HOME=/opt/Alfresco
echo "Creating init.d links"
ln -s $ALF_HOME/alfresco.sh /etc/init.d/alfresco
ln -s $ALF_HOME/virtual_alf.sh /etc/init.d/virtual_alf
update-rc.d alfresco defaults
ln -s $ALF_HOME/alfresco.sh /etc/init.d/alfresco
ln -s $ALF_HOME/virtual_alf.sh /etc/init.d/virtual_alf
update-rc.d alfresco defaults
update-rc.d virtual_alf defaults
Lets make it executable
chmod 777 initialize.sh
Run it
./initialize.sh
Reboot and see what happens.
—
Mine is up and running now, and it’s time to have a play around. This is borrowed VERY heavily from http://wiki.alfresco.com/wiki/Installing_Alfresco_Lab_3_Stable_on_Ubuntu_8.10, I’ve just rewritten some parts but this is basically what I’ve followed. My install is on 8.04.