Physical and logical extents sizeDoes swap need to be on a contiguous LVM logical volumeHow to correct fs...

How do proponents of Sola Scriptura address the ministry of those Apostles who authored no parts of Scripture?

Are there any elected officials in the U.S. who are not legislators, judges, or constitutional officers?

Why did Khan ask Admiral James T. Kirk about Project Genesis?

If the Shillelagh cantrip is applied to a club with non-standard damage dice, what is the resulting damage dice?

How to gently end involvement with an online community?

Add 2 new columns to existing dataframe using apply

How do we tell which part of kinetic energy gives rise to temperature?

"Opusculum hoc, quamdiu vixero, doctioribus emendandum offero."?

Joining lists with same elements

Can you cast bonus action and reaction spells while already casting a spell?

What are the occurences of total war in the Native Americans?

Why are non-collision-resistant hash functions considered insecure for signing self-generated information

Where can/should I, as a high schooler, publish a paper regarding the derivation of a formula?

How does the OS tell whether an "Address is already in use"?

Why is there a difference between predicting on Validation set and Test set?

When calculating a force, why do I get different result when I try to calculate via torque vs via sum of forces at an axis?

To get so rich that you are not in need of anymore money

Round towards zero

What is the difference between "Grippe" and "Männergrippe"?

How much does Commander Data weigh?

How many birds in the bush?

Is first Ubuntu user root?

Talk interpreter

How is linear momentum conserved in case of a freely falling body?



Physical and logical extents size


Does swap need to be on a contiguous LVM logical volumeHow to correct fs size for logical volumeWhat is the proper way to shrink a LVM partition?Why are there two different values for the size of a drive and how to reconcile them with device-mapper and LVM?Move logical volume to a new physical diskHow to resize logical volume in Red Hat LinuxMove all data in LV to first PV, remove othersHow to shrink a physical volume?LVM Shrink to remove a deviceSetting up RAID1 with an active physical volume (Debian 9 stretch)






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ margin-bottom:0;
}







3















I have created a partition with 36TB (/dev/sdb1) in rhel 6.6.
Now I want use this for LVM.




  • What is recommended size for Physical Extents, Volume Extents and Logical Extents?

  • How important PE, VE and LE size to define while creating?


I want to create LV size of 10TB, 10TB, 6TB.
I am using for file sharing through NFS and samba. Performance should be good. Please guide me for this...










share|improve this question



























  • The answers to your questions are available in plenty of the docs available. Did you try googling?

    – Sree
    May 15 '15 at 4:19


















3















I have created a partition with 36TB (/dev/sdb1) in rhel 6.6.
Now I want use this for LVM.




  • What is recommended size for Physical Extents, Volume Extents and Logical Extents?

  • How important PE, VE and LE size to define while creating?


I want to create LV size of 10TB, 10TB, 6TB.
I am using for file sharing through NFS and samba. Performance should be good. Please guide me for this...










share|improve this question



























  • The answers to your questions are available in plenty of the docs available. Did you try googling?

    – Sree
    May 15 '15 at 4:19














3












3








3


1






I have created a partition with 36TB (/dev/sdb1) in rhel 6.6.
Now I want use this for LVM.




  • What is recommended size for Physical Extents, Volume Extents and Logical Extents?

  • How important PE, VE and LE size to define while creating?


I want to create LV size of 10TB, 10TB, 6TB.
I am using for file sharing through NFS and samba. Performance should be good. Please guide me for this...










share|improve this question
















I have created a partition with 36TB (/dev/sdb1) in rhel 6.6.
Now I want use this for LVM.




  • What is recommended size for Physical Extents, Volume Extents and Logical Extents?

  • How important PE, VE and LE size to define while creating?


I want to create LV size of 10TB, 10TB, 6TB.
I am using for file sharing through NFS and samba. Performance should be good. Please guide me for this...







linux performance lvm






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited 8 hours ago









Alexey Vazhnov

196 bronze badges




196 bronze badges










asked May 15 '15 at 4:05









sagarsagar

691 gold badge1 silver badge5 bronze badges




