Hi, I'm Harlin and welcome to my blog. I write about Python, Alfresco and other cheesy comestibles.

Alfresco - Installing Community 5.2

I'm creating this post as a bookmark of sorts. If you've arrived here, no need to worry with this one unless you are interested in getting Alfresco Community installed. Keep in mind that there are Alfresco Enterprise and Community installs. If you don't have an Enterprise license and are interested in getting Alfresco installed, this is the post for you.

Before we begin, please make sure you have at least 4GB of memory and 2 cpu's dedicated to your server or laptop. You can use a vmware or virtualbox or kvm guest machine but you will still need this amount of memory and CPUs.

To download Alfresco Community, go here:

https://www.alfresco.com/products/community/download

To be a good sport, fill out the marketing info. If you're honest and let them know you're only interested in just learning more about the platform on your own, you likely won't get a telemarketing call ;-).

After that's done, you will be redirected to:

https://www.alfresco.com/alfresco-community-download

Next, choose the installer based on your OS:

Windows 64 bit
Linux
OSX

Go ahead and download the installer to your machine.

A quick note here if you are using Ubuntu (which of the supported Linux distros I completely recommend), you will need to install a few prerequisite libraries so that LibreOffice works.

Install libraries:

# sudo apt install libfontconfig1 libfontconfig1-dev libice-dev libice6 libsm-dev libsm6 libxrender-dev libxrender1 libxext-dev libxext6 libxinerama-dev libxinerama1 libcups2 libcups2-dev libglu1-mesa libglu1-mesa-dev libcairo2 libcairo2-dev

After you've downloaded the Alfresco installer, you can install it on Linux or MacOS X by going to the directory and making sure it's executable and then run the installer:

# chmod +x alfresco-community-installer-201707-linux-x64.bin
# sudo ./alfresco-community-installer-201707-linux-x64.bin --mode text

If you're on Windows, you can simply click on the setup.exe.

Now, if you get the following message when trying to install on Linux, no worries, you should have everything necessary installed from the sudo apt install command above:

Note:

Some or all of the libraries needed to support LibreOffice were not found on your system: fontconfig libSM libICE libXrender libXext libcups libGLU libcairo2 libgl1-mesa-glx

You are strongly advised to stop this installation and install the libraries.

For more information, see the LibreOffice documentation at http://docs.alfresco.com/search/site/all?keys=libfontconfig

Ok, moving along with the installation you should see the following:

Installation:

Do you want to continue with the installation? [y/N]: y

Language Selection

Please select the installation language
[1] English - English
[2] French - Français
[3] Spanish - Español
[4] Italian - Italiano
[5] German - Deutsch
[6] Japanese - 日本語
[7] Dutch - Nederlands
[8] Russian - Русский
[9] Simplified Chinese - 简体中文
[10] Norwegian - Norsk bokmål
[11] Brazilian Portuguese - Português Brasileiro
Please choose an option [1] : 
----------------------------------------------------------------------------
Welcome to the Alfresco Community Setup Wizard.

----------------------------------------------------------------------------
Installation Type

[1] Easy - Install using the default configuration.
[2] Advanced - Configure server ports and service properties.: Choose optional components to install.
Please choose an option [1] : 2

----------------------------------------------------------------------------

I recommend going with the Advanced option if you are performing a command line installation.

Next, we get to choose components that we want installed. I recommend choosing them as I did. Do not install Solr1 and do not install Web Quick Start:

Select the components you want to install; clear the components you do not want 
to install. Click Next when you are ready to continue.

Java [Y/n] :y

PostgreSQL [Y/n] :y

LibreOffice [Y/n] :y

Alfresco Community : Y (Cannot be edited)

Solr1 [y/N] : n

Solr4 [Y/n] :y

Alfresco Office Services [Y/n] :y

Web Quick Start [y/N] : n

Google Docs Integration [Y/n] :y

Is the selection above correct? [Y/n]: y

As far as installation goes, I tend to have many versions of Alfresco running on the same server. As such, I like to have a hierarchy like so:

/alfresco
/alfresco/5.2.d
/alfresco/5.1.e

and so forth. So, I recommending using something like below or just at least have your own convention that you understand.

----------------------------------------------------------------------------
Installation Folder

Choose a folder to install Alfresco Community.

Select a folder: [/opt/alfresco-community]: 

Alfresco comes with an embedded Postgresql database server. I recommend you use that unless you know database servers well and have experience in setting up distributed Java apps.

----------------------------------------------------------------------------
Database Server Parameters

Enter the port of your database.

Database Server Port: [5432]: 

Unless you have another Tomcat instance that you plan to run at the same time, you should be fine to stick with the defaults:

----------------------------------------------------------------------------
Tomcat Port Configuration

Enter your Tomcat configuration parameters.

Web Server Domain: [127.0.0.1]: 

Tomcat Server Port: [8080]: 

Tomcat Shutdown Port: [8005]: 

Tomcat SSL Port: [8443]: 

Tomcat AJP Port: [8009]: 

LibreOffice is used to handle document type transformations. The defaults are fine here also:

----------------------------------------------------------------------------
LibreOffice Server Port

Enter the port that the LibreOffice Server will listen to.

LibreOffice Server Port: [8100]: 

Unless you have your ftp server on the same machine, the default is fine:

----------------------------------------------------------------------------
FTP Port

Choose a port number for the integrated FTP server.

Port: [21]: 

Normally the convention when setting up Alfresco is to use admin/admin as username and password:

----------------------------------------------------------------------------
Admin Password

Specify a password for the Alfresco Content Services administrator account.

Admin Password: :
Repeat Password: :

I personally don't prefer to install Alfresco as a service. For development machines you are likely to have multiple Alfresco installs and on production servers, you really don't want your critical production apps to start without personally monitoring but that choice is up to you:

----------------------------------------------------------------------------
Install as a service

If you register Alfresco Community as a service it will automatically start 
Alfresco Community on machine startup.

Install Alfresco Community as a service? [Y/n]: n

You may get this warning but as long as you are not setting up a production server and you are following the initial resource prerequisites at the beginning of this post, you should be fine.

----------------------------------------------------------------------------
Warning

This environment is not configured optimally for Alfresco Content Services - 
review this list before continuing.

While these issues won’t prevent Alfresco Content Services from functioning, 
some product features might not be available, or the system might not perform 
optimally.

CPU clock speed is too slow
 (2.0 GHz+): 1.8 GHz
Not enough system RAM available
 (4.0GB+): 3.85GB


Press [Enter] to continue:

Install continues.

----------------------------------------------------------------------------
Setup is now ready to begin installing Alfresco Community on your computer.

Do you want to continue? [Y/n]: y

----------------------------------------------------------------------------
Please wait while Setup installs Alfresco Community on your computer.

 Installing
 0% ______________ 50% ______________ 100%
 #########################################

----------------------------------------------------------------------------
Setup has finished installing Alfresco Community on your computer.

View Readme File [Y/n]: n

Launch Alfresco Community [Y/n]: n

Ok, installation part is over and now is time for the moment of truth. Go to the directory where you started and issue the start command:

# cd /opt/alfresco-community
# ./alfresco.sh start

Tomcat should start and then appear to finish. But, Alfresco is just getting started up. We can monitor the logs for any potential issues using "tail":

# tail -f tomcat/logs/catalina.out

We should see a number of entries. There may be a warning or two here and there but ultimately at the end, we should see something like this:

Dec 12, 2017 5:04:31 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-apr-8080"]
Dec 12, 2017 5:04:31 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["ajp-apr-8009"]
Dec 12, 2017 5:04:31 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-bio-8443"]
Dec 12, 2017 5:04:31 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 74644 ms

If you didn't get any weird errors where it doesn't appear that Alfresco started properly, you can point your browser to:

http://:8080/share

When you eventually get a login page, go ahead and login as admin / admin or whatever password you set for admin during the installation.

Once you get in you should see a user dashboard. Keep in mind that Alfresco is the repository that runs in the background while Share is the web UI to work with Alfresco. Share was designed to be a collaboration tool. As such, it uses the concept of "Sites" where folders and documents are created. So, let's go ahead and create a site.

At the top, choose Sites > Create Site

I used these defaults:

  • Name: TestSite1

  • Automatically, Site ID will be filled in with testsite1.

  • Choose Public

  • Click Create

This will redirect you to the TestSite1 dashboard.

At the top right hand side, click on Document Library.

Click Upload and select any file on your workstation (preferrably a word document, pdf or image file) and upload it.

My file name was called TheAlfrescoDatabase.docx. Click on your document's name in the document list. This will take you to a document detail page. A preview should be generated.

Click the Back button or click on Documents (above the document's name) and you should be directed back to the document list page or Document Library page.

There should now be a thumbnail for the document.

In the upper right hand corner, you should see an input that has the text, Search files, people, sites. Enter the name of your document and click enter.

We should now see a list of search results with the name of our document. This is probably the most basic smoke test you can perform to make sure that Alfresco is running as expected. If you have gotten this far without any significant problems, then your installation of Alfresco Community was successful.

Any Comments, Always Welcome!