cancel
Showing results for 
Search instead for 
Did you mean: 

good instructions for upgrading Alfresco Community

pacco_robin
Champ in-the-making
Champ in-the-making
Hi,

I am running Alfresco Community 4.2.e. with mySQL 5.5 on Ubuntu 12.04 LTS and I would like to upgrade to 4.2.f.

Guidelines are provided here: http://docs.alfresco.com/community/topic/com.alfresco.community.doc/tasks/upgrade-process.html

As I am new to Linux I would appriciate it if someone can help me with more detailed information how to upgrade using my setup.

Thanks a lot.

Regards,

Frank
4 REPLIES 4

jpotts
World-Class Innovator
World-Class Innovator
Frank,

Those are pretty detailed steps. Perhaps you can post the specifics that are giving you trouble?

Jeff

kuldeep
Champ in-the-making
Champ in-the-making
This tutorial is for Alfresco community with Postgres but I am hoping this gives you some idea

http://ezref.info/21+steps+to+upgrade+Alfresco+community+edition.html

pacco_robin
Champ in-the-making
Champ in-the-making
Dear Jeff, Kuldeep,

I tried the steps mentioned in http://ezref.info/21+steps+to+upgrade+Alfresco+community+edition.html. In the end Alfresco didn't work anymore and I had to revert back to the old situation.

Let me try it another time later this week and provide you with detailed steps.

Thanks for replying.

Regards,

Frank

Dear Jeff, Kuldeep,

I retried step by step and now it works!

In order to help others in the future I explained all steps below. I hope this is appreciated.

Regards,

Frank

———-

Steps to upgrade Alfresco community edition 4.2.e using mySQL and Ubuntu 12.04LTS

1. Stop Alfresco server. From the Alfresco installation folder, execute the command:
sudo service alfresco stop

2. Backup Alfresco installation
sudo cp /opt/"old alfresco folder" /opt/"backup_of_old_alfresco-folder" -R

3. Turn off Solr
Edit the alfresco-global.properties
sudo vi /opt/"old alfresco folder"/tomcat/shared/classes/alfresco-global.properties

Change solr indexing as under:
### Solr indexing ###
index.subsystem.name=noindex
dir.keystore=${dir.root}/keystore
#solr.port.ssl=8443

(replace solr with noindex)

4. Start Alfresco server
sudo service alfresco start

Wait for Alfresco to start up
I use:
sudo tail /opt/"old alfresco folder"/tomcat/logs/catalina.out -f

5. Stop Alfresco server
sudo service alfresco stop

6. Check if mySQL is running
mysqladmin -u root -p status

7. Backup the Alfresco database to the tmp folder
I have to do this from the console as mySQL is restriced.
sudo mysqldump -u root -p alfresco > /tmp/alfdbdump.sql
Then move the dump file to /opt
sudo mv /tmp/alfdbdump.sql /opt

8. Delete the Alfresco service file
sudo rm /etc/init.d/alfresco

9. Drop the Alfresco database
I have to do this from the console as mySQL is restriced.
sudo mysqladmin -u root -p drop alfresco

10. Download latest Alfresco version and FTP it to the Ubuntu server

11. Move it from the home folder to the /opt folder and go there
sudo mv "alfresco download" /opt
cd /opt

12. Create the new Alfresco database
I have to do this from the console as mySQL is restriced.
mysql -u root -p
mysql> CREATE DATABASE alfresco DEFAULT CHARACTER SET utf8;
mysql> GRANT ALL PRIVILEGES ON alfresco.* TO alfresco@localhost IDENTIFIED BY 'alfresco user password';
mysql> FLUSH PRIVILEGES;
mysql> exit

13. Make the Alfresco binary installer executable
sudo chmod +x "alfresco download"

13. Install the new version
sudo ./"alfresco download" –mode text
(I use English, Advanced, Java Y, PostgreSQL N, SharePoint Y, Web Quick Start Y, Google Docs Y, LibreOffice Y)

Select a different folder for installation, e.g. /opt/alfresco-x.y.z

Database configuration
JDBC URL: [jdbcSmiley Tongueostgresql://localhost/alfresco]: jdbc:mysql://localhost/alfresco?useUnicode=yes&characterEncoding=UTF-8
JDBC Driver: [org.postgresql.Driver]: org.gjt.mm.mysql.Driver
Database name: alfresco
Username: alfresco
Password: alfresco user password

I leave port settings as it is.

Supply an admin password.

Install Alfresco as a service.

Before launching Alfresco Community Share, make sure you copied mysql-connector-java-x.x.x-bin.jar to tomcat/lib.
sudo cp /home/[user]/mysql-connector-java-x.x.x-bin.jar /opt/alfresco-x.y.z/tomcat/lib

DO NOT LAUNCH THE ALFRESCO COMMUNITY SHARE!

14. Restore the database
Move the dump from /opt to the /tmp folder
sudo mv /opt/alfdbdump.sql /tmp
Restore the database
I have to do this from the console as mySQL is restriced.
sudo mysql -u root -p alfresco < /tmp/alfdbdump.sql

15. Stop Alfresco
sudo service alfresco stop

16. Move the original content to the new location
cd /opt/"old alfresco folder"/alf_data
sudo mv contentstore contentstore.deleted /opt/alfresco-x.y.z/alf_data/

17. Turn off Solr
Edit the alfresco-global.properties
sudo vi /opt/alfresco-x.y.z/tomcat/shared/classes/alfresco-global.properties

Change solr indexing as under:
### Solr indexing ###
index.subsystem.name=noindex
dir.keystore=${dir.root}/keystore
#solr.port.ssl=8443

(replace solr with noindex)

18. Start Alfresco
sudo service alfresco start

Wait for Alfresco to start up
I use:
sudo tail /opt/alfresco-x.y.z/tomcat/logs/catalina.out -f

19. Stop Alfresco server
sudo service alfresco stop

20. Turn on Solr
Edit the alfresco-global.properties
sudo vi /opt/alfresco-x.y.z/tomcat/shared/classes/alfresco-global.properties

Change solr indexing as under:
### Solr indexing ###
index.subsystem.name=solr
dir.keystore=${dir.root}/keystore
#solr.port.ssl=8443

(replace noindex with solr)

21. Put back any customization you did (ATTENTION, this depends on your configuration)
E.g.
1. Other changes to alfresco-global.properties
2. Secure Tomcat
cd /opt/alfresco-x.y.z/tomcat/webapps/ROOT
sudo vi index.html
<html>

<head>
<meta http-equiv="refresh" content="0;URL=https://[name].[domain].[extension]/share/">
</head>

<body>
</body>

</html>
3. Changes to tomcat
/opt/alfresco-x.y.z/tomcat/conf/tomcat-users.xml
4. Changes to vti
/opt/alfresco-x.y.z/tomcat/webapps/alfresco/WEB-INF/classes/alfresco/module/org.alfresco.module.vti/context
Change the name in vti.properties
5. Disable users to create or delete sites
Change the alfresco/public-services-security-context.xml file (in the default install found in /opt/alfresco.x.y.z/tomcat/webapps/alfresco/WEB-INF/classes/alfresco/public-services-security-context.xml)
Change from
org.alfresco.service.cmr.site.SiteService.createSite=ACL_ALLOW
to
org.alfresco.service.cmr.site.SiteService.createSite=ACL_METHOD.ROLE_ADMINISTRATOR
Also for deleteSite

22. Restart the server entirely
sudo reboot

ADDITIONALLY CLEAN UP
- remove the dump from /tmp
- remove the bin file from /opt
- remove the old Alfresco folder from /opt
- when everything is working ok, remove the backup from /opt