All of lore.kernel.org
 help / color / mirror / Atom feed
* [linux-lvm] Backup of ROOT Partition.
@ 2008-06-30 21:06 Jean-Philippe Villeneuve
  2008-07-01  8:19 ` Alessandro Ferrari
  2008-07-01 11:03 ` Bryan Kadzban
  0 siblings, 2 replies; 8+ messages in thread
From: Jean-Philippe Villeneuve @ 2008-06-30 21:06 UTC (permalink / raw)
  To: linux-lvm

Hi,
I would like to know if I can backup all my system partitions(ROOT 
included) using a snapshot? I searched the internet for this information 
and found nobody that said that this was possible or not.  if someone 
has a link to a page that describes this I would really appreciate this 
information.
Thank You.

Jean-Philippe Villeneuve
Programmeur R&D/Programmer R&D
MULTI-�LECTRONIQUE (MTE) INC.
www.multi-electronique.com
T�l. : (418) 724-5835

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

* Re: [linux-lvm] Backup of ROOT Partition.
  2008-06-30 21:06 [linux-lvm] Backup of ROOT Partition Jean-Philippe Villeneuve
@ 2008-07-01  8:19 ` Alessandro Ferrari
  2008-07-01 11:03 ` Bryan Kadzban
  1 sibling, 0 replies; 8+ messages in thread
From: Alessandro Ferrari @ 2008-07-01  8:19 UTC (permalink / raw)
  To: LVM general discussion and development

Hi Jean-Philippe,

yes, I make backup of my ROOT partition every day using snapshot 
functionality!

Alessandro

----- Original Message ----- 
From: "Jean-Philippe Villeneuve" <jeepii@globetrotter.net>
To: <linux-lvm@redhat.com>
Sent: Monday, June 30, 2008 11:06 PM
Subject: [linux-lvm] Backup of ROOT Partition.


> Hi,
> I would like to know if I can backup all my system partitions(ROOT 
> included) using a snapshot? I searched the internet for this information 
> and found nobody that said that this was possible or not.  if someone has 
> a link to a page that describes this I would really appreciate this 
> information.
> Thank You.
>
> Jean-Philippe Villeneuve
> Programmeur R&D/Programmer R&D
> MULTI-�LECTRONIQUE (MTE) INC.
> www.multi-electronique.com
> T�l. : (418) 724-5835
>
>
> _______________________________________________
> linux-lvm mailing list
> linux-lvm@redhat.com
> https://www.redhat.com/mailman/listinfo/linux-lvm
> read the LVM HOW-TO at http://tldp.org/HOWTO/LVM-HOWTO/ 

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

* Re: [linux-lvm] Backup of ROOT Partition.
  2008-06-30 21:06 [linux-lvm] Backup of ROOT Partition Jean-Philippe Villeneuve
  2008-07-01  8:19 ` Alessandro Ferrari
@ 2008-07-01 11:03 ` Bryan Kadzban
  2008-07-01 11:13   ` Dan Shearer
  2008-07-02 13:40   ` Jean-Philippe Villeneuve
  1 sibling, 2 replies; 8+ messages in thread
From: Bryan Kadzban @ 2008-07-01 11:03 UTC (permalink / raw)
  To: LVM general discussion and development

-----BEGIN PGP SIGNED MESSAGE-----
Hash: RIPEMD160

Jean-Philippe Villeneuve wrote:
> I would like to know if I can backup all my system partitions(ROOT 
> included) using a snapshot?

Depends on what you mean by "backup [...] using a snapshot".

If you mean taking a snapshot, then mounting it somewhere and pointing
your backup software to that mount point, then unmounting and deleting
the snapshot after the backup is done, then yes, it should work fine.

If you mean taking a snapshot and leaving it around forever *as* the
backup, then that will work -- but the more backups you have, the slower
LVM gets (currently).  This is because of the copy-on-write code: every
time the root logical volume changes, all of the snapshots need to be
updated.  If you only have one or two snapshots, this isn't so bad, but
if you had (say) 20, writing to your real root LV would slow to a crawl.

There is some code hanging around somewhere that I *think* is supposed
to handle this better, but I don't know the status...
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFIag79S5vET1Wea5wRA6aRAKCuFkT9BXlmtiyke1bFPw5CJYGtRQCeI27D
++3wT6+y0d3oYjmxEVA2NmY=
=1UlT
-----END PGP SIGNATURE-----

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

