[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Debian-sf-users] sourceforge database backup
From: |
Christian BAYLE |
Subject: |
Re: [Debian-sf-users] sourceforge database backup |
Date: |
Thu, 04 Apr 2002 10:35:20 +0200 |
Mathieu Peltier wrote:
>
> Hi
>
> I am new to Debian-sf. I have read this mail of Roland Mas about sourceforge
> database backup:
> http://mail.freesoftware.fsf.org/pipermail/debian-sf-users/2002-February/000104.html
>
> Why not using the pg_dump postgres command?
I think this is because it's slow and import is tricky
(It seems to me, not so obvious to choose the good options)
This is just and easy way to make a fast save of the DB,
but pg_dump should work too :)
>
> ---------------------------------------
> #! /bin/sh
>
> DATABASE=sourceforge
> BACKUP=/var/lib/sourceforge/dumps/sourceforge.dump
>
> echo Saving $DATABASE database into text file: $BACKUP
> mv $BACKUP.gz $BACKUP.gz.old
> pg_dump $DATABASE | gzip > $BACKUP.gz
> chmod 400 $BACKUP.gz
> echo done
> ---------------------------------------
>
> (use then
> createdb sourceforge
> gunzip -c sourceforge.dump.gz | psql sourceforge
> to restore the postgresql database)
>
> ps: Thanks to the authors of debian-sf package!
>
> --
> Mathieu Peltier
>
> _______________________________________________
> Debian-sf-users mailing list
> address@hidden
> http://mail.freesoftware.fsf.org/mailman/listinfo/debian-sf-users
--
Christian Bayle
===============================================================================
E-mail: address@hidden