pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
File system level backup
7+ messages / 5 participants
[nested] [flat]

* File system level backup
@ 2003-10-17 09:13 Ganesan Kanavathy <ganesh@magnusquest.com>
  2003-10-22 01:12 ` Re: File system level backup Ganesan Kanavathy <ganesh@magnusquest.com>
  2003-10-22 01:12 ` Re: File system level backup Ganesan Kanavathy <ganesh@magnusquest.com>
  0 siblings, 2 replies; 7+ messages in thread

From: Ganesan Kanavathy @ 2003-10-17 09:13 UTC (permalink / raw)
  To: pgsql-admin

Dear all,
 
All the while I was doing pg_dump as backup method for my pgsql db.
Today I came across File system level backup on Postgresql
Documentation.
 
After reading it, I am quite unsure whether File system level backup is
better than pg_dump. 
 
Furthermore, do we really need to do File system level backup or pg_dump
is good enough?
 
Any suggestion is much appreciated.
 
Regards,
ganesh

^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: File system level backup
  2003-10-17 09:13 File system level backup Ganesan Kanavathy <ganesh@magnusquest.com>
@ 2003-10-22 01:12 ` Ganesan Kanavathy <ganesh@magnusquest.com>
  2003-10-22 02:25   ` Re: File system level backup Jamie Lawrence <jal@jal.org>
  1 sibling, 1 reply; 7+ messages in thread

From: Ganesan Kanavathy @ 2003-10-22 01:12 UTC (permalink / raw)
  To: pgsql-admin

Please help me with question. So far no replies.
 
Regards,
ganesh
 
-----Original Message-----
From: pgsql-admin-owner@postgresql.org
[mailto:pgsql-admin-owner@postgresql.org] On Behalf Of Ganesan Kanavathy
Sent: Friday, October 17, 2003 5:14 PM
To: pgsql-admin@postgresql.org
Subject: [ADMIN] File system level backup
 
Dear all,
 
All the while I was doing pg_dump as backup method for my pgsql db.
Today I came across File system level backup on Postgresql
Documentation.
 
After reading it, I am quite unsure whether File system level backup is
better than pg_dump. 
 
Furthermore, do we really need to do File system level backup or pg_dump
is good enough?
 
Any suggestion is much appreciated.
 
Regards,
ganesh

^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: File system level backup
  2003-10-17 09:13 File system level backup Ganesan Kanavathy <ganesh@magnusquest.com>
  2003-10-22 01:12 ` Re: File system level backup Ganesan Kanavathy <ganesh@magnusquest.com>
@ 2003-10-22 02:25   ` Jamie Lawrence <jal@jal.org>
  0 siblings, 0 replies; 7+ messages in thread

From: Jamie Lawrence @ 2003-10-22 02:25 UTC (permalink / raw)
  To: Ganesan Kanavathy <ganesh@magnusquest.com>; +Cc: pgsql-admin


> Dear all,
>  
> All the while I was doing pg_dump as backup method for my pgsql db.
> Today I came across File system level backup on Postgresql
> Documentation.
>  
> After reading it, I am quite unsure whether File system level backup is
> better than pg_dump. 

You have to look at your needs.
  
> Furthermore, do we really need to do File system level backup or pg_dump
> is good enough?

File system level backup is typically complicated to design, and is
specific to your needs.

pg_dump is nearly universally usable, but might not meet your needs, if
you are a 24x7 shop. Online backup is almost always specific to your
site, usually a big deal to set up, and rarely impossible.

> Any suggestion is much appreciated.

Without more information about what you're doing, I can't say anything
more. But most likely, pg_dump will work for you. It covers most cases.

-j

-- 
Jamie Lawrence                                        jal@jal.org
Helpful Hint: Unbreakable toys can be used to break other toys.





^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: File system level backup
  2003-10-17 09:13 File system level backup Ganesan Kanavathy <ganesh@magnusquest.com>
@ 2003-10-22 01:12 ` Ganesan Kanavathy <ganesh@magnusquest.com>
  2003-10-22 01:38   ` Re: File system level backup Bruce Momjian <pgman@candle.pha.pa.us>
  2003-10-22 12:38   ` Re: File system level backup Jeff <threshar@torgo.978.org>
  2003-10-22 15:11   ` Re: File system level backup scott.marlowe <scott.marlowe@ihs.com>
  1 sibling, 3 replies; 7+ messages in thread

From: Ganesan Kanavathy @ 2003-10-22 01:12 UTC (permalink / raw)
  To: pgsql-admin

Please help me with question. So far no replies.
 
Regards,
ganesh
 
-----Original Message-----
From: pgsql-admin-owner@postgresql.org
[mailto:pgsql-admin-owner@postgresql.org] On Behalf Of Ganesan Kanavathy
Sent: Friday, October 17, 2003 5:14 PM
To: pgsql-admin@postgresql.org
Subject: [ADMIN] File system level backup
 
Dear all,
 
All the while I was doing pg_dump as backup method for my pgsql db.
Today I came across File system level backup on Postgresql
Documentation.
 
After reading it, I am quite unsure whether File system level backup is
better than pg_dump. 
 
Furthermore, do we really need to do File system level backup or pg_dump
is good enough?
 
Any suggestion is much appreciated.
 
Regards,
ganesh

^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: File system level backup
  2003-10-17 09:13 File system level backup Ganesan Kanavathy <ganesh@magnusquest.com>
  2003-10-22 01:12 ` Re: File system level backup Ganesan Kanavathy <ganesh@magnusquest.com>
@ 2003-10-22 01:38   ` Bruce Momjian <pgman@candle.pha.pa.us>
  2 siblings, 0 replies; 7+ messages in thread

