cancel
Showing results for 
Search instead for 
Did you mean: 

Ubuntu 8.04

leetcharmer
Champ in-the-making
Champ in-the-making
Has anyone installed Alfresco Enterprise 2.2.0 on Ubuntu 8.04 yet?  I've been trying but here are my errors when I try to run the alfresco script as stated http://wiki.alfresco.com/wiki/Installing_Alfresco_on_Ubuntu_7.10:
administrator@alfresco:~$ sudo /etc/init.d/alfresco start
Starting OpenOffice service …
Setting up iptables …
Redirecting port 21 to 2021 (tcp)
Bad argument `tcp'
Try `iptables -h' or 'iptables –help' for more information.
Bad argument `tcp'
Try `iptables -h' or 'iptables –help' for more information.
Redirecting port 445 to 1445 (tcp)
Bad argument `tcp'
Try `iptables -h' or 'iptables –help' for more information.
Bad argument `tcp'
Try `iptables -h' or 'iptables –help' for more information.
Redirecting port 139 to 1139 (tcp)
Bad argument `tcp'
Try `iptables -h' or 'iptables –help' for more information.
Bad argument `tcp'
Try `iptables -h' or 'iptables –help' for more information.
Redirecting port 137 to 1137 (udp)
Bad argument `udp'
Try `iptables -h' or 'iptables –help' for more information.
Bad argument `udp'
Try `iptables -h' or 'iptables –help' for more information.
Redirecting port 138 to 1138 (udp)
Bad argument `udp'
Try `iptables -h' or 'iptables –help' for more information.
Bad argument `udp'
Try `iptables -h' or 'iptables –help' for more information.
Starting Alfresco …
Neither the JAVA_HOME nor the JRE_HOME environment variable is defined
At least one of these environment variable is needed to run this program
administrator@alfresco:~$ /usr/lib/openoffice/program/soffice.bin X11 error: Can't open display:
   Set DISPLAY environment variable, use -display option
   or check permissions of your X-Server
   (See "man X" resp. "man xhost" for details)

administrator@alfresco:~$ sudo /etc/init.d/alfresco stop
Neither the JAVA_HOME nor the JRE_HOME environment variable is defined
At least one of these environment variable is needed to run this program

In /etc/profile:
# /etc/profile: system-wide .profile file for the Bourne shell (sh(1))
# and Bourne compatible shells (bash(1), ksh(1), ash(1), …).

JAVA_HOME="/usr/lib/jvm/java-6-sun-1.6.0.06"; export JAVA_HOME
PATH=$PATH:$JAVA_HOME/bin
export PATH

