All of lore.kernel.org
 help / color / mirror / Atom feed
* [linux-lvm] pvs -a on a partition of ZFS block device
@ 2014-06-10 18:44 alessandro macuz
  2014-06-11  7:53 ` Oliver Rath
  0 siblings, 1 reply; 5+ messages in thread
From: alessandro macuz @ 2014-06-10 18:44 UTC (permalink / raw)
  To: LVM general discussion and development

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

Hi all,

the goal is to mount a LVM volume that is contained in a 8e partition of a
zvol device.

Since we speak about a production system I stated from the basic and I
wanted to see if pvs would recognize the partition. No luck.

root@server02:/mnt# pvs -a /dev/zd1168p2
  Failed to read physical volume "/dev/zd1168p2"

but on the other way on the same system I get

root@server02:/mnt# pvs -a /dev/sdb2
  PV         VG         Fmt  Attr PSize   PFree
  /dev/sdb2  vgserver01 lvm2 a-   464.83g 432.82g

The only difference I can see between the 2 is the major number

root@server02:/mnt# ls -la /dev/zd1168p2
brw-rw---- 1 root disk 230, 1170 Jun 10 19:56 /dev/zd1168p2

and

root@server02:/mnt# ls -la /dev/sdb2
brw-rw---- 1 root disk 8, 18 Feb 11 10:43 /dev/sdb2

Is it an expected behaviour that I pvs doesn't recognize "physical device"
within ZFS block devices?

Thanks, Alex

[-- Attachment #2: Type: text/html, Size: 1315 bytes --]

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

* Re: [linux-lvm] pvs -a on a partition of ZFS block device
  2014-06-10 18:44 [linux-lvm] pvs -a on a partition of ZFS block device alessandro macuz
@ 2014-06-11  7:53 ` Oliver Rath
  2014-06-11  8:43   ` alessandro macuz
  0 siblings, 1 reply; 5+ messages in thread
From: Oliver Rath @ 2014-06-11  7:53 UTC (permalink / raw)
  To: linux-lvm

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

Hi Alex,

Im not sure if I understand right: You take a zfv-Volume to create a lvm
volume inside? Make it sense to mix two similar concepts in this way?
Imho zfs and lvm are focussed to different goals, so if you combine it,
you get the worse of both.

What is your goal mixing these concepts? If you have created a
zfs-volume, you can mount it directly without detouring over lvm and
vice versa.

I think it is much better to decide for one of these (zfs-volumes XOR
lvm-Volumes) depending on your needs.

Just my 2ct

Regards
Oliver


Am 10.06.2014 20:44, schrieb alessandro macuz:
> Hi all,
>
> the goal is to mount a LVM volume that is contained in a 8e partition
> of a zvol device.
>
> Since we speak about a production system I stated from the basic and I
> wanted to see if pvs would recognize the partition. No luck.
>
> root@server02:/mnt# pvs -a /dev/zd1168p2
>   Failed to read physical volume "/dev/zd1168p2"
>
> but on the other way on the same system I get 
>
> root@server02:/mnt# pvs -a /dev/sdb2
>   PV         VG         Fmt  Attr PSize   PFree
>   /dev/sdb2  vgserver01 lvm2 a-   464.83g 432.82g
>
> The only difference I can see between the 2 is the major number
>
> root@server02:/mnt# ls -la /dev/zd1168p2
> brw-rw---- 1 root disk 230, 1170 Jun 10 19:56 /dev/zd1168p2
>
> and 
>
> root@server02:/mnt# ls -la /dev/sdb2
> brw-rw---- 1 root disk 8, 18 Feb 11 10:43 /dev/sdb2
>
> Is it an expected behaviour that I pvs doesn't recognize "physical
> device" within ZFS block devices?
>
> Thanks, Alex
>
>
> _______________________________________________
> 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/


[-- Attachment #2: Type: text/html, Size: 3532 bytes --]

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

* Re: [linux-lvm] pvs -a on a partition of ZFS block device
  2014-06-11  7:53 ` Oliver Rath
@ 2014-06-11  8:43   ` alessandro macuz
  2014-06-11  9:33     ` Zdenek Kabelac
  0 siblings, 1 reply; 5+ messages in thread
From: alessandro macuz @ 2014-06-11  8:43 UTC (permalink / raw)
  To: LVM general discussion and development

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

2014-06-11 9:53 GMT+02:00 Oliver Rath <rath@mglug.de>:

>  Hi Alex,
>
> Im not sure if I understand right: You take a zfv-Volume to create a lvm
> volume inside? Make it sense to mix two similar concepts in this way? Imho
> zfs and lvm are focussed to different goals, so if you combine it, you get
> the worse of both.
>
> What is your goal mixing these concepts? If you have created a zfs-volume,
> you can mount it directly without detouring over lvm and vice versa.
>
> I think it is much better to decide for one of these (zfs-volumes XOR
> lvm-Volumes) depending on your needs.
>
> Just my 2ct
>
> Regards
> Oliver
>
>
Hi Oliver,

I see and back your point since the flexibility given by LVM can be
obtained with ZFS as well.
In this case I'm not trying to achieve anything but rather dealing with
something already existing and without making too many changes I'd like to
access that volume. I think my reasoning is correct but somehow I see
something non-expected. I thought I could use pvs, and lvs later on, on any
block device as for any physical disks.

Maybe pvs is coded to work only with some devices on purpose, I haven't
looked at the source. I don't think what I'm doing is wrong in theory and I
would like to know if instead, from the theoretically point of view, it is.