From: Bruce Momjian @ 2003-10-22 01:38 UTC (permalink / raw)
  To: Ganesan Kanavathy <ganesh@magnusquest.com>; +Cc: pgsql-admin


pg_dump is fine, in fact better.  For a file system backup, you have to
stop the postmaster, backup, then restart it.

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

Ganesan Kanavathy wrote:
> Please help me with question. So far no replies.
>  
> Regards,
> ganesh
>  
> -----Original Message-----
> From: pgsql-admin-owner@postgresql.org
> [mailto:pgsql-admin-owner@postgresql.org] On Behalf Of Ganesan Kanavathy
> Sent: Friday, October 17, 2003 5:14 PM
> To: pgsql-admin@postgresql.org
> Subject: [ADMIN] File system level backup
>  
> Dear all,
>  
> All the while I was doing pg_dump as backup method for my pgsql db.
> Today I came across File system level backup on Postgresql
> Documentation.
>  
> After reading it, I am quite unsure whether File system level backup is
> better than pg_dump. 
>  
> Furthermore, do we really need to do File system level backup or pg_dump
> is good enough?
>  
> Any suggestion is much appreciated.
>  
> Regards,
> ganesh

-- 
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073



^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: File system level backup
  2003-10-17 09:13 File system level backup Ganesan Kanavathy <ganesh@magnusquest.com>
  2003-10-22 01:12 ` Re: File system level backup Ganesan Kanavathy <ganesh@magnusquest.com>
@ 2003-10-22 12:38   ` Jeff <threshar@torgo.978.org>
  2 siblings, 0 replies; 7+ messages in thread

From: Jeff @ 2003-10-22 12:38 UTC (permalink / raw)
  To: Ganesan Kanavathy <ganesh@magnusquest.com>; +Cc: pgsql-admin

On Wed, 22 Oct 2003 09:12:40 +0800
"Ganesan Kanavathy" <ganesh@magnusquest.com> wrote:

> All the while I was doing pg_dump as backup method for my pgsql db.
> Today I came across File system level backup on Postgresql
> Documentation.
>  

If you do a filesystem level backup the only "safe" way to do this is to
either stop postgres and then backup, or if you are using a logical
volume manager take a snapshot.    You cannot just "tar" a "live" pgdata
directory as the contents will change as tar goes through each file and
you'll be left with a corrupt database.


-- 
Jeff Trout <jeff@jefftrout.com>
http://www.jefftrout.com/
http://www.stuarthamm.net/



^ permalink  raw  reply  [nested|flat] 7+ messages in thread

* Re: File system level backup
  2003-10-17 09:13 File system level backup Ganesan Kanavathy <ganesh@magnusquest.com>
  2003-10-22 01:12 ` Re: File system level backup Ganesan Kanavathy <ganesh@magnusquest.com>
@ 2003-10-22 15:11   ` scott.marlowe <scott.marlowe@ihs.com>
  2 siblings, 0 replies; 7+ messages in thread

From: scott.marlowe @ 2003-10-22 15:11 UTC (permalink / raw)
  To: Ganesan Kanavathy <ganesh@magnusquest.com>; +Cc: pgsql-admin

On Wed, 22 Oct 2003, Ganesan Kanavathy wrote:

> All the while I was doing pg_dump as backup method for my pgsql db.
> Today I came across File system level backup on Postgresql
> Documentation.
>  
> After reading it, I am quite unsure whether File system level backup is
> better than pg_dump. 
>  
> Furthermore, do we really need to do File system level backup or pg_dump
> is good enough?

The two are more complementary than equivalent.  Here's a short list of 
the pros and cons of each:

Advantages of pg_dump:  
* transportable between versions of postgresql / other RDBMSs
* can be run while the database is up and get a consistent snapshot
* can be run from a remote machine easily.

Disadvantages of pg_dump:
* slower than a file system backup
* may require hand editing of the dump before restoring (rare, but has 
happened due to some obscure bugs.)

Advantages of file level backup:
* Very fast
* Can be used to clone a database quickly
* Is a great way to backup a database before a minor revision (i.e. 7.3.3 
to 7.3.4) in case things go horribly wrong.

Disadvantages of file level backup:
* Server needs to be shut down to get a consistent backup
* file level database backups are not very portable.  I.e. if you want to 
restore a file level backup, the target database must be running the same 
base version of postgresql, must be on the same architecture, and must 
have many of the compile time options be the same, or it won't work.

Generally, pg_dump is preferred, but file level backups have their place.




^ permalink  raw  reply  [nested|flat] 7+ messages in thread


end of thread, other threads:[~2003-10-22 15:11 UTC | newest]

Thread overview: 7+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2003-10-17 09:13 File system level backup Ganesan Kanavathy <ganesh@magnusquest.com>
2003-10-22 01:12 ` Ganesan Kanavathy <ganesh@magnusquest.com>
2003-10-22 02:25   ` Jamie Lawrence <jal@jal.org>
2003-10-22 01:12 ` Ganesan Kanavathy <ganesh@magnusquest.com>
2003-10-22 01:38   ` Bruce Momjian <pgman@candle.pha.pa.us>
2003-10-22 12:38   ` Jeff <threshar@torgo.978.org>
2003-10-22 15:11   ` scott.marlowe <scott.marlowe@ihs.com>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox