why do we need to create physical volume and volume group?
I have some doubts while studying about LVM. what is requirement to create physical volume and volume group separately. Means is it not possible to make LV on directly physical volume.
lvm
add a comment |
I have some doubts while studying about LVM. what is requirement to create physical volume and volume group separately. Means is it not possible to make LV on directly physical volume.
lvm
add a comment |
I have some doubts while studying about LVM. what is requirement to create physical volume and volume group separately. Means is it not possible to make LV on directly physical volume.
lvm
I have some doubts while studying about LVM. what is requirement to create physical volume and volume group separately. Means is it not possible to make LV on directly physical volume.
lvm
lvm
edited Jan 23 at 21:17
Rui F Ribeiro
39.8k1479133
39.8k1479133
asked Jul 7 '17 at 13:31
yogs_2019yogs_2019
62
62
add a comment |
add a comment |
2 Answers
2
active
oldest
votes
Creating a Logical Volume directly over a Physical Volume would not give much avantage over a simple partitioning of a disk and would negate one of the most useful features of LVM, that is grouping together several PVs into a single VGs.
For instance, you can group three physical disks of 100 Gb each into a single VG, then create a 300 Gb volume (as a LV) out of it. Or two 150 Gb volumes.
add a comment |
This is how it was done before : you just "slice" a disk into partition, each partition holding a filesystem (aka files and directories).
/dev/sda1 => / from 0 to 12
/dev/sda2 => swap from 13 to 53
/dev/sda3 => /usr from 54 to 114
/dev/sda4 => /var from 115 to 156
free from 157 to end of disk
(number are pseudo block)
Now the problem is when you want to increase, say /usr
, you will overlap /var
. Having free space after, but still needing a cumbersome move to extend /usr
.
Now the whole LVM paradigm have been set up as to allow use of multiple disk, and dynamic growing of logical volume (and filesystem that support it).
Also keep in mind that logical volume are seldom use alone, most of the time a filesystem (ext4
, xfs
, and many other) is put in top of it.
LVM stack (from physical to logical) looks like
- disk (PV: Physical Volume)
- Volume Group (VG) : one or more PV
- Logical Volume (LV) : a part on a LV, can be mirrored if need be, can be dynamically moved from a PV to another (in same VG).
Not part of LVM:
- Below LVM are SAN device, local disk or Virtual disk
- Above LVM are filesystem or swap.
- Some program may use direct access to LV (I don't have example in mind tho).
add a comment |
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
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f375990%2fwhy-do-we-need-to-create-physical-volume-and-volume-group%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
Creating a Logical Volume directly over a Physical Volume would not give much avantage over a simple partitioning of a disk and would negate one of the most useful features of LVM, that is grouping together several PVs into a single VGs.
For instance, you can group three physical disks of 100 Gb each into a single VG, then create a 300 Gb volume (as a LV) out of it. Or two 150 Gb volumes.
add a comment |
Creating a Logical Volume directly over a Physical Volume would not give much avantage over a simple partitioning of a disk and would negate one of the most useful features of LVM, that is grouping together several PVs into a single VGs.
For instance, you can group three physical disks of 100 Gb each into a single VG, then create a 300 Gb volume (as a LV) out of it. Or two 150 Gb volumes.
add a comment |
Creating a Logical Volume directly over a Physical Volume would not give much avantage over a simple partitioning of a disk and would negate one of the most useful features of LVM, that is grouping together several PVs into a single VGs.
For instance, you can group three physical disks of 100 Gb each into a single VG, then create a 300 Gb volume (as a LV) out of it. Or two 150 Gb volumes.
Creating a Logical Volume directly over a Physical Volume would not give much avantage over a simple partitioning of a disk and would negate one of the most useful features of LVM, that is grouping together several PVs into a single VGs.
For instance, you can group three physical disks of 100 Gb each into a single VG, then create a 300 Gb volume (as a LV) out of it. Or two 150 Gb volumes.
answered Jul 7 '17 at 13:37
dr01dr01
16.1k114973
16.1k114973
add a comment |
add a comment |
This is how it was done before : you just "slice" a disk into partition, each partition holding a filesystem (aka files and directories).
/dev/sda1 => / from 0 to 12
/dev/sda2 => swap from 13 to 53
/dev/sda3 => /usr from 54 to 114
/dev/sda4 => /var from 115 to 156
free from 157 to end of disk
(number are pseudo block)
Now the problem is when you want to increase, say /usr
, you will overlap /var
. Having free space after, but still needing a cumbersome move to extend /usr
.
Now the whole LVM paradigm have been set up as to allow use of multiple disk, and dynamic growing of logical volume (and filesystem that support it).
Also keep in mind that logical volume are seldom use alone, most of the time a filesystem (ext4
, xfs
, and many other) is put in top of it.
LVM stack (from physical to logical) looks like
- disk (PV: Physical Volume)
- Volume Group (VG) : one or more PV
- Logical Volume (LV) : a part on a LV, can be mirrored if need be, can be dynamically moved from a PV to another (in same VG).
Not part of LVM:
- Below LVM are SAN device, local disk or Virtual disk
- Above LVM are filesystem or swap.
- Some program may use direct access to LV (I don't have example in mind tho).
add a comment |
This is how it was done before : you just "slice" a disk into partition, each partition holding a filesystem (aka files and directories).
/dev/sda1 => / from 0 to 12
/dev/sda2 => swap from 13 to 53
/dev/sda3 => /usr from 54 to 114
/dev/sda4 => /var from 115 to 156
free from 157 to end of disk
(number are pseudo block)
Now the problem is when you want to increase, say /usr
, you will overlap /var
. Having free space after, but still needing a cumbersome move to extend /usr
.
Now the whole LVM paradigm have been set up as to allow use of multiple disk, and dynamic growing of logical volume (and filesystem that support it).
Also keep in mind that logical volume are seldom use alone, most of the time a filesystem (ext4
, xfs
, and many other) is put in top of it.
LVM stack (from physical to logical) looks like
- disk (PV: Physical Volume)
- Volume Group (VG) : one or more PV
- Logical Volume (LV) : a part on a LV, can be mirrored if need be, can be dynamically moved from a PV to another (in same VG).
Not part of LVM:
- Below LVM are SAN device, local disk or Virtual disk
- Above LVM are filesystem or swap.
- Some program may use direct access to LV (I don't have example in mind tho).
add a comment |
This is how it was done before : you just "slice" a disk into partition, each partition holding a filesystem (aka files and directories).
/dev/sda1 => / from 0 to 12
/dev/sda2 => swap from 13 to 53
/dev/sda3 => /usr from 54 to 114
/dev/sda4 => /var from 115 to 156
free from 157 to end of disk
(number are pseudo block)
Now the problem is when you want to increase, say /usr
, you will overlap /var
. Having free space after, but still needing a cumbersome move to extend /usr
.
Now the whole LVM paradigm have been set up as to allow use of multiple disk, and dynamic growing of logical volume (and filesystem that support it).
Also keep in mind that logical volume are seldom use alone, most of the time a filesystem (ext4
, xfs
, and many other) is put in top of it.
LVM stack (from physical to logical) looks like
- disk (PV: Physical Volume)
- Volume Group (VG) : one or more PV
- Logical Volume (LV) : a part on a LV, can be mirrored if need be, can be dynamically moved from a PV to another (in same VG).
Not part of LVM:
- Below LVM are SAN device, local disk or Virtual disk
- Above LVM are filesystem or swap.
- Some program may use direct access to LV (I don't have example in mind tho).
This is how it was done before : you just "slice" a disk into partition, each partition holding a filesystem (aka files and directories).
/dev/sda1 => / from 0 to 12
/dev/sda2 => swap from 13 to 53
/dev/sda3 => /usr from 54 to 114
/dev/sda4 => /var from 115 to 156
free from 157 to end of disk
(number are pseudo block)
Now the problem is when you want to increase, say /usr
, you will overlap /var
. Having free space after, but still needing a cumbersome move to extend /usr
.
Now the whole LVM paradigm have been set up as to allow use of multiple disk, and dynamic growing of logical volume (and filesystem that support it).
Also keep in mind that logical volume are seldom use alone, most of the time a filesystem (ext4
, xfs
, and many other) is put in top of it.
LVM stack (from physical to logical) looks like
- disk (PV: Physical Volume)
- Volume Group (VG) : one or more PV
- Logical Volume (LV) : a part on a LV, can be mirrored if need be, can be dynamically moved from a PV to another (in same VG).
Not part of LVM:
- Below LVM are SAN device, local disk or Virtual disk
- Above LVM are filesystem or swap.
- Some program may use direct access to LV (I don't have example in mind tho).
answered Jul 7 '17 at 14:06
ArchemarArchemar
20k93772
20k93772
add a comment |
add a comment |
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.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f375990%2fwhy-do-we-need-to-create-physical-volume-and-volume-group%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
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