Thanks, Alex

[-- Attachment #2: Type: text/html, Size: 2014 bytes --]

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

* Re: [linux-lvm] pvs -a on a partition of ZFS block device
  2014-06-11  8:43   ` alessandro macuz
@ 2014-06-11  9:33     ` Zdenek Kabelac
  2014-06-11 10:11       ` alessandro macuz
  0 siblings, 1 reply; 5+ messages in thread
From: Zdenek Kabelac @ 2014-06-11  9:33 UTC (permalink / raw)
  To: LVM general discussion and development, alessandro.macuz

Dne 11.6.2014 10:43, alessandro macuz napsal(a):
>
>
> 2014-06-11 9:53 GMT+02:00 Oliver Rath <rath@mglug.de <mailto:rath@mglug.de>>:
>
>     Hi Alex,
>
>     Im not sure if I understand right: You take a zfv-Volume to create a lvm
>     volume inside? Make it sense to mix two similar concepts in this way? Imho
>     zfs and lvm are focussed to different goals, so if you combine it, you get
>     the worse of both.
>
>     What is your goal mixing these concepts? If you have created a zfs-volume,
>     you can mount it directly without detouring over lvm and vice versa.
>
>     I think it is much better to decide for one of these (zfs-volumes XOR
>     lvm-Volumes) depending on your needs.
>
>     Just my 2ct
>
>     Regards
>     Oliver
>
>
> Hi Oliver,
>
> I see and back your point since the flexibility given by LVM can be obtained
> with ZFS as well.
> In this case I'm not trying to achieve anything but rather dealing with
> something already existing and without making too many changes I'd like to
> access that volume. I think my reasoning is correct but somehow I see
> something non-expected. I thought I could use pvs, and lvs later on, on any
> block device as for any physical disks.
>
> Maybe pvs is coded to work only with some devices on purpose, I haven't looked
> at the source. I don't think what I'm doing is wrong in theory and I would
> like to know if instead, from the theoretically point of view, it is.
>
> Thanks, Alex

Support for  ZFS partitions has been embedded into 2.02.106 lvm2 version.
You may as well add it to older version of lvm2 by updating your lvm.conf

https://bugzilla.redhat.com/show_bug.cgi?id=913597


You can add the following to your /etc/lvm.conf devices section to solve the 
issue:

types = [ "zvol", 16 ]

Zdenek

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

* Re: [linux-lvm] pvs -a on a partition of ZFS block device
  2014-06-11  9:33     ` Zdenek Kabelac
@ 2014-06-11 10:11       ` alessandro macuz
  0 siblings, 0 replies; 5+ messages in thread
From: alessandro macuz @ 2014-06-11 10:11 UTC (permalink / raw)
  To: Zdenek Kabelac; +Cc: LVM general discussion and development

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

2014-06-11 11:33 GMT+02:00 Zdenek Kabelac <zkabelac@redhat.com>:

> Dne 11.6.2014 10:43, alessandro macuz napsal(a):
>
>>
>>
>> 2014-06-11 9:53 GMT+02:00 Oliver Rath <rath@mglug.de <mailto:
>> rath@mglug.de>>:
>>
>>
>>     Hi Alex,
>>
>>     Im not sure if I understand right: You take a zfv-Volume to create a
>> lvm
>>     volume inside? Make it sense to mix two similar concepts in this way?
>> Imho
>>     zfs and lvm are focussed to different goals, so if you combine it,
>> you get
>>     the worse of both.
>>
>>     What is your goal mixing these concepts? If you have created a
>> zfs-volume,
>>     you can mount it directly without detouring over lvm and vice versa.
>>
>>     I think it is much better to decide for one of these (zfs-volumes XOR
>>     lvm-Volumes) depending on your needs.
>>
>>     Just my 2ct
>>
>>     Regards
>>     Oliver
>>
>>
>> Hi Oliver,
>>
>> I see and back your point since the flexibility given by LVM can be
>> obtained
>> with ZFS as well.
>> In this case I'm not trying to achieve anything but rather dealing with
>> something already existing and without making too many changes I'd like to
>> access that volume. I think my reasoning is correct but somehow I see
>> something non-expected. I thought I could use pvs, and lvs later on, on
>> any
>> block device as for any physical disks.
>>
>> Maybe pvs is coded to work only with some devices on purpose, I haven't
>> looked
>> at the source. I don't think what I'm doing is wrong in theory and I would
>> like to know if instead, from the theoretically point of view, it is.
>>
>> Thanks, Alex
>>
>
> Support for  ZFS partitions has been embedded into 2.02.106 lvm2 version.
> You may as well add it to older version of lvm2 by updating your lvm.conf
>
> https://bugzilla.redhat.com/show_bug.cgi?id=913597
>
>
> You can add the following to your /etc/lvm.conf devices section to solve
> the issue:
>
> types = [ "zvol", 16 ]



Thanks Zdenek,

it works !

Alessandro

[-- Attachment #2: Type: text/html, Size: 2836 bytes --]

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

end of thread, other threads:[~2014-06-11 10:11 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-06-10 18:44 [linux-lvm] pvs -a on a partition of ZFS block device alessandro macuz
2014-06-11  7:53 ` Oliver Rath
2014-06-11  8:43   ` alessandro macuz
2014-06-11  9:33     ` Zdenek Kabelac
2014-06-11 10:11       ` alessandro macuz

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.