Pack ZODB with repozo.py

Hi I have created a script which will pack zodb. here is the code:

#pack zodb with repozo.py

### CONFIGURATION START ##########
ZOPE_HOME=/home/tareq/Plone-3.1/zeocluster/parts/zope2 # this is the zope home find your zope home #from zmi control panel
PYTHONPATH=$ZOPE_HOME/lib/python # this is the python path that the zope is using
PATH_TO_REPOZOPY=/home/tareq/Plone-3.1/zeocluster/bin/repozo.py # find the repozo.py to find in #terminal type: locate repozo.py
BACKUP_DIRECTORY=/home/tareq/plone/Learning # where you want to keep the backup of data.fs file
PATH_TO_DATAFS_FILE=/home/tareq/Plone-3.1/zeocluster/var/filestorage/Data.fs #this is the path of zodb #database Data.fs

################### N-O N-E-E-D T-O E-D-I-T A-F-T-E-R T-H-I-S L-I-N-E ##############################
export PYTHONPATH #this is needed to be done else repozo.py cant find path

COMMAND_DB_BACKUP=”$PATH_TO_REPOZOPY -BvQ -r $BACKUP_DIRECTORY -f $PATH_TO_DATAFS_FILE” # creating the command here
`${COMMAND_DB_BACKUP}` # this line executes the command

### HOW TO RUN THIS COMMAND ##########

#1. Open Terminal type sh packzodb.sh
#see files created in the BACKUP_DIRECTORY
# Simple 😉

Advertisements
About

Work is fun!

Tagged with: , , , , , ,
Posted in Linux, ploneCMS, Ubuntu, Zope
2 comments on “Pack ZODB with repozo.py
  1. Patrick says:

    Hi,

    this script is not to pack, but to create a backup of the particular ZODB…

    – Patrick

  2. Rosemary says:

    This is not for packing.I will be grateful if it can modified for pack

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Disclaimer
All content provided on this "tareqalam.com" blog is for informational purposes only. The owner of this blog makes no representations as to the accuracy or completeness of any information on this site or found by following any link on this site. The owner of [tareqalam.wordpress.com] will not be liable for any errors or omissions in this information nor for the availability of this information. The owner will not be liable for any losses, injuries, or damages from the display or use of this information.
October 2008
M T W T F S S
« Sep   Nov »
 12345
6789101112
13141516171819
20212223242526
2728293031  

Enter your email address to follow this blog and receive notifications of new posts by email.

Join 23 other followers

%d bloggers like this: