Installing on MacOS X

Showing results for 
Search instead for 
Did you mean: 

Installing on MacOS X

0 0 10.2K

Obsolete Pages{{Obsolete}}

The official documentation is at:


This guide is still work in progress. Everything except instructions for CIFS should be working now. /Alexandra

Installing Alfresco

The following is a guide to installing Alfresco on Mac OS X and Mac OS X Server.

Alfresco Tomcat Bundled Installation


  • Mac OS X 10.4 or above
  • Java 1.5 is preinstalled on Mac OS X 10.4 and Mac OS X 10.4 Server. Pre-release packages of Java are available for download for registrered (free) users at
  • Alfresco available from


  • MySQL is preinstalled on Mac OS X Server

Simple Installation on OS X

All these instructions assume knowledge of using OS X from Terminal commands.  You
may need to prefix some of the commands with 'sudo' if you do not have administrative

Install JDK 5.0

- If you already have J2SE Development Kit 5.0 installed, skip to 'Install Alfresco Tomcat Bundle'

- Browse to
- Install once downloaded
- Ensure the JAVA_HOME variable is set correctly

Install Alfresco Tomcat Bundle

Note: This assumes you have a /opt directory but virtually any directory will do. If this is your development workstation, we recommend your home directory for convenient: ~/alfresco. Of course,  /usr/local should work, or create your own /opt.

  sudo mkdir /opt/alfresco

  • Copy the downloaded alfresco bundle to /opt/alfresco
  sudo cp alfresco-community-tomcat-2.0.0.tar.gz  /opt/alfresco

or (for 2.1)

  sudo cp alfresco-community-tomcat-2.1.0.tar.gz  /opt/alfresco

- Tar uncompress alfresco-community-tomcat-2.0.0.tar.gz  in the '/opt/alfresco' directory

  sudo gnutar -xzvf alfresco-community-tomcat-2.0.0.tar.gz

or (for 2.1)

  sudo gnutar -xzvf alfresco-community-tomcat-2.1.0.tar.gz

or (for 3b)

  sudo gnutar -xzvf alfresco-community-tomcat-3b.tar.gz

or (for 3c)

  sudo gnutar -xzvf alfresco-labs-tomcat-3c.tar.gz

or (for 3d / 3Stable)

  sudo gnutar -xzvf alfresco-labs-tomcat-3c.tar.gz

Note: As of Alfresco 3d / 3Stable, there is now a Mac OS X installer. If you use that installer, you can skip all installation instructions noted here though the CIFS and FTP configuration instructions will come in handy.

If you not intend to run Alfresco as root user make sure all permissions for the user you want to run as is set to both exceute and write access for the bundle.

Set Paths

Edit '' and check the variables are pointing to the location where Tomcat
is installed:
- For the Tomcat bundle, this will be '/opt/alfresco/tomcat'

For version 2.1,
is the default

Optional Install of Database

Alfresco is pre-configured to use the HSQL database, but can easily be
configured to use other databases, please visit the forums and wiki at for guidelines

- See 'README-mysql.txt' for details on configuring for use with MySQL.

General configuration details can be found at:

You have now installed all the components needed to run the Alfresco server.

Optional Install of OpenOffice (seem to be working finally!)

If you would like to have a range of document transformations available from within
Alfresco, you need to install OpenOffice.  This is entirely optional and can be
done at any point after Alfresco has been installed. 

      • There are known issues with OpenOffice 2.0.1 and 2.0.2 ***
  • Make sure X11 is installed otherwise do it from the Mac OS X install DVD
  • Browse to
  • Download the OS X version
  • Install OpenOffice
  • Start one of the OpenOffice programs to go through initial registration, then close it
  • Rename '/opt/alfresco/' to '/opt/alfresco/'

  • Edit '/opt/alfresco/' and set the correct location for OpenOffice. On Mac OS X the usual location is in /Applications. There is an error in the script regarding the path to 'soffice' and the correct one for OpenOffice 2.2 is

  • The launch argument looks something like this
  /Applications/\ '-accept=socket,host=localhost,port=8100;urp;StarOffice.ServiceManager' -nologo -headless -nofirststartwizard & 

What made it work for me was to not run the script as root and do it from xterm after starting X11. No configuration of DISPLAY environment variables seem to be necessary.

  • Stop and restart the Alfresco server if it is already running