if [ -d /etc/profile.d ]; then
  for i in /etc/profile.d/*.sh; do
    if [ -r $i ]; then
      . $i
    fi
  done
  unset i
fi

if [ "$PS1" ]; then
  if [ "$BASH" ]; then
    PS1='\u@\h:\w\$ '
    if [ -f /etc/bash.bashrc ]; then
        . /etc/bash.bashrc
    fi
  else
    if [ "`id -u`" -eq 0 ]; then
      PS1='# '
    else
      PS1='$ '
    fi
  fi
fi

umask 022
I don't know what to do.
11 REPLIES 11

dinger
Champ in-the-making
Champ in-the-making
Have you tried
iptables -h
? You should be able to see if the command in the script is not valid anymore.

Looks like java home isn't set up properley? What happens when you run
echo $JAVA_HOME

Rob

vivi
Champ in-the-making
Champ in-the-making
Hello,

I also try to install Alfresco (but alfresco-community-tomcat-2.1.0.tar.gz) on ubuntu server 8.04 following the tutorial for ubuntu 7.10 (http://wiki.alfresco.com/wiki/Installing_Alfresco_on_Ubuntu_7.10).

With this ubuntu, the java version is:
java version "1.6.0_06"
Java(TM) SE Runtime Environment (build 1.6.0_06-b02)
Java HotSpot(TM) Server VM (build 10.0-b22, mixed mode)

with Openoffice 2.4

When I launch the script given at the end of the tutorial, I also get the same messages as reported earlier.

There is a problem with JAVA_HOME, with the X-server (maybe due to the Openoffice version?) and with iptable…
I have tryied to declare JAVA_HOME in different files such as /etc/profile, ~/.bashrc, /etc/environment with the same result when I execute the script.

How can we solve the problem?
Does anyone has already managed to install Alfresco on ubuntu 8.04?

leetcharmer
Champ in-the-making
Champ in-the-making
Have you tried
iptables -h
? You should be able to see if the command in the script is not valid anymore.

Looks like java home isn't set up properley? What happens when you run
echo $JAVA_HOME

Rob
administrator@alfresco:~$ echo $JAVA_HOME
/usr/lib/jvm/java-6-sun-1.6.0.06

also according to the man page for iptables and the help tool via iptables -h, it shows -t is still a legit use of iptables.  So, not quite sure how to debug their script.

Here's a copy of the script for easy viewing:

#
# Alfresco init script for Ubuntu
# 2 nov 2007 Joost Horward
#

export ALFRESCO_HOME=/opt/alfresco
export CATALINA_BASE=/opt/alfresco/tomcat
export CATALINA_HOME=/opt/alfresco/tomcat
export PIDFILE=/var/run/alfresco
export LOGFILE=/var/log/alfresco/alfresco.log

# Set any default JVM values
export JAVA_OPTS='-Xms128m -Xmx512m -server -Djava.io.tmpdir=/var/lib/alfresco/tmp'


cd "$ALFRESCO_HOME"

#
# redirect FROM TO PROTOCOL
# setup port redirect using iptables
redirect() {
   echo "Redirecting port $1 to $2 ($3)"
   iptables -t nat -A OUTPUT -d localhost -p $3 –dport $1 -j REDIRECT –to-ports $2
   iptables -t nat -A PREROUTING -d $HOSTNAME -p $3 –dport $1 -j REDIRECT –to-ports $2
   iptables -t nat -A OUTPUT -d $HOSTNAME -p $3 –dport $1 -j REDIRECT –to-ports $2
}

#
# setup_iptables
# setup iptables for redirection of CIFS and FTP
setup_iptables () {

   echo "1" >/proc/sys/net/ipv4/ip_forward
   # Clear NATing tables
   iptables -t nat -F
   # FTP NATing
   redirect 21 2021 tcp

   # CIFS NATing
   redirect 445 1445 tcp
   redirect 139 1139 tcp
   redirect 137 1137 udp
   redirect 138 1138 udp
}

#
# start_openoffice
#
start_openoffice(){
   sudo -H -u alfresco xvfb-run /usr/lib/openoffice/program/soffice "-accept=socket,host=localhost,port=8100;urp;StarOffice.ServiceManager" -nologo -headless -nofirststartwizard &
}

case $1 in
start)
   if [ -f $PIDFILE ] ; then
      echo "Alfresco is already running!"
      exit 1
   fi
   touch $PIDFILE
   echo "Starting OpenOffice service …"
   start_openoffice

   echo "Setting up iptables …"
   setup_iptables   

   echo "Starting Alfresco …"
   echo  -e "\n\n\n\n\n\n\n\n\n\n`date` Starting Alfresco …" >>$LOGFILE
   sudo chown alfresco:alfresco $LOGFILE

   sudo -H -u alfresco sh $CATALINA_HOME/bin/startup.sh
        ;;
stop) 
   sudo -H -u alfresco sh $CATALINA_HOME/bin/shutdown.sh
   killall -w -u alfresco
        echo  -e "`date` Stopping Alfresco …" >>$LOGFILE
   rm $PIDFILE
        ;;
restart)
   rm $PIDFILE
   sudo -H -u alfresco sh $CATALINA_HOME/bin/shutdown.sh
   killall -w -u alfresco
    echo  -e "\n\n\n\n\n\n\n\n\n`date` Restarting Alfresco …" >>$LOGFILE
   sudo -H -u alfresco sh $CATALINA_HOME/bin/startup.sh
   touch $PIDFILE
        ;;
zap)
   echo "Zapping $PIDFILE …"
   rm $PIDFILE
   ;;
*)
   echo "Usage: alfresco [start|stop|restart|zap] [tail]"
   exit 1
   ;;

esac  

case $2 in
tail)
   tail -f $LOGFILE
   ;;
esac


exit 0

louish
Champ in-the-making
Champ in-the-making
Hi All.

I'm having an issue installing the community version (latest) on Ubuntu 8.04.   I've set the JAVA_HOME and echo $JAVA_HOME displays the following.
$ echo $JAVA_HOME
/usr/lib/jvm/java-6-openjdk/bin


What happens is that after extracting afresco to /opt/alfresco.  I run ./alfresco.sh…  And nothing happens.  I just get a blinking cursor.   What am I missing?

TIA
Louis

leetcharmer
Champ in-the-making
Champ in-the-making
I don't think Alfresco will work with the openJDK version of Java.

christianm
Champ in-the-making
Champ in-the-making
Hi,

I found in http://forum.ubuntu-fr.org/viewtopic.php?pid=1719605 a work around about this problem. I replaced the alfresco.sh script and modified the variable for Java and working fine, I hope this script make help full:

PD: Special thanks to the Ubuntu Forum France 🙂 for the post


#!/bin/sh
# Start or stop Alfresco server
# Set the following to where Tomcat is installed
APPSERVER=/opt/alfresco/tomcat
# Set any default JVM values
export JAVA_HOME=/usr/lib/jvm/java-6-sun
export JAVA_OPTS='-Xms128m -Xmx256m -server'
# Following only needed for Sun JVMs before to 1.5 update 8
export JAVA_OPTS="${JAVA_OPTS} -XX:CompileCommand=exclude,org/apache/lucene/index/IndexReader\$1,doBody -XX:CompileCommand=exclude,org/alfresco/repo/search/impl/lucene/index/IndexInfo\$Merger,mergeIndexes -XX:CompileCommand=exclude,org/alfresco/repo/search/impl/lucene/index/IndexInfo\$Merger,mergeDeletions"
#
if [ "$1" = "start" ]; then
  "$APPSERVER"/bin/startup.sh
#  if [ -r ./virtual_start.sh ]; then
#    sh ./virtual_start.sh
#  fi
  if [ -r ./start_oo.sh ]; then
    sh ./start_oo.sh
  fi
elif [ "$1" = "stop" ]; then
  "$APPSERVER"/bin/shutdown.sh
#  if [ -r ./virtual_start.sh ]; then
#    sh ./virtual_stop.sh
#  fi
  if [ -r ./start_oo.sh ]; then
    killall soffice.bin
  fi
fi

vivi
Champ in-the-making
Champ in-the-making
Here is a method to install Alfresco community 2.1 on Ubuntu server 8.04

http://forum.alfresco-fr.org/viewtopic.php?f=6&t=1810

louish
Champ in-the-making
Champ in-the-making
Hi All.

Problem solved.  It was a UE (user error) on my part.   I was not starting alfresco correctly.  I had missed the end part of the command.

sudo ./alfresco.sh start

TIA
for all the suggestions.

Louis

scottthornley
Champ in-the-making
Champ in-the-making
I'm fairly sure that this is a layer 8 issue, but would appreciate additional eyeballs and/or guidance.
I installed alfresco via the information on:

http://wiki.alfresco.com/wiki/Installing_Alfresco_on_Ubuntu_7.10
http://wiki.alfresco.com/wiki/Installing_Alfresco_on_Ubuntu_8.04
http://forums.alfresco.com/fr/viewtopic.php?f=6&t=1810

I've put the
export JAVA_HOME="/usr/lib/jvm/java-6-sun" 
lines in both /etc/profile and /etc/environment (the French version)

When I execute
$ sudo /etc/init.d/alfresco start
I get the same iptables and "Neither JAVA_HOME nor the "JRE_HOME"…. error messages as posted above. When I execute
$ sudo su -
# /etc/init.d/alfresco start

I merely get the JAVA_HOME/JRE_HOME error messages.

When  I execute
$ sudo /opt/alfresco/alfresco.sh start
, the process does not throw any error messages, just the normal
Using CATALINA_BASE:   /opt/alfresco/tomcat
Using CATALINA_HOME:   /opt/alfresco/tomcat
Using CATALINA_TMPDIR: /opt/alfresco/tomcat/temp
Using JRE_HOME:       /usr/lib/jvm/java-6-sun

a
$ ps -ef | grep alfresco
shows the process running. So I point browser to port 8080/alfresco, which just gives a 404 error:

HTTP Status 404 - /alfresco/
type Status report
message /alfresco/
description The requested resource (/alfresco/) is not available.
Apache Tomcat/5.5.23

Pointing to port 8080 does give the Tomcat success page.

I've gone back over things a number of time, looking for ownership/permissions issues, but am not seeing anything.

Any ideas?