LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 01-05-2011, 11:45 PM   #1
yoachan
Member
 
Registered: Nov 2009
Posts: 109

Rep: Reputation: 16
LVM Partition


Dear all,

I'm still new with LVM and linux partition, so please bear with me.
I had a legacy machine with partition as shown in this image.

http://i329.photobucket.com/albums/l.../Linux/LVM.png

What I need is just resize /home to 35GB and add 12GB to /var.

My question is:
  1. Is it save for me to change partition just using that "edit" button and filling larger size -- for I still have 17GB free? A friend told that I need to move last partition first, and the next one (and so on) till the partition that I want to move. Really not sure about this. Or should I use another partition tool such as gparted (as mentioned in other thread)? I can't afford any data loss.
  2. When the time come, I want to add another storage to this machine. Is it possible to combine that storage to add more space to my current home and var? And if it is, how can I do it?

Can anyone please give me an explanation?

any help appreciated.

regards,

Yoachan
 
Old 01-05-2011, 11:57 PM   #2
silvyus_06
Member
 
Registered: Oct 2010
Distribution: Ubuntu 10.04 , Linux Mint Debian Edition , Microsoft Windows 7
Posts: 390

Rep: Reputation: 50
1 . yes , you need to have the free space aftee the partition you want to grow . say , move the partitions as wanted until the free space comes after your desired partition .
example : /dev/sda3 is you desired partition ... and after dev/sda3 you need to have unallocated space.

2 . i am also new to this whole lvm thing . i am searching on it .
ok.found that . i'm citing from here(which also has lots of other useful infos ) .

Quote:
Before we can extend an existing volume group we need to create a physical volume:


# pvcreate /dev/sda1 (modify with YOUR partition )
Physical volume "/dev/sda1" successfully created


And now we extend the VG:


# vgextend maingroup /dev/sda1 (again , modify with YOUR paritition)
Volume group "maingroup" successfully extended
edit :
excuse me , but now that i see what you have , you can grow it easily , you do not haave to move partitions around

Last edited by silvyus_06; 01-06-2011 at 12:00 AM.
 
1 members found this post helpful.
Old 01-06-2011, 12:02 AM   #3
djtoltz
Member
 
Registered: Nov 2003
Location: Eastern North Carolina, USA
Distribution: Mandrake
Posts: 51

Rep: Reputation: 20
ALWAYS make backups before changing partitions. If you can't afford data loss, don't touch it. Having said that, your hard drive could crash at any time, so you should have a backup, anyway, if your data is important to you.

Logical volumes can be resized, but you must also resize the filesystem contained in the LV. If you do not, you'll have trouble.

This tutorial might be useful for you: http://www.tcpdump.com/kb/os/linux/l...ide/intro.html
 
1 members found this post helpful.
Old 01-06-2011, 12:44 AM   #4
yoachan
Member
 
Registered: Nov 2009
Posts: 109

Original Poster
Rep: Reputation: 16
Ok guys.

Thanks for the helps.
I'll do backup as djtoltz said, and will run resize as silvyus_06 told.

thanks for both of you
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
how to partition an lvm jamesbon Linux - Server 6 10-05-2010 08:41 AM
shrink LVM partition bcbotha Fedora 4 06-09-2009 06:00 PM
Copy Contents of LVM Partition to Another Partition With a Different File System tmort Linux - General 3 03-07-2008 06:00 AM
can't mount lvm partition alris Linux - General 2 12-19-2007 04:33 PM
Shrinking an LVM partition Sabre_X Linux - Software 6 10-01-2005 12:13 AM


All times are GMT -5. The time now is 09:57 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration