Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

Increase filesystem Size RHEL5

Posted on 2011-04-19
7
Medium Priority
?
443 Views
Last Modified: 2012-06-21
How do I check how much space is still left out in my VG and if yes how do I increase /home
0
Comment
Question by:mnis2008
  • 4
  • 2
7 Comments
 
LVL 38

Expert Comment

by:wesly_chen
ID: 35428273
As root:
# pvdisplay
# vgdisplay
# lvdsiplay
0
 
LVL 38

Expert Comment

by:wesly_chen
ID: 35428291
Please post the output of those commands above plus this one:
# fdisk -l

So people here know your disk usage.
0
 
LVL 38

Expert Comment

by:wesly_chen
ID: 35428453
Woo, typo, should be (as root)
# pvdisplay
# vgdisplay
# lvdisplay
# fdisk -l
0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 
LVL 31

Expert Comment

by:farzanj
ID: 35428464
You can display one of the following

lvmdiskscan

pvs
vgs
lvs
pvscan
vgscan
lvscan

pvdisplay
vgdisplay
lvdisplay

You can extend your vg by vgextend
You can change your lvm by lvresize
0
 

Author Comment

by:mnis2008
ID: 35428960
Here is the output

]# lvdisplay
  --- Logical volume ---
  LV Name                /dev/VolGroup01/LogVol01
  VG Name                VolGroup01
  LV UUID                amYm35-eWPU-K8sR-jQnW-z79F-OlgY-K98WqV
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                3.97 GB
  Current LE             127
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:12

  --- Logical volume ---
  LV Name                /dev/VolGroup00/root
  VG Name                VolGroup00
  LV UUID                97IkAC-T35d-CMSg-8QXk-vsgs-fe9Q-fglWor
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                1.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:0

  --- Logical volume ---
  LV Name                /dev/VolGroup00/home
  VG Name                VolGroup00
  LV UUID                o0sDnj-LHHT-c0vl-GchM-3ZU4-1Fxe-1nlctD
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                1.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:1

  --- Logical volume ---
  LV Name                /dev/VolGroup00/admin
  VG Name                VolGroup00
  LV UUID                p63Zcf-dl4x-hAct-EjOl-lO6u-04Vc-90Oy05
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                1.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:2

  --- Logical volume ---
  LV Name                /dev/VolGroup00/tmp
  VG Name                VolGroup00
  LV UUID                UgXBKO-SumX-YFHK-pZg5-3saJ-Ad7F-mCnVGY
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                1.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:3

  --- Logical volume ---
  LV Name                /dev/VolGroup00/opt
  VG Name                VolGroup00
  LV UUID                d1Fl4U-cOLs-cYsN-2KDu-PcSJ-DM5X-AaBloB
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                2.00 GB
  Current LE             64
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:4

  --- Logical volume ---
  LV Name                /dev/VolGroup00/apps
  VG Name                VolGroup00
  LV UUID                fYMh5e-h0mu-qvxp-mthR-VqN9-YGiB-QBJulw
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                1.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:5

  --- Logical volume ---
  LV Name                /dev/VolGroup00/usr
  VG Name                VolGroup00
  LV UUID                HlRhrM-3EOx-xmwS-sA3s-l784-43KP-U2Khuj
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                3.00 GB
  Current LE             96
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:6

  --- Logical volume ---
  LV Name                /dev/VolGroup00/var
  VG Name                VolGroup00
  LV UUID                l3Onon-vaPN-rWG2-hbiP-yPei-BOdI-BKkyTO
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                3.00 GB
  Current LE             96
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:7

  --- Logical volume ---
  LV Name                /dev/VolGroup00/varlog
  VG Name                VolGroup00
  LV UUID                FrtRk7-w0BZ-Zuk9-4BJl-NAFx-wmzA-DBcRIB
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                1.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:8

  --- Logical volume ---
  LV Name                /dev/VolGroup00/varlogaudit
  VG Name                VolGroup00
  LV UUID                VY8XGg-bIKn-xWWQ-fai7-pMIN-xZTd-7xlFev
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                1.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:9

# pvdisplay
  --- Physical volume ---
  PV Name               /dev/sdb1
  VG Name               VolGroup01
  PV Size               4.00 GB / not usable 30.63 MB
  Allocatable           yes (but full)
  PE Size (KByte)       32768
  Total PE              127
  Free PE               0
  Allocated PE          127
  PV UUID               8E781D-N6LZ-JQWk-ZXWf-R1WP-8d4r-HqrXBU

  --- Physical volume ---
  PV Name               /dev/sda2
  VG Name               VolGroup00
  PV Size               22.90 GB / not usable 22.43 MB
  Allocatable           yes
  PE Size (KByte)       32768
  Total PE              732
  Free PE               252
  Allocated PE          480
  PV UUID               Z8nPcb-ggmA-9kVL-GGZL-Q7I4-q2MI-BxcUD7

  --- Physical volume ---
  PV Name               /dev/sdc1
  VG Name               VolGroup00
  PV Size               60.00 GB / not usable 28.04 MB
  Allocatable           yes
  PE Size (KByte)       32768
  Total PE              1919
  Free PE               1919
  Allocated PE          0
  PV UUID               ijmOcX-f3RR-mnPZ-mvAG-mkJV-WHQ2-qT8P6q

]# vgdisplay
  --- Volume group ---
  VG Name               VolGroup01
  System ID
  Format                lvm2
  Metadata Areas        1
  Metadata Sequence No  2
  VG Access             read/write
  VG Status             resizable
  MAX LV                0
  Cur LV                1
  Open LV               1
  Max PV                0
  Cur PV                1
  Act PV                1
  VG Size               3.97 GB
  PE Size               32.00 MB
  Total PE              127
  Alloc PE / Size       127 / 3.97 GB
  Free  PE / Size       0 / 0
  VG UUID               FQi33v-GzIl-gtfM-cMWV-j1MI-QJN8-xQ2z4U

  --- Volume group ---
  VG Name               VolGroup00
  System ID
  Format                lvm2
  Metadata Areas        2
  Metadata Sequence No  16
  VG Access             read/write
  VG Status             resizable
  MAX LV                0
  Cur LV                10
  Open LV               10
  Max PV                0
  Cur PV                2
  Act PV                2
  VG Size               82.84 GB
  PE Size               32.00 MB
  Total PE              2651
  Alloc PE / Size       480 / 15.00 GB
  Free  PE / Size       2171 / 67.84 GB
  VG UUID               KJse36-7Sml-o0hm-JWoc-6QPR-vhb4-KtmxVa