Optional tips for running X11 applications in Mac OS X

  • Add the following lines in the top of the script in order to configure a display in X11
  DISPLAY=localhost:1.0; export DISPLAY
  cd /usr/X11R6/bin
  ./Xvfb :1 -screen 0 800x600x32

  • It also seems that using the open-X11 script in the X11R6/bin folder is the suggested way to start X11 applications on Mac OS X. However, the idea is to start OpenOffice headless with the right sockets open for Alfresco to access it as a transformation engine.

Running the Alfresco Server

Navigate to the '/opt/alfresco' directory, and enter

  ./ start

Or, to help ensure CIFS can properly bind to privileged port (otherwise see port remapping below)

  sudo ./ start

You can now try Alfresco by visiting:

Note: it may take a few minutes before the server responds.  When I first started, it took three iterations of starting... then becoming frustrated and stopping...--Jake 22:01, 18 January 2008 (UTC)

The server is configured with a single administrative login with user name and password
both set to 'admin'.

To test the installation, you may wish to follow the tutorial, available from: or from the company space from within the Web Client.

Closing the Alfresco Server

Navigate to the '/opt/alfresco' directory and run './ stop'.

Connect using WebDav on Mac OS X

The Alfresco repository can be mounted as a WebDav volume in Mac OS X Finder. Choose Apple-K and enter the following


Use and connect to the FTP-server

There is a built-in Java-based FTP-server in Alfresco. That server defaults to the standard port 21 but that will only work if you run the Alfresco startup script as root. If you need to start Alfresco as anything other than root you will need to change the port. In order to bind FTP-server to unpriviliged ports you need to edit file-servers.xml and locate the following entry:

  <config evaluator='string-compare' condition='FTP Server'>
  <serverEnable enabled='true'/>

and add the following line after:


Then you will need to make sure the firewall is open for the port you selected (any port above 1024 can be entered in the above example - though some may already be in use). That means that you need to the specify another port than the default one in your ftp client. Another option is to set up port forwarding so the non-priviliged port is mapped to the standard FTP port 21.

In order to have support for non-ASCII Swedish characters åäö and ÅÄÖ I had to add an extra line of code to set the file server to MacRoman and then do the same in my FTP-client (Cyberduck).


See more on

For a list of character encodings see here:

Using the CIFS Server

To check the CIFS server is running on the local machine, try connecting from the Alfresco server using smbclient.

  smbclient -L


  smbclient -L `hostname` -U admin%admin

You may mount the repository on a Mac client using a Network connection (Apple-K in Finder) of the form:


A dialogue box should appear prompting for WORKGROUP, USER and PASSWORD. WORKGROUP can be left empty and use your web client user and password for the remaining to. A volume called 'ALFRESCO' should be mounted in Finder.

If you have trouble using Finder to mount an SMB share, use the command line instead, like this:

  mount_smbfs //admin:admin@localhost:1445/Alfresco /Users/jpotts/alfresco-cifs

The '1445' is the CIFS port (see firewall port remapping, below) and may not be required in all cases.

Starting Alfresco as root user is required to have CIFS working without remapping.

Port remapping to remove requirement to run as root

In order to be able to start Alfresco without being root user the file server config and firewall settings need to be updated.

For file server config changes see running CIFS from a normal user account

For firewall settings:

  # ! /bin/sh
  echo 'Setup CIFS Port Forwarding ...'
  sysctl -w net.inet.ip.fw.enable=1
  sysctl -w net.inet.ip.forwarding=1
  sysctl -w net.inet.ip.fw.verbose=1
  sysctl -w net.inet.ip.fw.debug=0

  #Will remove any existing rules in your current configuration. Optional.
  ipfw flush

  #ipfw add 100 count log ip from any to any
  ipfw add 200 allow ip from any to any via lo0
  # Forward native SMB and NetBIOS sessions to non-privileged ports
  ipfw add 300 fwd <local ip>,1445 tcp from any to me dst-port 445
  ipfw add 400 fwd <local ip>,1139 tcp from any to me dst-port 139

  # Forward NetBIOS datagrams to non-privileged ports (does not currently work)
  ipfw add 500 fwd <local ip>,1137 udp from any to me dst-port 137
  ipfw add 600 fwd <local ip>,1138 udp from any to me dst-port 138

  ipfw add 65535 allow ip from any to any

  #Resets logs in ipfw. Optional
  ipfw zero
  echo 'Done.'

Replace all instances of <local ip> above with your server's IP address.  Please note that in order to apply these rules, the firewall need to be activated. In Mac OS X Client do that in System Preferences->Sharing, and for Mac OS X Server open the Server Admin GUI application and make sure the firewall is on. Please observe that neither GUI-tool include all the options necessary to do the settings described above. Therefore it may be appropriate to create a shell script with the terminal commands for ipfw listed above. Run that as root or use the sudo-command. Also note that the Server Admin GUI can be rather slow to update its list of rules after running the script.

