LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 01-30-2013, 08:55 AM   #1
rhbegin
Member
 
Registered: Oct 2003
Location: Arkansas, NWA
Distribution: Fedora/CentOS/SL6
Posts: 381

Rep: Reputation: 23
Question LVM - creating extra logical volumes (using extra space outside LVM)


I am trying to understand a concept that is confusing me.

I created a virtual machine, it is for a internal samba file share (small-no password).

So I created the LVM then sized it accordingly, putting 'root' /, /home, /var, and swap in the logical volume group - vg01 - inside it there is lv00-lv04 for the mount points.

So there is about 7-8GB of unused space in the virtual machine container - outside the LVM group created (unused).

When I run fdisk -l it ONLY shows /dev/sda /dev/sda1 and /dev/sda2 in which (sda1 - boot) and (sda2 - is the Logical Volume Group - vg01).

/dev/sda
/dev/sda1 -- /boot ext4
/dev/sda2 -- /

I am not seeing the extra disk space, nor am I able to allocate it to create another logical volume group for the 'samba file share'.


The big question is, how do you use the free space or allocate it? It is not seen by fdisk -l (I am not aware of another method).

Can anyone help shed some light/advice on this?

Below the extra disk space is show via fdisk -l (however how do you create another Logical Volume Group???)

[root@is01 ~]# fdisk -l

Disk /dev/sda: 26.8 GB, 26843545600 bytes
64 heads, 32 sectors/track, 25600 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00034e7f

Device Boot Start End Blocks Id System
/dev/sda1 * 2 501 512000 83 Linux
Partition 1 does not end on cylinder boundary.
/dev/sda2 502 17909 17825792 8e Linux LVM
Partition 2 does not end on cylinder boundary.

Disk /dev/mapper/vg_is01-lv03: 2147 MB, 2147483648 bytes
255 heads, 63 sectors/track, 261 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000


Disk /dev/mapper/vg_is01-lv00: 12.9 GB, 12884901888 bytes
255 heads, 63 sectors/track, 1566 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000


Disk /dev/mapper/vg_is01-lv02: 1073 MB, 1073741824 bytes
255 heads, 63 sectors/track, 130 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000


Disk /dev/mapper/vg_is01-lv01: 2143 MB, 2143289344 bytes
255 heads, 63 sectors/track, 260 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

[root@is01 ~]# vgdisplay
--- Volume group ---
VG Name vg_is01
System ID
Format lvm2
Metadata Areas 1
Metadata Sequence No 5
VG Access read/write
VG Status resizable
MAX LV 0
Cur LV 4
Open LV 4
Max PV 0
Cur PV 1
Act PV 1
VG Size 17.00 GiB
PE Size 4.00 MiB
Total PE 4351
Alloc PE / Size 4351 / 17.00 GiB
Free PE / Size 0 / 0
VG UUID Uvw4iE-w0Mg-f0JT-Vdv7-ppJI-CkbZ-yqBiNx

Last edited by rhbegin; 01-30-2013 at 09:00 AM.
 
Old 01-30-2013, 07:08 PM   #2
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,153

Rep: Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125Reputation: 4125
Try this (as root)
Code:
parted /dev/sda "print free"
The tools tend not to show the free space, but allow you to allocate it to new partition(s). cfdisk is an exception - once in it, you get a nice ncurses interface that does show the free space.
You need to create a partition, run pvcreate on it then either add it to your current vg, or create another vg - your choice.
tldp.org has a good (if old) howto - redhat used to have good admin guides on their docs site, I presume they still do.
 
  


Reply



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 add unallocated space to a logical volume? using LVM tauro_kpo Linux - Hardware 7 08-19-2012 01:02 PM
Creating additional volumes with LVM Zymus Linux - General 1 10-20-2011 02:41 AM
[SOLVED] How to list filesystems that are using LVM logical volumes? Centos 5.6 needsleep Linux - Newbie 2 06-23-2011 11:53 PM
New Kubuntu8.1 with extra storage on LVM don_wombat_73 Linux - Software 0 12-08-2008 03:43 PM
LVM - Extending logical volume - Insufficient free space deim Linux - Newbie 0 04-07-2007 09:47 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 04: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
Open Source Consulting | Domain Registration