* Re: [linux-lvm] Backup of ROOT Partition.
  2008-07-01 11:03 ` Bryan Kadzban
@ 2008-07-01 11:13   ` Dan Shearer
  2008-07-01 16:48     ` Bryan Kadzban
  2008-07-02 13:40   ` Jean-Philippe Villeneuve
  1 sibling, 1 reply; 8+ messages in thread
From: Dan Shearer @ 2008-07-01 11:13 UTC (permalink / raw)
  To: LVM general discussion and development

On Tue, Jul 01, 2008 at 07:03:26AM -0400, Bryan Kadzban wrote:

> If you mean taking a snapshot and leaving it around forever *as* the
> backup, then that will work -- but the more backups you have, the slower
> LVM gets (currently).  This is because of the copy-on-write code: every
> time the root logical volume changes, all of the snapshots need to be
> updated.  If you only have one or two snapshots, this isn't so bad, but
> if you had (say) 20, writing to your real root LV would slow to a crawl.
> 
> There is some code hanging around somewhere that I *think* is supposed
> to handle this better, but I don't know the status...

You may be referring to ddsnap, go to
http://code.google.com/p/zumastor/source/browse and look at
svn/trunk/ddsnap. And you can check out and build from google code too
of course.

I find it difficult to tell where this is going though, there doesn't
seem to be disagreement between the people who maintain ddsnap and the
people who maintain lvm2, but I haven't found any statements about what
the way forward is.

Any comments from lvm2 maintainers?

-- 
Dan Shearer
dan@shearer.org

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

* Re: [linux-lvm] Backup of ROOT Partition.
  2008-07-01 11:13   ` Dan Shearer
@ 2008-07-01 16:48     ` Bryan Kadzban
  0 siblings, 0 replies; 8+ messages in thread
From: Bryan Kadzban @ 2008-07-01 16:48 UTC (permalink / raw)
  To: LVM general discussion and development

[-- Attachment #1: Type: text/plain, Size: 675 bytes --]

On Tue, Jul 01, 2008 at 08:43:32PM +0930, Dan Shearer wrote:
> http://code.google.com/p/zumastor/source/browse

The "zumastor" name rings a few bells, so I do believe that's what I was
thinking of, yes.

> there doesn't seem to be disagreement between the people who maintain
> ddsnap and the people who maintain lvm2, but I haven't found any
> statements about what the way forward is.

As a user, I'm just waiting to see what happens, and using the plain old
LVM code in the meantime.  That works out well enough, as long as I'm
aware of its limitations, which is the only reason I mentioned the poor
write performance with large numbers of snapshots.  :-)

So we'll see.


