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 08-07-2013, 06:24 AM   #1
boby.kumar
Member
 
Registered: Mar 2013
Posts: 92

Rep: Reputation: Disabled
Increase /dev/mapper/VolGroup-lv_home by adding an extra hard drive in liux system


Hi Team
Thanks a lot for the support you had been providing me. Now again need your help here. Actually i have a linux system with 1TB hd and /home area is showing 1TB. we need to increase /home area by adding an extra hard drive as 1TB to make it 2TB.
A snapshot is goes here for /home area:

Filesystem Type Size Used Avail Use% Mounted on
/dev/mapper/VolGroup-lv_root ext4 50G 3.1G 44G 7% /
tmpfs tmpfs 1.9G 276K 1.9G 1% /dev/shm
/dev/sda1 ext4 485M 35M 425M 8% /boot
/dev/mapper/VolGroup-lv_home ext4 1.8T 197M 1.7T 1% /home

As per googling i have added hd and create /dev/sb1 pv and added this pv to existing vg.
following is the snapshot here:

--- Volume group ---
VG Name VolGroup
System ID
Format lvm2
Metadata Areas 2
Metadata Sequence No 8
VG Access read/write
VG Status resizable
MAX LV 0
Cur LV 3
Open LV 3
Max PV 0
Cur PV 2
Act PV 2
VG Size 3.64 TiB
PE Size 4.00 MiB
Total PE 953737
Alloc PE / Size 953737 / 3.64 TiB
Free PE / Size 0 / 0
VG UUID Km6NE9-n5sq-dDc4-cigp-w6Rk-sPLF-OvoKhu
After that system had restarted to take new effects.
It should be show me the size of /home area to 2TB but no change here.

[root@www ~]# df -PTh
Filesystem Type Size Used Avail Use% Mounted on
/dev/mapper/VolGroup-lv_root ext4 50G 3.1G 44G 7% /
tmpfs tmpfs 1.9G 276K 1.9G 1% /dev/shm
/dev/sda1 ext4 485M 35M 425M 8% /boot
/dev/mapper/VolGroup-lv_home ext4 1.8T 197M 1.7T 1% /home

Could you please let me know how to increase /dev/mapper/VolGroup-lv_home this area to 2TB? I am totally stucked here.
please help me.

Thanks in Advance
 
Old 08-07-2013, 07:51 AM   #2
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.8, Centos 5.10
Posts: 17,240

Rep: Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324
The usual steps are
1. add disk
2. make disk a pv
3. add pv to vg
4. lvextend ...

http://tldp.org/HOWTO/LVM-HOWTO/
 
Old 08-07-2013, 07:53 AM   #3
Ser Olmy
Senior Member
 
Registered: Jan 2012
Distribution: Slackware
Posts: 2,404

Rep: Reputation: Disabled
I assume you added the new Physical Volume to the Volume Group with vgextend. Now you need to extend the Logical Volume "VolGroup-lv_home" with lvextend and finally extend the file system with resize2fs.
 
Old 08-08-2013, 07:57 AM   #4
boby.kumar
Member
 
Registered: Mar 2013
Posts: 92

Original Poster
Rep: Reputation: Disabled
Thanks for your reply.
If i want to format whole hard drive by mkfs.ext4 /dev/sdb commnad,Is hard drive crashed or not?
can i use this later as it has 2000GB space? please suggest me.
 
Old 08-08-2013, 08:21 AM   #5
Ser Olmy
Senior Member
 
Registered: Jan 2012
Distribution: Slackware
Posts: 2,404

Rep: Reputation: Disabled
I'm afraid I don't understand exactly what you're asking, or how it relates to your original question (if at all). What do you mean by "crashed"?
 
Old 08-08-2013, 08:38 AM   #6
boby.kumar
Member
 
Registered: Mar 2013
Posts: 92

Original Poster
Rep: Reputation: Disabled
Dear Ser Olmy

i am getting the following error in Hard disk while creating the partition:

Disk /dev/sdb: 2000.4 GB, 2000398934016 bytes
255 heads, 63 sectors/track, 243201 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk identifier: 0x55293afb

Device Boot Start End Blocks Id System
/dev/sdb1 1 243201 1953512001 83 Linux
Partition 1 does not start on physical sector boundary.

Could you please explain why its happening? please share resolution with me.

Regards
New Member
 
Old 08-08-2013, 09:18 AM   #7
Ser Olmy
Senior Member
 
Registered: Jan 2012
Distribution: Slackware
Posts: 2,404

Rep: Reputation: Disabled
I don't see an error message?

If you mean the "partition 1 does not start on physical sector boundary" message, that appears because of this:
Code:
Disk /dev/sdb: 2000.4 GB, 2000398934016 bytes
255 heads, 63 sectors/track, 243201 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
This is an "advanced format" disk with 4096 byte physical sectors, but for compatibility reasons it emulates 512 byte sectors. Each physical sector contains 8 emulated, logical sectors.

Your partition starts at emulated sector 243201, which is not a multiple of 8. This is not optimal, and that's why you're getting the "does not start on physical sector boundary" message.
 
Old 08-08-2013, 09:38 AM   #8
boby.kumar
Member
 
Registered: Mar 2013
Posts: 92

Original Poster
Rep: Reputation: Disabled
how can i fix this problem? please help me
 
Old 08-08-2013, 09:45 AM   #9
Ser Olmy
Senior Member
 
Registered: Jan 2012
Distribution: Slackware
Posts: 2,404

Rep: Reputation: Disabled
Delete the partition and recreate it so it starts on a physical sector boundary. The first sector number must be a multiple of 8. 234201 is not, but 234200 or 234208 is.

By the way, why does the partition start so far from the beginning of the disk?
 
  


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
create /dev/mapper/volgroup-volume -> ../dm-N Zimmi84 Linux - Server 0 07-20-2013 09:44 PM
[SOLVED] Adding another hard drive changes drive id's in /dev/sd* explorer Slackware 11 04-01-2011 10:09 AM
Cannot mount my /dev/mapper/crypted-drive BashTin Slackware 2 02-18-2010 10:19 AM
Adding a new hard drive in Centos 5.1 system; a few questions... nadsab Linux - Hardware 8 03-28-2008 04:33 PM
Adding a EIDE hard drive to a SCSI system beepay Linux - Hardware 2 01-19-2006 03:59 PM


All times are GMT -5. The time now is 03:07 PM.

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