691 gold badge1 silver badge5 bronze badges
















  • The answers to your questions are available in plenty of the docs available. Did you try googling?

    – Sree
    May 15 '15 at 4:19



















  • The answers to your questions are available in plenty of the docs available. Did you try googling?

    – Sree
    May 15 '15 at 4:19

















The answers to your questions are available in plenty of the docs available. Did you try googling?

– Sree
May 15 '15 at 4:19





The answers to your questions are available in plenty of the docs available. Did you try googling?

– Sree
May 15 '15 at 4:19










1 Answer
1






active

oldest

votes


















6















First off, you're confused about what some of those are. You can set the physical extent size with a fair bit of flexibility (vgcreate -s <size-of-PE>). But it doesn't matter, you should just go with the default. To quote the manpage:




The default is 4 MiB.… [H]aving a large number of extents will slow down the tools but have no impact on I/O performance to the logical volume.




When they say "no impact on I/O performance", they mean that literally. LVM is a wrapper around device-mapper and the LVM tools do not expose the physical extent size to device-mapper. The actual kernel code doing the I/O is unaware of the extent size. So it doesn't matter, unless you need to run lvcreate (etc.) all the time as part of your workload.



(Note it can influence data alignment; see below.)



The size in logical extents (set with lvcreate -l «number-of-extents») is just a way to specify the size of the logical volume. LV size = physical extent size * number of extents. Generally though you'd use -L «size» because that does the math for you, and let's you specify human-friendly sizes like 10T



I'm not sure what you mean by "volume extents", unless you mean the same as the above. Or maybe you mean the length of a physical volume in extents, but that'd also just be another way to specify the size.



What you should care about



At 36TB, your sdb is very unlikely to be a plain old disk. You should find out its alignment requirements and make sure you get everything aligned correctly. This is easiest if data_alignment_offset_detection (see man 5 lvm.conf) works in your setup—then the LVM tools will handle this all for you. Allocation (of a logical volume) is done in entire physical extent chunks, so you probably want the PE size to be a multiple of your alignment size. But at 4MiB, it probably already is. Misalignment will kill I/O performance, especially of writes.



You should also ensure that you're using an appropriate RAID level for your workload. Consider also battery-backed cache.






share|improve this answer




























  • Hi, We are using Hardware RAID 6 and I am planing to create 9TB x 4 partitions. /dev/sdb1/2/3/4 and create lvm with striping and I also use 64MB PE for better performance. Is this fine ?

    – sagar
    May 15 '15 at 8:26













  • @sagar I'm not sure why you'd slice the disk into multiple pieces inside the kernel (by partitioning) only to put it back together inside the kernel (via LVM). Just do the straightforward thing—one large partition, put a PV on it, slice it with LVM.

    – derobert
    May 15 '15 at 21:27











  • Hi derobert, what is the Max size we can create lv In lvm2 for default PE 4 MB

    – sagar
    May 16 '15 at 22:19











  • @sagar LVM2 metadata is text-based; it doesn't have fixed-width binary numbers. The limits come from the kernel's ability to parse the numbers. On a 64-bit kernel, the limit is in the multiple-exabyte range.

    – derobert
    May 16 '15 at 23:40














Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "106"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f203538%2fphysical-and-logical-extents-size%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









6















First off, you're confused about what some of those are. You can set the physical extent size with a fair bit of flexibility (vgcreate -s <size-of-PE>). But it doesn't matter, you should just go with the default. To quote the manpage:




The default is 4 MiB.… [H]aving a large number of extents will slow down the tools but have no impact on I/O performance to the logical volume.




When they say "no impact on I/O performance", they mean that literally. LVM is a wrapper around device-mapper and the LVM tools do not expose the physical extent size to device-mapper. The actual kernel code doing the I/O is unaware of the extent size. So it doesn't matter, unless you need to run lvcreate (etc.) all the time as part of your workload.



(Note it can influence data alignment; see below.)



The size in logical extents (set with lvcreate -l «number-of-extents») is just a way to specify the size of the logical volume. LV size = physical extent size * number of extents. Generally though you'd use -L «size» because that does the math for you, and let's you specify human-friendly sizes like 10T