[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

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

* Re: [linux-lvm] Backup of ROOT Partition.
  2008-07-01 11:03 ` Bryan Kadzban
  2008-07-01 11:13   ` Dan Shearer
@ 2008-07-02 13:40   ` Jean-Philippe Villeneuve
  2008-07-16 21:03     ` Jean-Philippe Villeneuve
  1 sibling, 1 reply; 8+ messages in thread
From: Jean-Philippe Villeneuve @ 2008-07-02 13:40 UTC (permalink / raw)
  To: LVM general discussion and development


Bryan Kadzban wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: RIPEMD160
>
> Jean-Philippe Villeneuve wrote:
>   
>> I would like to know if I can backup all my system partitions(ROOT 
>> included) using a snapshot?
>>     
>
> Depends on what you mean by "backup [...] using a snapshot".
>
> If you mean taking a snapshot, then mounting it somewhere and pointing
> your backup software to that mount point, then unmounting and deleting
> the snapshot after the backup is done, then yes, it should work fine.
>   
This is exactly what I want to do.  I just want the latest 
configuration, users files etc. I realy don't need files at a specific 
date with tons of backups.

Than you all for the fast and acurate answers.

Jean-Philippe

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

* Re: [linux-lvm] Backup of ROOT Partition.
  2008-07-02 13:40   ` Jean-Philippe Villeneuve
@ 2008-07-16 21:03     ` Jean-Philippe Villeneuve
  2008-07-16 22:22       ` Bryan Kadzban
  0 siblings, 1 reply; 8+ messages in thread
From: Jean-Philippe Villeneuve @ 2008-07-16 21:03 UTC (permalink / raw)
  To: LVM general discussion and development

I tried the folowing recipe: 
http://tldp.org/HOWTO/LVM-HOWTO/snapshots_backup.html with the folowing 
script:

/****************************/

#!/bin/sh
BAKLVMNAME=sysbackup
lvcreate -L592M -s -n $BAKLVMNAME  /dev/VolGroup00/LogVol00
mount /dev/VolGroup00/$BAKLVMNAME /mnt/sysbackup/ -o ro
cd /mnt/sysbackup
time tar -cjvpf /mnt/serveur/backSysVol.bz2 *
cd ..
umount /mnt/sysbackup
lvremove -f /dev/VolGroup00/$BAKLVMNAME

/****************************/

I get the folowing error:
  Rounding up size to full physical extent 608.00 MB
  Insufficient free extents (1) in volume group VolGroup00: 19 required

It works find if I do it with -L20M.
How do I change the LogicalVolumeSize?

according to 'df' I have plenty of space for data.

# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/VolGroup00-LogVol00
                       35G  6.0G   27G  19% /
/dev/md0              677G  270G  373G  42% /mnt/serveur
/dev/sda1             190M   26M  155M  15% /boot
tmpfs                 374M     0  374M   0% /dev/shm

Am I missing something?

Jean-Philippe Villeneuve wrote:
>
> Bryan Kadzban wrote:
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: RIPEMD160
>>
>> Jean-Philippe Villeneuve wrote:
>>  
>>> I would like to know if I can backup all my system partitions(ROOT 
>>> included) using a snapshot?
>>>     
>>
>> Depends on what you mean by "backup [...] using a snapshot".
>>
>> If you mean taking a snapshot, then mounting it somewhere and pointing
>> your backup software to that mount point, then unmounting and deleting
>> the snapshot after the backup is done, then yes, it should work fine.
>>   
> This is exactly what I want to do.  I just want the latest 
> configuration, users files etc. I realy don't need files at a specific 
> date with tons of backups.
>
> Than you all for the fast and acurate answers.
>
> Jean-Philippe
>
>
> _______________________________________________
> linux-lvm mailing list
> linux-lvm@redhat.com
> https://www.redhat.com/mailman/listinfo/linux-lvm
> read the LVM HOW-TO at http://tldp.org/HOWTO/LVM-HOWTO/
>

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

* Re: [linux-lvm] Backup of ROOT Partition.
  2008-07-16 21:03     ` Jean-Philippe Villeneuve
@ 2008-07-16 22:22       ` Bryan Kadzban
  0 siblings, 0 replies; 8+ messages in thread
From: Bryan Kadzban @ 2008-07-16 22:22 UTC (permalink / raw)
  To: LVM general discussion and development

-----BEGIN PGP SIGNED MESSAGE-----
Hash: RIPEMD160

Jean-Philippe Villeneuve wrote:
> I get the folowing error:
> 
> Insufficient free extents (1) in volume group VolGroup00: 19 required
> 
> It works find if I do it with -L20M.

You need to either grow the physical volume if possible, add extra
physical volumes to the volume group (and therefore grow the volume
group), or shrink the existing logical volume.

> according to 'df' I have plenty of space for data.

Yeah, but that's not the space that logical volumes use.

LVs are allocated from inside the group-of-physical-volumes in a VG.
Think of LVs like partitions: if you have tons of space available on the
FS that's inside a partition, that doesn't necessarily mean you can add
a new partition to the disk.  You'll have to either shrink the existing
LV, or add more physical volumes to the group.

I believe either can be done while the FS is mounted.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFIfnS4S5vET1Wea5wRA2bLAKDbIXtd9c56WFCWM8hf2Au5t7D/TgCgoV0k
BPTR74O1ES4C1bFJKdfhESI=
=p+QB
-----END PGP SIGNATURE-----

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

end of thread, other threads:[~2008-07-16 22:23 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-06-30 21:06 [linux-lvm] Backup of ROOT Partition Jean-Philippe Villeneuve
2008-07-01  8:19 ` Alessandro Ferrari
2008-07-01 11:03 ` Bryan Kadzban
2008-07-01 11:13   ` Dan Shearer
2008-07-01 16:48     ` Bryan Kadzban
2008-07-02 13:40   ` Jean-Philippe Villeneuve
2008-07-16 21:03     ` Jean-Philippe Villeneuve
2008-07-16 22:22       ` Bryan Kadzban

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.