All of lore.kernel.org
 help / color / mirror / Atom feed
* [linux-lvm] create physical partition from logical partition
@ 2013-02-06 17:10 fakhreddine HABIB
  2013-02-07 11:01 ` [linux-lvm] Re : " georges.giralt
  2013-02-07 13:02 ` [linux-lvm] " Marian Csontos
  0 siblings, 2 replies; 6+ messages in thread
From: fakhreddine HABIB @ 2013-02-06 17:10 UTC (permalink / raw)
  To: linux-lvm


[-- Attachment #1.1: Type: text/plain, Size: 501 bytes --]

Hi,

   I nead please your help to create a physical partition from a logical
partition.

   I present my problem : I have the configuration (attached pic) of the
partitions.

   I use the centos system. The problem that my group volume "vg_rega" use
the whole of the physical disk. I want to install Ubuntu system with centos
(dual boot), but i need a physical partition to do that. How can'i convert
the " Unused Space " logical partition to physical partition to install
Ubuntu.

  Thank you.

F.H

[-- Attachment #1.2: Type: text/html, Size: 567 bytes --]

[-- Attachment #2: Screenshot.png --]
[-- Type: image/png, Size: 82029 bytes --]

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

* [linux-lvm] Re :  create physical partition from logical partition
  2013-02-06 17:10 [linux-lvm] create physical partition from logical partition fakhreddine HABIB
@ 2013-02-07 11:01 ` georges.giralt
  2013-02-07 13:02 ` [linux-lvm] " Marian Csontos
  1 sibling, 0 replies; 6+ messages in thread
From: georges.giralt @ 2013-02-07 11:01 UTC (permalink / raw)
  To: LVM general discussion and development

Hello !
I suppose you do not want to loose any data ?
If yes, I'll give only steps to follow and not detailed instructions in order for you to study and understand what you are doing and not break anything. 
Actually, given the picture shown, the volume group uses only the second partition of the physical disk (sda2) not the whole disk. But this is not relevant. 
At first, you have to calculate how many PE left free you have. Decide what number you will keep free for future Centos extension. 
Then, reduce the volume group size by the amount you can free (Number of PE x PE size)
If this is successful, Check that the now unallocated PE are at the end of sda2. 
Then reduce the size of the sda2 partition, freeing space for a new partition. 
Then create a new partition onto which you could install the new OS... 

Hope this helps. 
----- Mail d'origine -----
De: fakhreddine HABIB <fakhreddine2006@gmail.com>
À: linux-lvm@redhat.com
Envoyé: Wed, 06 Feb 2013 18:10:15 +0100 (CET)
Objet: [linux-lvm] create physical partition from logical partition

Hi,

   I nead please your help to create a physical partition from a logical
partition.

   I present my problem : I have the configuration (attached pic) of the
partitions.

   I use the centos system. The problem that my group volume "vg_rega" use
the whole of the physical disk. I want to install Ubuntu system with centos
(dual boot), but i need a physical partition to do that. How can'i convert
the " Unused Space " logical partition to physical partition to install
Ubuntu.

  Thank you.

F.H

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

* Re: [linux-lvm] create physical partition from logical partition
  2013-02-06 17:10 [linux-lvm] create physical partition from logical partition fakhreddine HABIB
  2013-02-07 11:01 ` [linux-lvm] Re : " georges.giralt
@ 2013-02-07 13:02 ` Marian Csontos
       [not found]   ` <CAMugGiHnARz60km5=0WjHw4UrNnfvFVWQ3zgVWWG=n62S_XzNQ@mail.gmail.com>
  1 sibling, 1 reply; 6+ messages in thread
From: Marian Csontos @ 2013-02-07 13:02 UTC (permalink / raw)
  To: LVM general discussion and development; +Cc: fakhreddine HABIB

On 02/06/2013 06:10 PM, fakhreddine HABIB wrote:
> Hi,
>
>     I nead please your help to create a physical partition from a logical
> partition.
>
>     I present my problem : I have the configuration (attached pic) of the
> partitions.
>
>     I use the centos system. The problem that my group volume "vg_rega" use
> the whole of the physical disk. I want to install Ubuntu system with centos
> (dual boot), but i need a physical partition to do that. How can'i convert
> the " Unused Space " logical partition to physical partition to install
> Ubuntu.

1st: backup your data! Though operations should be safe, there is always 
human factor and other risks.

Before creating a new partition you will need to resize (shrink) the PV:

     pvresize --pvresize --setphysicalvolumesize DESIRED_PV_SIZE /dev/sda2

pvresize should be safe: it will only shrink PV when there is free space 
at the end, but does not relocate LVs if the free space is in the 
middle. In that case you will need to move the extents first:

     pvmove --alloc anywhere /dev/sda2:OLDSTART-OLDEND /dev/sda2

This may not work correctly and allocate data in the region being moved 
from (which needs to verify with latest version and report)

Then you should be able to shrink the sda2 partition, using parted or 
fdisk. This may be the riskiest part.

However, Ubuntu is able to use Logical Volumes, so you should not need 
to add more physical partitions: for me "dualboot" of 2 linux systems 
with single /boot partition worked mostly fine - except when one is 
using old grub (CentOS) and another grub2 (ubuntu), but even that is not 
impossible...

-- Marian

>
>    Thank you.
>
> F.H
>
>
>
>
> _______________________________________________
> 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] 6+ messages in thread

* [linux-lvm] create physical partition from logical partition
       [not found]         ` <51180903.4020108@redhat.com>
@ 2013-02-14 13:18           ` Marian Csontos
  2013-02-14 13:19             ` Marian Csontos
  0 siblings, 1 reply; 6+ messages in thread
From: Marian Csontos @ 2013-02-14 13:18 UTC (permalink / raw)
  To: lvm-devel

Hello, I did answer here and it still applies.

Though I am sure I have not got you an ill advice, please, *use reply to 
list* or reply to all, so other can review, fix typos/mistakes in steps, 
or provide an additional information.

 > [root at zaphod ~]# lvcreate -L 1G -n lv vg_zaphod
 >   Logical volume "lv" created
 > [root at zaphod ~]# lvresize -L 2G vg_zaphod/lv
 >   Extending logical volume lv to 2.00 GiB
 >   Logical volume lv successfully resized
 > [root at zaphod ~]# lvresize -L 1G vg_zaphod/lv
 >   WARNING: Reducing active logical volume to 1.00 GiB
 >   THIS MAY DESTROY YOUR DATA (filesystem etc.)
 > Do you really want to reduce lv? [y/n]: n

Briefly, answered "y" here lvresize does what asked for and cuts 
filesystem into two. Though it says it will destroy data it was still 
reversible operation, resizing incomplete FS later not so, but running 
fsck dealt an ultimate blow to the FS.

 > Now, the important question: Have you done a backup before?

I hope not getting an answer does not mean no.

-- Marian


On 02/10/2013 09:54 PM, Marian Csontos wrote:
> On 02/10/2013 12:23 AM, fakhreddine HABIB wrote:
>> Thank you again Marian.
>>
>> I tried first with the second point to run `fdisk /dev/sda` and i change
>> the `Id` of /dev/sda2 to `8e`, using the Live Cd of Ubuntu.
>> Now i can see the VG group ' vg_regalcauchy, thank you a lot for this
>> point.
>>
>> Now, i have a problem .. i don't know what the reason. I tried after to
>> reduce my volume in ' dev/vg_regalcaucy/lv_home' to have a big space to
>> install Ubuntu, when i reduce the volume, i had a problem with the
>> filesystem size was 26214400 blocks and the physical size of the
>> device is
>> 24962048.
>> When i use the resize2fs it didn't work, i fix the file system size
>> manually to 24962048.
>
> Hello. Oh no! I am afraid this is the most common mistake I have seen:
> people do first shrink the LV and then the FS, while it must be done in
> reverse order. The wrong way just removes part of FS first, so there may
> be uncomplete files. And any attempt to fix the FS makes it worse -
> links to data in the removed part of FS are broken now.
>
> NOTE: There is a `fsadm` command which does handle resizing of both LVs
> and FSs which should be used instead.
>
> Now, the important question: Have you done a backup before?
>
> *Yes*: Very well! Just restore the data from Backup and repeat just
> shrink the FS first and everything should be fine.
>
> *No*: I am afraid there are going to be files lost, depends very much
> how full the filesystem was.
>
> If possible do a backup now - you may need to return to it and retry...
>
> Then you should increase the size of the LV back and then increase the
> FS size back to original value.
>
> Try running fsck now, but be prepared for lot of errors.
>
> You should check files in lost+found and if any valuable data are there:
> fragments of your files,...
>
> -- Marian
>
>> but when i want to mount the ' dev/vg_regalcaucy/lv_home', i have the
>> message :
>>
>> mount: wrong fs type, bad option, bad superblock on
>> /dev/vg_regalcaucy/lv_home,
>> missing codepage or helper program, or other error
>> In some cases useful info is found in syslog - try
>> dmesg | tail or so
>>
>>
>> And when i try to reboot my Centos system i have the message in the
>> snapshot
>>
>> http://cjoint.com/data/0Bkatrr9BNg.htm
>>
>> Can you help me please to find a solution, i use the partition magic Live
>> CD to use the shell, because i can't have an access to the system...
>> and i
>> don't know how can'i install in the system the ' nfs-common ' if it need.
>>
>> Thank you.
>>
>> F. H
>>
>>
>>
>>
>>
>>
>>
>>
>> 2013/2/8 Marian Csontos <mcsontos@redhat.com>
>>
>>> On 02/08/2013 04:38 AM, fakhreddine HABIB wrote:
>>>
>>>> First thank you Marian.
>>>>
>>>
>>> Hello,
>>>
>>>
>>>
>>>> About the method to reuduce the Pv, i think is risked... I don't
>>>> want to
>>>> take any risk of loosing data ...
>>>>
>>>
>>> - pvresize will not resize if there are data in the trailing disk
>>> space to
>>> about to be shrinked
>>>
>>> - pvmove will mirror the data until moved successfully and even on
>>> failure
>>> will start again
>>>
>>> There is a short interval when LVM metadata are updated where system
>>> crash
>>> could result in troubles, but this is no more risk than increasing
>>> logical
>>> volume size...
>>>
>>> If you need creating new partition, you have no other option than
>>> resizing
>>> the PV.
>>>
>>> *Backups, backups, backups!*
>>>
>>> Though I am quite confident LVM user now, I am always doing backups when
>>> shuffling round partitions.
>>>
>>> Perhaps the easiest way if you have a spare USB HDD around is to run a
>>> live CD and `dd` the /dev/sda there (like this `dd if=/dev/sda
>>> of=/path/to/file/on/your/usb/**disk.img bs=1M`) If anything goes wrong,
>>> you can simply switch the if and of params, and everything will be back
>>> where it was before.
>>>
>>> *Virtualization?*
>>>
>>> Actually, there is an option: if your machine is HVM (Virtualization
>>> enabled) you could still install and run Ubuntu in a virtual machine.
>>>
>>> CONS: slower, more memory consuming (2 OS are running at the same time),
>>> not all HW is accessible...
>>>
>>>
>>>
>>>> I tried your idea if i can install ubuntu and Centos in the same
>>>> Physical
>>>> partition, using a logical one .. but i can,t find the way to do that..
>>>> Ubuntu installation interface give the whole /dev/sda2 but i can't see
>>>> the logical volumes (I talk about logical volumes of a LV group)
>>>> (attached
>>>> pics)
>>>>
>>>
>>> Too bad. Looks like the installer does not recognize LVM partition.
>>>
>>> Is it possible the partition used does not have a partition header?
>>>
>>> Run `fdisk /dev/sda` and there you could try `p` to print partitions.
>>> `Id`
>>> should be `8e` and `System` Linux LVM. If that's not so, try `t` and
>>> change
>>> 2-nd partition's type to `8e`.
>>>
>>> That may help ubuntu recognize the LVM partition.
>>>
>>> If not, try asking on Ubuntu forum...
>>>
>>> -- Marian
>>>
>>>
>>>> thank you.
>>>>
>>>>
>>
>



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

* [linux-lvm] create physical partition from logical partition
  2013-02-14 13:18           ` Marian Csontos
@ 2013-02-14 13:19             ` Marian Csontos
  2013-02-14 13:19               ` [linux-lvm] Fwd: Re: [lvm-devel] " Marian Csontos
  0 siblings, 1 reply; 6+ messages in thread
From: Marian Csontos @ 2013-02-14 13:19 UTC (permalink / raw)
  To: lvm-devel

:-( wrong list! Sorry.

On 02/14/2013 02:18 PM, Marian Csontos wrote:
> Hello, I did answer here and it still applies.
>
> Though I am sure I have not got you an ill advice, please, *use reply to
> list* or reply to all, so other can review, fix typos/mistakes in steps,
> or provide an additional information.
>
>  > [root at zaphod ~]# lvcreate -L 1G -n lv vg_zaphod
>  > Logical volume "lv" created
>  > [root at zaphod ~]# lvresize -L 2G vg_zaphod/lv
>  > Extending logical volume lv to 2.00 GiB
>  > Logical volume lv successfully resized
>  > [root at zaphod ~]# lvresize -L 1G vg_zaphod/lv
>  > WARNING: Reducing active logical volume to 1.00 GiB
>  > THIS MAY DESTROY YOUR DATA (filesystem etc.)
>  > Do you really want to reduce lv? [y/n]: n
>
> Briefly, answered "y" here lvresize does what asked for and cuts
> filesystem into two. Though it says it will destroy data it was still
> reversible operation, resizing incomplete FS later not so, but running
> fsck dealt an ultimate blow to the FS.
>
>  > Now, the important question: Have you done a backup before?
>
> I hope not getting an answer does not mean no.
>
> -- Marian
>
>
> On 02/10/2013 09:54 PM, Marian Csontos wrote:
>> On 02/10/2013 12:23 AM, fakhreddine HABIB wrote:
>>> Thank you again Marian.
>>>
>>> I tried first with the second point to run `fdisk /dev/sda` and i change
>>> the `Id` of /dev/sda2 to `8e`, using the Live Cd of Ubuntu.
>>> Now i can see the VG group ' vg_regalcauchy, thank you a lot for this
>>> point.
>>>
>>> Now, i have a problem .. i don't know what the reason. I tried after to
>>> reduce my volume in ' dev/vg_regalcaucy/lv_home' to have a big space to
>>> install Ubuntu, when i reduce the volume, i had a problem with the
>>> filesystem size was 26214400 blocks and the physical size of the
>>> device is
>>> 24962048.
>>> When i use the resize2fs it didn't work, i fix the file system size
>>> manually to 24962048.
>>
>> Hello. Oh no! I am afraid this is the most common mistake I have seen:
>> people do first shrink the LV and then the FS, while it must be done in
>> reverse order. The wrong way just removes part of FS first, so there may
>> be uncomplete files. And any attempt to fix the FS makes it worse -
>> links to data in the removed part of FS are broken now.
>>
>> NOTE: There is a `fsadm` command which does handle resizing of both LVs
>> and FSs which should be used instead.
>>
>> Now, the important question: Have you done a backup before?
>>
>> *Yes*: Very well! Just restore the data from Backup and repeat just
>> shrink the FS first and everything should be fine.
>>
>> *No*: I am afraid there are going to be files lost, depends very much
>> how full the filesystem was.
>>
>> If possible do a backup now - you may need to return to it and retry...
>>
>> Then you should increase the size of the LV back and then increase the
>> FS size back to original value.
>>
>> Try running fsck now, but be prepared for lot of errors.
>>
>> You should check files in lost+found and if any valuable data are there:
>> fragments of your files,...
>>
>> -- Marian
>>
>>> but when i want to mount the ' dev/vg_regalcaucy/lv_home', i have the
>>> message :
>>>
>>> mount: wrong fs type, bad option, bad superblock on
>>> /dev/vg_regalcaucy/lv_home,
>>> missing codepage or helper program, or other error
>>> In some cases useful info is found in syslog - try
>>> dmesg | tail or so
>>>
>>>
>>> And when i try to reboot my Centos system i have the message in the
>>> snapshot
>>>
>>> http://cjoint.com/data/0Bkatrr9BNg.htm
>>>
>>> Can you help me please to find a solution, i use the partition magic
>>> Live
>>> CD to use the shell, because i can't have an access to the system...
>>> and i
>>> don't know how can'i install in the system the ' nfs-common ' if it
>>> need.
>>>
>>> Thank you.
>>>
>>> F. H
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>> 2013/2/8 Marian Csontos <mcsontos@redhat.com>
>>>
>>>> On 02/08/2013 04:38 AM, fakhreddine HABIB wrote:
>>>>
>>>>> First thank you Marian.
>>>>>
>>>>
>>>> Hello,
>>>>
>>>>
>>>>
>>>>> About the method to reuduce the Pv, i think is risked... I don't
>>>>> want to
>>>>> take any risk of loosing data ...
>>>>>
>>>>
>>>> - pvresize will not resize if there are data in the trailing disk
>>>> space to
>>>> about to be shrinked
>>>>
>>>> - pvmove will mirror the data until moved successfully and even on
>>>> failure
>>>> will start again
>>>>
>>>> There is a short interval when LVM metadata are updated where system
>>>> crash
>>>> could result in troubles, but this is no more risk than increasing
>>>> logical
>>>> volume size...
>>>>
>>>> If you need creating new partition, you have no other option than
>>>> resizing
>>>> the PV.
>>>>
>>>> *Backups, backups, backups!*
>>>>
>>>> Though I am quite confident LVM user now, I am always doing backups
>>>> when
>>>> shuffling round partitions.
>>>>
>>>> Perhaps the easiest way if you have a spare USB HDD around is to run a
>>>> live CD and `dd` the /dev/sda there (like this `dd if=/dev/sda
>>>> of=/path/to/file/on/your/usb/**disk.img bs=1M`) If anything goes wrong,
>>>> you can simply switch the if and of params, and everything will be back
>>>> where it was before.
>>>>
>>>> *Virtualization?*
>>>>
>>>> Actually, there is an option: if your machine is HVM (Virtualization
>>>> enabled) you could still install and run Ubuntu in a virtual machine.
>>>>
>>>> CONS: slower, more memory consuming (2 OS are running at the same
>>>> time),
>>>> not all HW is accessible...
>>>>
>>>>
>>>>
>>>>> I tried your idea if i can install ubuntu and Centos in the same
>>>>> Physical
>>>>> partition, using a logical one .. but i can,t find the way to do
>>>>> that..
>>>>> Ubuntu installation interface give the whole /dev/sda2 but i can't see
>>>>> the logical volumes (I talk about logical volumes of a LV group)
>>>>> (attached
>>>>> pics)
>>>>>
>>>>
>>>> Too bad. Looks like the installer does not recognize LVM partition.
>>>>
>>>> Is it possible the partition used does not have a partition header?
>>>>
>>>> Run `fdisk /dev/sda` and there you could try `p` to print partitions.
>>>> `Id`
>>>> should be `8e` and `System` Linux LVM. If that's not so, try `t` and
>>>> change
>>>> 2-nd partition's type to `8e`.
>>>>
>>>> That may help ubuntu recognize the LVM partition.
>>>>
>>>> If not, try asking on Ubuntu forum...
>>>>
>>>> -- Marian
>>>>
>>>>
>>>>> thank you.
>>>>>
>>>>>
>>>
>>
>
> --
> lvm-devel mailing list
> lvm-devel at redhat.com
> https://www.redhat.com/mailman/listinfo/lvm-devel



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

* [linux-lvm] Fwd: Re: [lvm-devel] create physical partition from logical partition
  2013-02-14 13:19             ` Marian Csontos
@ 2013-02-14 13:19               ` Marian Csontos
  0 siblings, 0 replies; 6+ messages in thread
From: Marian Csontos @ 2013-02-14 13:19 UTC (permalink / raw)
  To: LVM general discussion and development, fakhreddine HABIB

This list! I am sorry.

On 02/14/2013 02:18 PM, Marian Csontos wrote:
> Hello, I did answer here and it still applies.
>
> Though I am sure I have not got you an ill advice, please, *use reply to
> list* or reply to all, so other can review, fix typos/mistakes in steps,
> or provide an additional information.
>
>  > [root@zaphod ~]# lvcreate -L 1G -n lv vg_zaphod
>  > Logical volume "lv" created
>  > [root@zaphod ~]# lvresize -L 2G vg_zaphod/lv
>  > Extending logical volume lv to 2.00 GiB
>  > Logical volume lv successfully resized
>  > [root@zaphod ~]# lvresize -L 1G vg_zaphod/lv
>  > WARNING: Reducing active logical volume to 1.00 GiB
>  > THIS MAY DESTROY YOUR DATA (filesystem etc.)
>  > Do you really want to reduce lv? [y/n]: n
>
> Briefly, answered "y" here lvresize does what asked for and cuts
> filesystem into two. Though it says it will destroy data it was still
> reversible operation, resizing incomplete FS later not so, but running
> fsck dealt an ultimate blow to the FS.
>
>  > Now, the important question: Have you done a backup before?
>
> I hope not getting an answer does not mean no.
>
> -- Marian
>
>
> On 02/10/2013 09:54 PM, Marian Csontos wrote:
>> On 02/10/2013 12:23 AM, fakhreddine HABIB wrote:
>>> Thank you again Marian.
>>>
>>> I tried first with the second point to run `fdisk /dev/sda` and i change
>>> the `Id` of /dev/sda2 to `8e`, using the Live Cd of Ubuntu.
>>> Now i can see the VG group ' vg_regalcauchy, thank you a lot for this
>>> point.
>>>
>>> Now, i have a problem .. i don't know what the reason. I tried after to
>>> reduce my volume in ' dev/vg_regalcaucy/lv_home' to have a big space to
>>> install Ubuntu, when i reduce the volume, i had a problem with the
>>> filesystem size was 26214400 blocks and the physical size of the
>>> device is
>>> 24962048.
>>> When i use the resize2fs it didn't work, i fix the file system size
>>> manually to 24962048.
>>
>> Hello. Oh no! I am afraid this is the most common mistake I have seen:
>> people do first shrink the LV and then the FS, while it must be done in
>> reverse order. The wrong way just removes part of FS first, so there may
>> be uncomplete files. And any attempt to fix the FS makes it worse -
>> links to data in the removed part of FS are broken now.
>>
>> NOTE: There is a `fsadm` command which does handle resizing of both LVs
>> and FSs which should be used instead.
>>
>> Now, the important question: Have you done a backup before?
>>
>> *Yes*: Very well! Just restore the data from Backup and repeat just
>> shrink the FS first and everything should be fine.
>>
>> *No*: I am afraid there are going to be files lost, depends very much
>> how full the filesystem was.
>>
>> If possible do a backup now - you may need to return to it and retry...
>>
>> Then you should increase the size of the LV back and then increase the
>> FS size back to original value.
>>
>> Try running fsck now, but be prepared for lot of errors.
>>
>> You should check files in lost+found and if any valuable data are there:
>> fragments of your files,...
>>
>> -- Marian
>>
>>> but when i want to mount the ' dev/vg_regalcaucy/lv_home', i have the
>>> message :
>>>
>>> mount: wrong fs type, bad option, bad superblock on
>>> /dev/vg_regalcaucy/lv_home,
>>> missing codepage or helper program, or other error
>>> In some cases useful info is found in syslog - try
>>> dmesg | tail or so
>>>
>>>
>>> And when i try to reboot my Centos system i have the message in the
>>> snapshot
>>>
>>> http://cjoint.com/data/0Bkatrr9BNg.htm
>>>
>>> Can you help me please to find a solution, i use the partition magic
>>> Live
>>> CD to use the shell, because i can't have an access to the system...
>>> and i
>>> don't know how can'i install in the system the ' nfs-common ' if it
>>> need.
>>>
>>> Thank you.
>>>
>>> F. H
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>> 2013/2/8 Marian Csontos <mcsontos@redhat.com>
>>>
>>>> On 02/08/2013 04:38 AM, fakhreddine HABIB wrote:
>>>>
>>>>> First thank you Marian.
>>>>>
>>>>
>>>> Hello,
>>>>
>>>>
>>>>
>>>>> About the method to reuduce the Pv, i think is risked... I don't
>>>>> want to
>>>>> take any risk of loosing data ...
>>>>>
>>>>
>>>> - pvresize will not resize if there are data in the trailing disk
>>>> space to
>>>> about to be shrinked
>>>>
>>>> - pvmove will mirror the data until moved successfully and even on
>>>> failure
>>>> will start again
>>>>
>>>> There is a short interval when LVM metadata are updated where system
>>>> crash
>>>> could result in troubles, but this is no more risk than increasing
>>>> logical
>>>> volume size...
>>>>
>>>> If you need creating new partition, you have no other option than
>>>> resizing
>>>> the PV.
>>>>
>>>> *Backups, backups, backups!*
>>>>
>>>> Though I am quite confident LVM user now, I am always doing backups
>>>> when
>>>> shuffling round partitions.
>>>>
>>>> Perhaps the easiest way if you have a spare USB HDD around is to run a
>>>> live CD and `dd` the /dev/sda there (like this `dd if=/dev/sda
>>>> of=/path/to/file/on/your/usb/**disk.img bs=1M`) If anything goes wrong,
>>>> you can simply switch the if and of params, and everything will be back
>>>> where it was before.
>>>>
>>>> *Virtualization?*
>>>>
>>>> Actually, there is an option: if your machine is HVM (Virtualization
>>>> enabled) you could still install and run Ubuntu in a virtual machine.
>>>>
>>>> CONS: slower, more memory consuming (2 OS are running at the same
>>>> time),
>>>> not all HW is accessible...
>>>>
>>>>
>>>>
>>>>> I tried your idea if i can install ubuntu and Centos in the same
>>>>> Physical
>>>>> partition, using a logical one .. but i can,t find the way to do
>>>>> that..
>>>>> Ubuntu installation interface give the whole /dev/sda2 but i can't see
>>>>> the logical volumes (I talk about logical volumes of a LV group)
>>>>> (attached
>>>>> pics)
>>>>>
>>>>
>>>> Too bad. Looks like the installer does not recognize LVM partition.
>>>>
>>>> Is it possible the partition used does not have a partition header?
>>>>
>>>> Run `fdisk /dev/sda` and there you could try `p` to print partitions.
>>>> `Id`
>>>> should be `8e` and `System` Linux LVM. If that's not so, try `t` and
>>>> change
>>>> 2-nd partition's type to `8e`.
>>>>
>>>> That may help ubuntu recognize the LVM partition.
>>>>
>>>> If not, try asking on Ubuntu forum...
>>>>
>>>> -- Marian
>>>>
>>>>
>>>>> thank you.
>>>>>
>>>>>
>>>
>>
>
> --
> lvm-devel mailing list
> lvm-devel@redhat.com
> https://www.redhat.com/mailman/listinfo/lvm-devel

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

end of thread, other threads:[~2013-02-14 13:19 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-06 17:10 [linux-lvm] create physical partition from logical partition fakhreddine HABIB
2013-02-07 11:01 ` [linux-lvm] Re : " georges.giralt
2013-02-07 13:02 ` [linux-lvm] " Marian Csontos
     [not found]   ` <CAMugGiHnARz60km5=0WjHw4UrNnfvFVWQ3zgVWWG=n62S_XzNQ@mail.gmail.com>
     [not found]     ` <5114BA25.2000108@redhat.com>
     [not found]       ` <CAMugGiGTdn9SMjoaP2=AmPZ-QQuREVC89cziN4bM0eya5HjEDQ@mail.gmail.com>
     [not found]         ` <51180903.4020108@redhat.com>
2013-02-14 13:18           ` Marian Csontos
2013-02-14 13:19             ` Marian Csontos
2013-02-14 13:19               ` [linux-lvm] Fwd: Re: [lvm-devel] " Marian Csontos

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.