I'm not sure what you mean by "volume extents", unless you mean the same as the above. Or maybe you mean the length of a physical volume in extents, but that'd also just be another way to specify the size.



What you should care about



At 36TB, your sdb is very unlikely to be a plain old disk. You should find out its alignment requirements and make sure you get everything aligned correctly. This is easiest if data_alignment_offset_detection (see man 5 lvm.conf) works in your setup—then the LVM tools will handle this all for you. Allocation (of a logical volume) is done in entire physical extent chunks, so you probably want the PE size to be a multiple of your alignment size. But at 4MiB, it probably already is. Misalignment will kill I/O performance, especially of writes.



You should also ensure that you're using an appropriate RAID level for your workload. Consider also battery-backed cache.






share|improve this answer




























  • Hi, We are using Hardware RAID 6 and I am planing to create 9TB x 4 partitions. /dev/sdb1/2/3/4 and create lvm with striping and I also use 64MB PE for better performance. Is this fine ?

    – sagar
    May 15 '15 at 8:26













  • @sagar I'm not sure why you'd slice the disk into multiple pieces inside the kernel (by partitioning) only to put it back together inside the kernel (via LVM). Just do the straightforward thing—one large partition, put a PV on it, slice it with LVM.

    – derobert
    May 15 '15 at 21:27











  • Hi derobert, what is the Max size we can create lv In lvm2 for default PE 4 MB

    – sagar
    May 16 '15 at 22:19











  • @sagar LVM2 metadata is text-based; it doesn't have fixed-width binary numbers. The limits come from the kernel's ability to parse the numbers. On a 64-bit kernel, the limit is in the multiple-exabyte range.

    – derobert
    May 16 '15 at 23:40
















6















First off, you're confused about what some of those are. You can set the physical extent size with a fair bit of flexibility (vgcreate -s <size-of-PE>). But it doesn't matter, you should just go with the default. To quote the manpage:




The default is 4 MiB.… [H]aving a large number of extents will slow down the tools but have no impact on I/O performance to the logical volume.




When they say "no impact on I/O performance", they mean that literally. LVM is a wrapper around device-mapper and the LVM tools do not expose the physical extent size to device-mapper. The actual kernel code doing the I/O is unaware of the extent size. So it doesn't matter, unless you need to run lvcreate (etc.) all the time as part of your workload.



(Note it can influence data alignment; see below.)



The size in logical extents (set with lvcreate -l «number-of-extents») is just a way to specify the size of the logical volume. LV size = physical extent size * number of extents. Generally though you'd use -L «size» because that does the math for you, and let's you specify human-friendly sizes like 10T



I'm not sure what you mean by "volume extents", unless you mean the same as the above. Or maybe you mean the length of a physical volume in extents, but that'd also just be another way to specify the size.



What you should care about



At 36TB, your sdb is very unlikely to be a plain old disk. You should find out its alignment requirements and make sure you get everything aligned correctly. This is easiest if data_alignment_offset_detection (see man 5 lvm.conf) works in your setup—then the LVM tools will handle this all for you. Allocation (of a logical volume) is done in entire physical extent chunks, so you probably want the PE size to be a multiple of your alignment size. But at 4MiB, it probably already is. Misalignment will kill I/O performance, especially of writes.



You should also ensure that you're using an appropriate RAID level for your workload. Consider also battery-backed cache.






share|improve this answer




























  • Hi, We are using Hardware RAID 6 and I am planing to create 9TB x 4 partitions. /dev/sdb1/2/3/4 and create lvm with striping and I also use 64MB PE for better performance. Is this fine ?

    – sagar
    May 15 '15 at 8:26













  • @sagar I'm not sure why you'd slice the disk into multiple pieces inside the kernel (by partitioning) only to put it back together inside the kernel (via LVM). Just do the straightforward thing—one large partition, put a PV on it, slice it with LVM.

    – derobert
    May 15 '15 at 21:27











  • Hi derobert, what is the Max size we can create lv In lvm2 for default PE 4 MB

    – sagar
    May 16 '15 at 22:19











  • @sagar LVM2 metadata is text-based; it doesn't have fixed-width binary numbers. The limits come from the kernel's ability to parse the numbers. On a 64-bit kernel, the limit is in the multiple-exabyte range.

    – derobert
    May 16 '15 at 23:40














6














6










6









First off, you're confused about what some of those are. You can set the physical extent size with a fair bit of flexibility (vgcreate -s <size-of-PE>). But it doesn't matter, you should just go with the default. To quote the manpage:




The default is 4 MiB.… [H]aving a large number of extents will slow down the tools but have no impact on I/O performance to the logical volume.




When they say "no impact on I/O performance", they mean that literally. LVM is a wrapper around device-mapper and the LVM tools do not expose the physical extent size to device-mapper. The actual kernel code doing the I/O is unaware of the extent size. So it doesn't matter, unless you need to run lvcreate (etc.) all the time as part of your workload.



(Note it can influence data alignment; see below.)



The size in logical extents (set with lvcreate -l «number-of-extents») is just a way to specify the size of the logical volume. LV size = physical extent size * number of extents. Generally though you'd use -L «size» because that does the math for you, and let's you specify human-friendly sizes like 10T



I'm not sure what you mean by "volume extents", unless you mean the same as the above. Or maybe you mean the length of a physical volume in extents, but that'd also just be another way to specify the size.



What you should care about



At 36TB, your sdb is very unlikely to be a plain old disk. You should find out its alignment requirements and make sure you get everything aligned correctly. This is easiest if data_alignment_offset_detection (see man 5 lvm.conf) works in your setup—then the LVM tools will handle this all for you. Allocation (of a logical volume) is done in entire physical extent chunks, so you probably want the PE size to be a multiple of your alignment size. But at 4MiB, it probably already is. Misalignment will kill I/O performance, especially of writes.



You should also ensure that you're using an appropriate RAID level for your workload. Consider also battery-backed cache.






share|improve this answer















First off, you're confused about what some of those are. You can set the physical extent size with a fair bit of flexibility (vgcreate -s <size-of-PE>). But it doesn't matter, you should just go with the default. To quote the manpage:




The default is 4 MiB.… [H]aving a large number of extents will slow down the tools but have no impact on I/O performance to the logical volume.




When they say "no impact on I/O performance", they mean that literally. LVM is a wrapper around device-mapper and the LVM tools do not expose the physical extent size to device-mapper. The actual kernel code doing the I/O is unaware of the extent size. So it doesn't matter, unless you need to run lvcreate (etc.) all the time as part of your workload.



(Note it can influence data alignment; see below.)



The size in logical extents (set with lvcreate -l «number-of-extents») is just a way to specify the size of the logical volume. LV size = physical extent size * number of extents. Generally though you'd use -L «size» because that does the math for you, and let's you specify human-friendly sizes like 10T



I'm not sure what you mean by "volume extents", unless you mean the same as the above. Or maybe you mean the length of a physical volume in extents, but that'd also just be another way to specify the size.



What you should care about



At 36TB, your sdb is very unlikely to be a plain old disk. You should find out its alignment requirements and make sure you get everything aligned correctly. This is easiest if data_alignment_offset_detection (see man 5 lvm.conf) works in your setup—then the LVM tools will handle this all for you. Allocation (of a logical volume) is done in entire physical extent chunks, so you probably want the PE size to be a multiple of your alignment size. But at 4MiB, it probably already is. Misalignment will kill I/O performance, especially of writes.



You should also ensure that you're using an appropriate RAID level for your workload. Consider also battery-backed cache.







share|improve this answer














share|improve this answer



share|improve this answer








edited Apr 13 '16 at 13:51









dr01

17.5k11 gold badges56 silver badges79 bronze badges




17.5k11 gold badges56 silver badges79 bronze badges










answered May 15 '15 at 6:00









derobertderobert

79k8 gold badges175 silver badges231 bronze badges




