linux-lvm.redhat.com archive mirror
 help / color / mirror / Atom feed
* Odp: [linux-lvm] Using pvcreate with file...
@ 2006-07-31 18:41 Bartosz Brewinski
  0 siblings, 0 replies; only message in thread
From: Bartosz Brewinski @ 2006-07-31 18:41 UTC (permalink / raw)
  To: linux-lvm

connect "vm1disk" file to "/dev/loop0" device:
# losetup /dev/loop0 vm1disk
display info about /dev/loop0:
# losetup /dev/loop0
use it to create pv:
# pvcreate /dev/loop0

later delete the /dev/loop0 <-> vm1disk binding by issuing command:
# losetup -d /dev/loop0
(do it after "pvremove /dev/loop0")

cheers,
bartek

>>> ahairape@mail.cern.ch 2006-07-31 19:59:27 >>>
Hello,

I am newbe to the lvm and I have the following issue:
My system is partitioned in the following way:

===============================================================
   Device Boot      Start         End      Blocks   Id  System
/dev/hda1   *           1          16      128488+  83  Linux
/dev/hda2              17        4767    38162407+  83  Linux
/dev/hda3            4768        4865      787185   82  Linux swap
===============================================================
There is no free space left on the disk.

I created the separate files, which I want to be lvm-enabled; I 
used the following commands:

==============================================================
#> cd /
#> dd if=/dev/zero  of=vm1disk bs=1k seek=16384k count=1
#> mkfs -t ext3 vm1disk

#> dd if=/dev/zero of=vm1swap bs=1024k count=1 
#> mkswap vm1swap
==============================================================

Now I want to initialize that "disk" for lvm-use.
So what I need to do?

pvcrete ..........................?

I had a look at the documentation, but they deal with real partitions
and disks (as far as I understood), not with files...

Thanks in advance to everyone who responds,
Arsen. 

_______________________________________________
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] only message in thread

only message in thread, other threads:[~2006-07-31 18:41 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-07-31 18:41 Odp: [linux-lvm] Using pvcreate with file Bartosz Brewinski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).