If you need another GUI tool to manipulate the firewall on Mac OS X have a look at:

Removing the .DS_Store 'duplicate' files

-Mac OS X creates hidden .DS_Store files in each folder. DS_Store (Desktop Services Store) is a hidden file created by Mac OS X to store custom attributes of a folder such as the position of icons or the choice of a background image. The creation of these files can be annoying when using Alfresco and can be disabled using the instructions on the following page:

The following instructions in the orginial readme file seems only to be applicable for Windows clients

If you are unable to connect to the CIFS server, then depending on your network, you may need
to configure the domain for CIFS to use.  You will need to have started the Alfresco server
at least once to be able to do this.  To set the domain, edit the 'file-servers-custom.xml'
file in the '~/alfresco/tomcat/shared/classes/alfresco/extension' directory and add the
domain into the following line:

  <host name='${localname}_A'/>

so that it is something like:

  <host name='${localname}_A' domain='MYDOMAIN'/>

You will need to restart the Alfresco server for this to take effect.

Once the Alfresco server is running, it should be possible to connect to it by mapping a
drive to it.  The name to use for the mapping is based on the name of the server on which
Alfresco is running, with '_A' on the end.  For example, if the PC name is 'MYPC01', then
the CIFS server name will be 'MYPC01_A'. 

To map the drive on a MS Windows client, open Windows Explorer, go
to the Tools menu and select 'Map Network Drive...'.  In the Map Network Drive dialog,
choose the drive letter you wish to use.  To locate the CIFS server, click the 'Browse...'
button and find the server name as described above.  You should then have the option to
select a folder within it called 'alfresco'.  Click 'OK' to select the folder, then click
'Finish' to map the drive.  You should now have access to the Alfresco repository from
the mapped drive.  If the CIFS server name does not show in the browse dialog, you may also
enter the folder location directly in the dialog, for example '\\MYPC01_A\alfresco'.

See more on:

Image Manipulation

To enable image manipulation on Mac OS X or Mac OS X Server, the ImageMagick package needs to be installed.  To check, try running the 'convert' command, which is part of ImageMagick and usually found in /usr/bin.  Otherwise download ImageMagick-universal-apple-darwin8.10.1.tar.gz from

and follow the install instructions. If ImageMagick has been installed in /opt/imagemagick then add the following lines to the startup script in order to make it available in the PATH

  export PATH=$PATH:/opt/imagemagick/ImageMagick-6.3.6/bin

  export MAGICK_HOME='/opt/imagemagick/ImageMagick-6.3.6'

  export DYLD_LIBRARY_PATH='/opt/imagemagick/ImageMagick-6.3.6/lib'


Remember to check the Alfresco.log file in the Alfresco Root directory. That can be done using 'more' or 'tail' command in the terminal but also using the GUI-application called Console found in /Applications/Utilities. In order to see the Alfresco directory you may need to enable display of hidden files in Mac OS X or Mac OS X Server. That can be done using several free/shareware applications like Cocktail:

There should be no error messages with java stack-traces in the log file.

If you have problems with your installation, please look for help on the Installation Forum and ask for any additional help you may need.

- The JAVA_HOME variable must be set correctly to your Java5 installation.

- If the following errors are reported on the console:

 ERROR [AbstractImageMagickContentTransformer] JMagickContentTransformer not available:
ERROR [AbstractImageMagickContentTransformer] ImageMagickContentTransformer not available:
Failed to execute command: convert ...

These are not issues which will cause the server to fail. Alfresco is reporting that various external document transformation engines are not available for use by the server. 

- If you see this error on server startup:

 ERROR [protocol] FTP Socket error Address already in use: JVM_Bind
        at Method)

Check to see if you have any services running against port 8080 for the Alfresco server and port 21 for the Alfresco FTP integration. (Please note that if running Alfresco from anything else than root the ftp port need to be set to something above 1024. See section above for instructions)

- To access the CIFS repository directly from the FireFox browser, you need to install the Alfresco FireFox Extension from here:

Internet Explorer does not require the extension to open CIFS folders directly.

- then you may view the CIFS folder from file:///Volumes/alfresco

For more troubleshooting tips see:

External references

Our good friends at AFP548 have a document about this called Document Management in the Fresh Air and recomend use Mac How.