10-25-2011 11:56 AM
sudo su
cd <any directory>./alfresco-community-4.0.a-installer-linux-x64.bincreateuser -P -U postgres -s -e -h /var/opt/alfresco-4.0.a/postgresql -p <new psql port as defined in install> <new user - same as your old database owner> sudo createdb -U <new user> -O alfresco -h /var/opt/alfresco-4.0.a/postgresql -p 5433 alfresco2 psql -U <new user> -h /var/opt/alfresco-4.0.a/postgresql -p 5433 alfresco2 < <your database dump file># Index Recovery Mode
#————-
index.recovery.mode=FULLindex.subsystem.name=solrindex.subsystem.name=lucene service alfresco start log4j.appender.File.File=/alfresco.loglog4j.appender.File.File=/var/opt/alfresco-4.0.a/alfresco.logindex.recovery.mode=AUTO### E-mail site invitation setting ###
notification.email.siteinvite=true
mail.host=localhost
mail.port=25
mail.username=anonymous
mail.password=
mail.encoding=UTF-8
mail.from.default=<admin email>
mail.smtp.auth=false#port = 5432port = <your new database port> service alfresco restart su <username>
echo '*:*:*:<pg username>:<pg password>' > ~/.pgpass
chmod 0600 ~/.pgpass#!/bin/bash
bdate=`date +%F`
############## Cold Backup for Alfresco on PostgreSql
blocation="<backup location>"
busername="<username>" #This needs to be the same username for system and MySql in order for authentication to work
bdatabasename="<your database name>"
sudo mkdir -p $blocation/$bdate/alfresco
service alfresco stop
wait
sh /var/opt/alfresco-4.0.a/postgresql/scripts/ctl.sh start
wait
alfbackup() {
sudo -u $busername /var/opt/alfresco-4.0.a/postgresql/bin/pg_dump -U $busername -h /var/opt/alfresco-4.0.a/postgresql -p 5433 $bdatabasename > $blocation/$bdate/alfresco/$bdatabasename.dump
tar czf $blocation/$bdate/alfresco/alfresco.tgz /var/opt/alfresco-4.0.a/alf_data
}
alfbackup
wait
sh /var/opt/alfresco-4.0.a/postgresql/scripts/ctl.sh stop
wait
service alfresco start
############## Remove old backups
olddelete=`date –date="7 days ago" +%F`
sudo rm -r $blocation/$olddelete
01-04-2012 04:36 PM
Create a new database user (you will understand why when it comes to backing up):
createuser -P -U postgres -s -e -h /var/opt/alfresco-4.0.a/postgresql -p <new psql port as defined in install> <new user - same as your old database owner>
Create a new database:sudo createdb -U <new user> -O alfresco -h /var/opt/alfresco-4.0.a/postgresql -p 5433 alfresco2
Restore your old database to the new:psql -U <new user> -h /var/opt/alfresco-4.0.a/postgresql -p 5433 alfresco2 < <your database dump file>
(If the old database owner does not exist in the new database, Postgre will throw errors in the import)
01-04-2012 04:48 PM
01-05-2012 09:11 AM
01-05-2012 09:51 AM
01-05-2012 11:16 PM
05-03-2012 10:47 AM
10-20-2012 12:33 PM
10-22-2012 05:38 AM
replication.enabled=false
db.schema.update=true
#
# Index Recovery Mode
#————-
index.recovery.mode=FULL
### E-mail site invitation setting ###
activities.feed.notifier.enabled=false
### CIFS Server Configuration ###
cifs.serverName=${localname}
#rmi#
#monitor.rmi.service.port=50508
#alfresco.rmi.services.external.host=172.16.0.49
### Solr indexing ###
index.subsystem.name=lucene
10-25-2012 12:52 AM
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.