From: Stuart D Gathman <stuart@bmsi.com>
To: LVM general discussion and development <linux-lvm@redhat.com>
Subject: Re: [linux-lvm] Question for LVM feasibility and usage on the embedded linux
Date: Fri, 24 Feb 2012 16:58:53 -0500 [thread overview]
Message-ID: <4F48081D.8070901@bmsi.com> (raw)
In-Reply-To: <CALLsPVhgBoZiPU6GR_UAjE31ZFOjyTkUeF03ddt5_+B6YD=16g@mail.gmail.com>
Long ago, Nostradamus foresaw that on 02/23/2012 08:00 PM, 박준모 would
write:
> Actually, i know that LVM solution is very attractive for engineer
> and/or system which have multiple disks.
> But, in my case, i have a only one disk(2TB) and i need to
> expand/shrink the partition dynamically according to the user request
> while file systems are online(without reboot or backup).
LVM expands/shrinks logical volumes (which you use instead of
partitions) while filesystems are online - that is a standard function.
It doesn't matter how many disks you have. Most desktops have just one.
As to whether the *filesystem* can expand or shrink online - that
depends on the filesystem. ext3 and ext4 can expand online, but not
shrink online. In general, it is a lot easier for a filesystem to
support expanding online that shrinking online. However, you can unmount
and shrink a filesystem and its underlying LV without disturbing other
filesystems. (As you would with partitions.)
>
> Requested Feature
> 1) expand/shrink the partition dynamically according to the user request.
> 2) space limitation per each partition or directory.
Not sure what you mean by "space limitation". Each LV has a size, yes.
>
> This is my user scenario.
> 1) Let's say that 500G is for shared folder and another 500G is for
> multimedia folder. And 1TB is a free disk space.
> 2) shared folder can use additional free disk at any time up to 1TB
> freely if free space is available.. But, multimedia folder can't use
> additional space without user permission and it can use only 500G space.
> 3) Let's say shared folder have 1.5TB now. But,if multimedia folder
> want to expand their space with 500G(Total 1TB), system MUST allocate
> additional space to multimedia folder. In this case, shared folder
> should be shrunk to 1TB and multimedia folder should be expanded up to
> 1TB.
> 4) Now, user can't write the data to the each folder over 1TB.
>
>
> 1) Does LVM suitable solution for me?( only 2TB one disk)
Again, the number of disks is not relevant.
Adding space to either filesystem while live is fully supported with
many filesystems, including ext3 and ext4. However, this depends on an
administrator issuing commands to add the space. You can also set up a
script to check free space, and add more when it gets low. Shrinking
requires unmounting with all the filesystems I am familiar with.
> 2) Do you know any case study on embedded system or similar with my
> situation?
It is pretty standard on any system. Even a home desktop will have
several filesystems which are expanded as needed.
> 3) Could you give me any comments or guidance?
It sounds like you need to install a linux distro with LVM on a desktop
or laptop and start using it. Try Fedora - but don't use the default
layout (which uses LVM but allocates all free space to the root
filesystem). Allocate only 10G for the root filesystem. After installing
and updating, allocate, initialize, and mount a /home filesystem of 10G.
While logged in, and using the GUI, expand /home to 20G. That will give
you the basics. Now create /shared and /multimedia filesystems.
prev parent reply other threads:[~2012-02-24 21:58 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-02-24 1:00 [linux-lvm] Question for LVM feasibility and usage on the embedded linux 박준모
2012-02-24 21:58 ` Stuart D Gathman [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4F48081D.8070901@bmsi.com \
--to=stuart@bmsi.com \
--cc=linux-lvm@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).