79k8 gold badges175 silver badges231 bronze badges
















  • Hi, We are using Hardware RAID 6 and I am planing to create 9TB x 4 partitions. /dev/sdb1/2/3/4 and create lvm with striping and I also use 64MB PE for better performance. Is this fine ?

    – sagar
    May 15 '15 at 8:26













  • @sagar I'm not sure why you'd slice the disk into multiple pieces inside the kernel (by partitioning) only to put it back together inside the kernel (via LVM). Just do the straightforward thing—one large partition, put a PV on it, slice it with LVM.

    – derobert
    May 15 '15 at 21:27











  • Hi derobert, what is the Max size we can create lv In lvm2 for default PE 4 MB

    – sagar
    May 16 '15 at 22:19











  • @sagar LVM2 metadata is text-based; it doesn't have fixed-width binary numbers. The limits come from the kernel's ability to parse the numbers. On a 64-bit kernel, the limit is in the multiple-exabyte range.

    – derobert
    May 16 '15 at 23:40



















  • Hi, We are using Hardware RAID 6 and I am planing to create 9TB x 4 partitions. /dev/sdb1/2/3/4 and create lvm with striping and I also use 64MB PE for better performance. Is this fine ?

    – sagar
    May 15 '15 at 8:26













  • @sagar I'm not sure why you'd slice the disk into multiple pieces inside the kernel (by partitioning) only to put it back together inside the kernel (via LVM). Just do the straightforward thing—one large partition, put a PV on it, slice it with LVM.

    – derobert
    May 15 '15 at 21:27











  • Hi derobert, what is the Max size we can create lv In lvm2 for default PE 4 MB

    – sagar
    May 16 '15 at 22:19











  • @sagar LVM2 metadata is text-based; it doesn't have fixed-width binary numbers. The limits come from the kernel's ability to parse the numbers. On a 64-bit kernel, the limit is in the multiple-exabyte range.

    – derobert
    May 16 '15 at 23:40

















Hi, We are using Hardware RAID 6 and I am planing to create 9TB x 4 partitions. /dev/sdb1/2/3/4 and create lvm with striping and I also use 64MB PE for better performance. Is this fine ?

– sagar
May 15 '15 at 8:26







Hi, We are using Hardware RAID 6 and I am planing to create 9TB x 4 partitions. /dev/sdb1/2/3/4 and create lvm with striping and I also use 64MB PE for better performance. Is this fine ?

– sagar
May 15 '15 at 8:26















@sagar I'm not sure why you'd slice the disk into multiple pieces inside the kernel (by partitioning) only to put it back together inside the kernel (via LVM). Just do the straightforward thing—one large partition, put a PV on it, slice it with LVM.

– derobert
May 15 '15 at 21:27





@sagar I'm not sure why you'd slice the disk into multiple pieces inside the kernel (by partitioning) only to put it back together inside the kernel (via LVM). Just do the straightforward thing—one large partition, put a PV on it, slice it with LVM.

– derobert
May 15 '15 at 21:27













Hi derobert, what is the Max size we can create lv In lvm2 for default PE 4 MB

– sagar
May 16 '15 at 22:19





Hi derobert, what is the Max size we can create lv In lvm2 for default PE 4 MB

– sagar
May 16 '15 at 22:19













@sagar LVM2 metadata is text-based; it doesn't have fixed-width binary numbers. The limits come from the kernel's ability to parse the numbers. On a 64-bit kernel, the limit is in the multiple-exabyte range.

– derobert
May 16 '15 at 23:40





@sagar LVM2 metadata is text-based; it doesn't have fixed-width binary numbers. The limits come from the kernel's ability to parse the numbers. On a 64-bit kernel, the limit is in the multiple-exabyte range.

– derobert
May 16 '15 at 23:40


















draft saved

draft discarded




















































Thanks for contributing an answer to Unix & Linux Stack Exchange!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f203538%2fphysical-and-logical-extents-size%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Hudson River Historic District Contents Geography History The district today Aesthetics Cultural...

The number designs the writing. Feandra Aversely Definition: The act of ingrafting a sprig or shoot of one...

Ayherre Geografie Demografie Externe links Navigatiemenu43° 23′ NB, 1° 15′ WL43° 23′ NB, 1°...