9 Replies Latest reply: Mar 26, 2012 3:05 PM by Dude! RSS

    VMware enhnced diskspace but OEL 6.1 not geting it on LVM for root

    661723
      hi

      I have a problem to be fixed by gurus.I am on home environment with VMware workstation 8 and a OEL 6.1 is deployed on it.
      The diskspace is enhanced upto 52G from 20G but the existing Guest OS (which is on OEL 6.1) not getting it.
      [root@nodeonvm2 Desktop]# fdisk -l
      
      Disk /dev/sda: 55.8 GB, 55834574848 bytes
      255 heads, 63 sectors/track, 6788 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: 0x0000aac1
      
         Device Boot      Start         End      Blocks   Id  System
      /dev/sda1   *           1          64      512000   83  Linux
      Partition 1 does not end on cylinder boundary.
      /dev/sda2              64        2611    20458496   8e  Linux LVM
      
      Disk /dev/mapper/VolGroup-lv_root: 18.8 GB, 18832424960 bytes
      255 heads, 63 sectors/track, 2289 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/VolGroup-lv_root doesn't contain a valid partition table
      
      Disk /dev/mapper/VolGroup-lv_swap: 2113 MB, 2113929216 bytes
      255 heads, 63 sectors/track, 257 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/VolGroup-lv_swap doesn't contain a valid partition table
      [root@nodeonvm2 Desktop]# 
      I just want "/dev/mapper/VolGroup-lv_root" to enhance upto some more gigs upto 2 Gigs more and create others for Testing Some ASM with 11gR2.

      kind regards
        • 1. Re: VMware enhnced diskspace but OEL 6.1 not geting it on LVM for root
          Dude!
          You will normally have to extend the size of the logical volume and also the file system residing in it. For instance:

          lvextend -L 2G /dev/VolGroup00/LogVol00
          resize2fs /dev/VolGroup00/LogVol00

          Linux 2.6 kernel supports on-line resize for filesystems mounted using ext3 only.
          • 2. Re: VMware enhnced diskspace but OEL 6.1 not geting it on LVM for root
            661723
            Hi Dude

            Dude wrote:
            You will normally have to extend the size of the logical volume and also the file system residing in it. For instance:

            lvextend -L 2G /dev/VolGroup00/LogVol00
            resize2fs /dev/VolGroup00/LogVol00

            Linux 2.6 kernel supports on-line resize for filesystems mounted using ext3 only.
            [root@nodeonvm2 ~]# lvextend -L 20G /dev/VolGroup/lv_root 
              Extending logical volume lv_root to 20.00 GiB
              Insufficient free space: 630 extents needed, but only 0 available
            [root@nodeonvm2 ~]# pv
            pva-addvo  pvck       pvdisplay  pvremove   pvs        pv.sh      
            pvchange   pvcreate   pvmove     pvresize   pvscan     
            [root@nodeonvm2 ~]# pvscan
              PV /dev/sda2   VG VolGroup   lvm2 [19.51 GiB / 0    free]
              Total: 1 [19.51 GiB] / in use: 1 [19.51 GiB] / in no VG: 0 [0   ]
            [root@nodeonvm2 ~]# 
            so its not happening.
            can we put LVM in hadoops cluster?
            http://en.wikipedia.org/wiki/Apache_Hadoop

            kind regards

            Edited by: no one on Mar 25, 2012 5:41 PM
            • 3. Re: VMware enhnced diskspace but OEL 6.1 not geting it on LVM for root
              Dude!
              You need to add more space to the Volume Group:

              create a new partiton, e.g. /dev/sda3
              <pre>
              fdisk /dev/sda
              </pre>
              Create a new primary partition and mark it with hex code 8e (linux lvm)

              Then try again:
              <pre>
              vgextend /dev/VolGroup /dev/sda3
              lvextend -L+20G /dev/VolGroup/lv_root
              resize2fs /dev/VolGroup/lv_root
              </pre>
              • 4. Re: VMware enhnced diskspace but OEL 6.1 not geting it on LVM for root
                661723
                Dude wrote:
                You need to add more space to the Volume Group:

                create a new partiton, e.g. /dev/sda3
                <pre>
                fdisk /dev/sda
                </pre>
                Create a new primary partition and mark it with hex code 8e (linux lvm)

                Then try again:
                <pre>
                vgextend /dev/VolGroup /dev/sda3
                lvextend -L+20G /dev/VolGroup/lv_root
                resize2fs /dev/VolGroup/lv_root
                </pre>
                [root@nodeonvm2 ~]# vgextend /dev/VolGroup /dev/sda3
                  No physical volume label read from /dev/sda3
                  Physical volume "/dev/sda3" successfully created
                  Volume group "VolGroup" successfully extended
                [root@nodeonvm2 ~]# lvextend -L 21G /dev/VolGroup/lv_root
                  Extending logical volume lv_root to 21.00 GiB
                  Insufficient free space: 886 extents needed, but only 768 available
                [root@nodeonvm2 ~]# lvextend -L 20G /dev/VolGroup/lv_root
                  Extending logical volume lv_root to 20.00 GiB
                  Logical volume lv_root successfully resized
                [root@nodeonvm2 ~]# lvextend -L 20.5G /dev/VolGroup/lv_root
                  Extending logical volume lv_root to 20.50 GiB
                  Logical volume lv_root successfully resized
                [root@nodeonvm2 ~]# lvextend -L 20.7G -r /dev/VolGroup/lv_root
                  Rounding up size to full physical extent 20.70 GiB
                  Extending logical volume lv_root to 20.70 GiB
                  Insufficient free space: 52 extents needed, but only 10 available
                [root@nodeonvm2 ~]# lvextend -L 20.6G -r /dev/VolGroup/lv_root
                  Rounding up size to full physical extent 20.60 GiB
                  Extending logical volume lv_root to 20.60 GiB
                  Insufficient free space: 26 extents needed, but only 10 available
                [root@nodeonvm2 ~]# lvextend -L 20.55G -r /dev/VolGroup/lv_root
                  Rounding up size to full physical extent 20.55 GiB
                  Extending logical volume lv_root to 20.55 GiB
                  Insufficient free space: 13 extents needed, but only 10 available
                [root@nodeonvm2 ~]# lvextend -L 20.54G -r /dev/VolGroup/lv_root
                  Rounding up size to full physical extent 20.54 GiB
                  Extending logical volume lv_root to 20.54 GiB
                  Insufficient free space: 11 extents needed, but only 10 available
                [root@nodeonvm2 ~]# lvextend -L 20.549G -r /dev/VolGroup/lv_root
                  Rounding up size to full physical extent 20.55 GiB
                  Extending logical volume lv_root to 20.55 GiB
                  Insufficient free space: 13 extents needed, but only 10 available
                [root@nodeonvm2 ~]# lvextend -L 20.545G -r /dev/VolGroup/lv_root
                  Rounding up size to full physical extent 20.55 GiB
                  Extending logical volume lv_root to 20.55 GiB
                  Insufficient free space: 12 extents needed, but only 10 available
                [root@nodeonvm2 ~]# lvextend -L 20.544G -r /dev/VolGroup/lv_root
                  Rounding up size to full physical extent 20.55 GiB
                  Extending logical volume lv_root to 20.55 GiB
                  Insufficient free space: 12 extents needed, but only 10 available
                [root@nodeonvm2 ~]# lvextend -L 20.53G -r /dev/VolGroup/lv_root
                  Rounding up size to full physical extent 20.53 GiB
                  Extending logical volume lv_root to 20.53 GiB
                  Logical volume lv_root successfully resized
                resize2fs 1.41.12 (17-May-2010)
                Filesystem at /dev/mapper/VolGroup-lv_root is mounted on /; on-line resizing required
                old desc_blocks = 2, new_desc_blocks = 2
                Performing an on-line resize of /dev/mapper/VolGroup-lv_root to 5382144 (4k) blocks.
                The filesystem on /dev/mapper/VolGroup-lv_root is now 5382144 blocks long.
                
                [root@nodeonvm2 ~]# 
                thanx its done.


                kind regards
                • 5. Re: VMware enhnced diskspace but OEL 6.1 not geting it on LVM for root
                  661723
                  hi

                  After the previous step i transfers some files to newly created different mount point but disk space has increased so fast.how to find the reason ?? As it is a VM ware environment So I suspect for enhancement is for some unused files are kept under VHFS.how do i clean them?

                  kind regards
                  • 6. Re: VMware enhnced diskspace but OEL 6.1 not geting it on LVM for root
                    661723
                    hi

                    After the previous step i transfers some files to newly created different mount point but disk space has increased so fast.how to find the reason ?? As it is a VM ware environment So I suspect for enhancement is for some unused files are kept under VHFS.how do i clean them?
                    [root@nodeonvm2 Desktop]# df -h
                    Filesystem            Size  Used Avail Use% Mounted on
                    /dev/mapper/VolGroup-lv_root
                                           21G   20G     0 100% /
                    tmpfs                1000M  264K 1000M   1% /dev/shm
                    /dev/sda1             485M   51M  409M  12% /boot
                    /dev/mapper/oracle-lvol0
                                          4.6G  1.4G  3.0G  32% /oracle
                    [root@nodeonvm2 Desktop]# 
                    kind regards
                    • 7. Re: VMware enhnced diskspace but OEL 6.1 not geting it on LVM for root
                      Dude!
                      You can try to find out which directory is eating all your root disk space:

                      <pre>
                      du -ms /*
                      </pre>
                      • 8. Re: VMware enhnced diskspace but OEL 6.1 not geting it on LVM for root
                        661723
                        Hi

                        Thx.
                        Dude wrote:
                        You can try to find out which directory is eating all your root disk space:

                        <pre>
                        du -ms /*
                        </pre>
                        [root@nodeonvm2 VMwareDnD]# pwd
                        /tmp/VMwareDnD
                        its replicating the copied file(s) from host to gust OS.
                        how to find if any process filled up the spaces?

                        kind regards
                        • 9. Re: VMware enhnced diskspace but OEL 6.1 not geting it on LVM for root
                          Dude!
                          Apparently this folder is created a temporary space for files which you drag & drop (DnD) to the VM's.