LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 11-12-2011, 11:55 AM   #1
drManhattan
Member
 
Registered: Aug 2010
Location: Warsaw, Poland
Distribution: Ubuntu 10.04 LTS on IBM Lenovo R61e, RHEL5-6,SLES10-11
Posts: 262

Rep: Reputation: 1
lvm extend on running file system


Hi

I wonder can I extend file system and lvm volume on running server.
File system is being used when I want to extend its size.

Can I do this without any danger to file system itself ?

ths for help.
 
Old 11-12-2011, 12:58 PM   #2
catkin
LQ 5k Club
 
Registered: Dec 2008
Location: Tamil Nadu, India
Distribution: Debian
Posts: 8,576
Blog Entries: 31

Rep: Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195Reputation: 1195
LVM volume: Yes. File system: depends on the file system.

No -- there is always a small possibility of something going wrong.
 
Old 11-13-2011, 11:58 AM   #3
drManhattan
Member
 
Registered: Aug 2010
Location: Warsaw, Poland
Distribution: Ubuntu 10.04 LTS on IBM Lenovo R61e, RHEL5-6,SLES10-11
Posts: 262

Original Poster
Rep: Reputation: 1
I have ext3 fs.

How can I do it without downtime ?
 
Old 11-13-2011, 12:16 PM   #4
hen770
Member
 
Registered: Oct 2010
Distribution: Arch
Posts: 136

Rep: Reputation: 7
The fs itself couldn't be resized when it's mounted and in use, take full backup if you try to force it, but in case it fails you have more downtime, so better to do do it unmounted.
 
Old 11-13-2011, 02:05 PM   #5
drManhattan
Member
 
Registered: Aug 2010
Location: Warsaw, Poland
Distribution: Ubuntu 10.04 LTS on IBM Lenovo R61e, RHEL5-6,SLES10-11
Posts: 262

Original Poster
Rep: Reputation: 1
thx for info.

But if I perform fs extension while fs is mounted but there is no I/O operations ?
 
Old 11-13-2011, 05:51 PM   #6
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 14,838

Rep: Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822Reputation: 1822
Not (necessarily) true.
Ext3 has supported online resize for some time (years). Extending the f/s can be done online, is supported, and works (for me). Check "man resize2fs".

A backup is always prudent.

Last edited by syg00; 11-13-2011 at 05:56 PM. Reason: Added command
 
1 members found this post helpful.
Old 11-15-2011, 05:02 AM   #7
hen770
Member
 
Registered: Oct 2010
Distribution: Arch
Posts: 136

Rep: Reputation: 7
Yep, my mistake there, you can resize you ext3 or ext4 fs with resize2fs (as long as the kernel supports it [from the man page]).
I have did it today with my /root ext4 partition that was on a 10G logical volume but the fs itself was just 7G, so with the /root partition mounted as root I have used resize2fs /dev/mapper/system-root (my lv name), and it became 10G in 2 sec.
 
  


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
[SOLVED] How to extend NFS file system jghvzln Linux - Server 1 06-07-2011 07:43 PM
Extend File system shaife720 Linux - General 1 05-02-2011 10:34 AM
not able to extend a fs using lvm unix1adm Linux - General 9 04-21-2011 10:01 AM
Adding an LVM hard disk to a system already running/using LVM firewiz87 Linux - Hardware 5 08-15-2010 01:59 AM
Extend file system mcouthino Linux - Enterprise 1 12-11-2005 10:21 AM


All times are GMT -5. The time now is 11:04 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