[root@lpv042 Data_Files]# lvdisplay
  --- Logical volume ---
  LV Name                /dev/VolGroup01/LogVol01
  VG Name                VolGroup01
  LV UUID                amYm35-eWPU-K8sR-jQnW-z79F-OlgY-K98WqV
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                3.97 GB
  Current LE             127
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:12

  --- Logical volume ---
  LV Name                /dev/VolGroup00/root
  VG Name                VolGroup00
  LV UUID                97IkAC-T35d-CMSg-8QXk-vsgs-fe9Q-fglWor
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                1.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:0

  --- Logical volume ---
  LV Name                /dev/VolGroup00/home
  VG Name                VolGroup00
  LV UUID                o0sDnj-LHHT-c0vl-GchM-3ZU4-1Fxe-1nlctD
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                1.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:1

  --- Logical volume ---
  LV Name                /dev/VolGroup00/admin
  VG Name                VolGroup00
  LV UUID                p63Zcf-dl4x-hAct-EjOl-lO6u-04Vc-90Oy05
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                1.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:2

  --- Logical volume ---
  LV Name                /dev/VolGroup00/tmp
  VG Name                VolGroup00
  LV UUID                UgXBKO-SumX-YFHK-pZg5-3saJ-Ad7F-mCnVGY
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                1.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:3

  --- Logical volume ---
  LV Name                /dev/VolGroup00/opt
  VG Name                VolGroup00
  LV UUID                d1Fl4U-cOLs-cYsN-2KDu-PcSJ-DM5X-AaBloB
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                2.00 GB
  Current LE             64
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:4

  --- Logical volume ---
  LV Name                /dev/VolGroup00/apps
  VG Name                VolGroup00
  LV UUID                fYMh5e-h0mu-qvxp-mthR-VqN9-YGiB-QBJulw
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                1.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:5

  --- Logical volume ---
  LV Name                /dev/VolGroup00/usr
  VG Name                VolGroup00
  LV UUID                HlRhrM-3EOx-xmwS-sA3s-l784-43KP-U2Khuj
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                3.00 GB
  Current LE             96
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:6

  --- Logical volume ---
  LV Name                /dev/VolGroup00/var
  VG Name                VolGroup00
  LV UUID                l3Onon-vaPN-rWG2-hbiP-yPei-BOdI-BKkyTO
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                3.00 GB
  Current LE             96
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:7

  --- Logical volume ---
  LV Name                /dev/VolGroup00/varlog
  VG Name                VolGroup00
  LV UUID                FrtRk7-w0BZ-Zuk9-4BJl-NAFx-wmzA-DBcRIB
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                1.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:8

  --- Logical volume ---
  LV Name                /dev/VolGroup00/varlogaudit
  VG Name                VolGroup00
  LV UUID                VY8XGg-bIKn-xWWQ-fai7-pMIN-xZTd-7xlFev
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                1.00 GB
  Current LE             32
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:9


# fdisk -l

Disk /dev/sda: 24.6 GB, 24696061952 bytes
255 heads, 63 sectors/track, 3002 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1          13      104358+  83  Linux
/dev/sda2              14        3002    24009142+  8e  Linux LVM

Disk /dev/sdb: 4294 MB, 4294967296 bytes
255 heads, 63 sectors/track, 522 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   *           1         522     4192901   8e  Linux LVM
Partition 1 has different physical/logical beginnings (non-Linux?):
     phys=(0, 1, 1) logical=(0, 2, 3)

Disk /dev/sdc: 64.4 GB, 64424509440 bytes
255 heads, 63 sectors/track, 7832 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdc1               1        7832    62910508+  8e  Linux LVM
0
 
LVL 38

Accepted Solution

by:
wesly_chen earned 2000 total points
ID: 35429055
 VG Name               VolGroup00
...
  VG Size               82.84 GB
  PE Size               32.00 MB
  Total PE              2651
  Alloc PE / Size       480 / 15.00 GB
  Free  PE / Size       2171 / 67.84 GB
-----------------
--- Logical volume ---
  LV Name                /dev/VolGroup00/home
  VG Name                VolGroup00
...
  LV Size                1.00 GB
--------------------

So you can (as root)
# lvextend -L +3G /dev/VolGroup00/home
where "-L +3G " is adding 3GB to /home and you can change to any size
0
 

Author Comment

by:mnis2008
ID: 35429065
This worked ...Thanks
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Little introduction about CP: CP is a command on linux that use to copy files and folder from one location to another location. Example usage of CP as follow: cp /myfoder /pathto/destination/folder/ cp abc.tar.gz /pathto/destination/folder/ab…
Join Greg Farro and Ethan Banks from Packet Pushers (http://packetpushers.net/podcast/podcasts/pq-show-93-smart-network-monitoring-paessler-sponsored/) and Greg Ross from Paessler (https://www.paessler.com/prtg) for a discussion about smart network …
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.
Suggested Courses
Course of the Month10 days, 23 hours left to enroll

572 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question