LinuxQuestions.org
Help answer threads with 0 replies.
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 03-19-2012, 07:32 AM   #16
stevenl
LQ Newbie
 
Registered: Mar 2012
Posts: 13

Original Poster
Rep: Reputation: Disabled

Code:
root@atraina-alfdrp:~# fdisk -lu /dev/sda

Disk /dev/sda: 107.6 GB, 107646812160 bytes
255 heads, 63 sectors/track, 13087 cylinders, total 210247680 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000d854e

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048      499711      248832   83  Linux
/dev/sda2          501758   134215679    66856961    5  Extended
/dev/sda3          499712      501757        1023   83  Linux
/dev/sda5          501760   134215679    66856960   8e  Linux LVM

Partition table entries are not in disk order
root@atraina-alfdrp:~#
 
Click here to see the post LQ members have rated as the most helpful post in this thread.
Old 03-19-2012, 10:16 AM   #17
xeleema
Member
 
Registered: Aug 2005
Location: D.i.t.h.o, Texas
Distribution: Slackware 13.x, rhel3/5, Solaris 8-10(sparc), HP-UX 11.x (pa-risc)
Posts: 987
Blog Entries: 4

Rep: Reputation: 252Reputation: 252Reputation: 252
You need to delete sda3 and recreate it again using the steps in Post #6

You were supposed to stick sda3 at the end (block-wise) of sda5. The starting cylinder should have been 134215680.
 
Old 03-22-2012, 01:37 AM   #18
stevenl
LQ Newbie
 
Registered: Mar 2012
Posts: 13

Original Poster
Rep: Reputation: Disabled
Hi, still not able to resolve the problem.

Code:
root@atraina-alfdrp:~# fdisk -lu /dev/sda

Disk /dev/sda: 107.6 GB, 107646812160 bytes
255 heads, 63 sectors/track, 13087 cylinders, total 210247680 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000d854e

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048      499711      248832   83  Linux
/dev/sda2          501758   134215679    66856961    5  Extended
/dev/sda4       134215680   210247679    38016000   83  Linux
/dev/sda5          501760   134215679    66856960   8e  Linux LVM
root@atraina-alfdrp:~# pvcreate /dev/sda4
  Physical volume "/dev/sda4" successfully created
root@atraina-alfdrp:~#
root@atraina-alfdrp:~# vgextend atraina-alfdrp /dev/sda4
  Couldn't find device with uuid uY5OiE-xRpo-jYXL-VdLq-PgwA-E2BP-dbej3C.
  Cannot change VG atraina-alfdrp while PVs are missing.
  Consider vgreduce --removemissing.
root@atraina-alfdrp:~# fdisk -lu

Disk /dev/sda: 107.6 GB, 107646812160 bytes
255 heads, 63 sectors/track, 13087 cylinders, total 210247680 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000d854e

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048      499711      248832   83  Linux
/dev/sda2          501758   134215679    66856961    5  Extended
/dev/sda4       134215680   210247679    38016000   83  Linux
/dev/sda5          501760   134215679    66856960   8e  Linux LVM

Disk /dev/mapper/atraina--alfdrp-root: 51.3 GB, 51279560704 bytes
255 heads, 63 sectors/track, 6234 cylinders, total 100155392 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/mapper/atraina--alfdrp-root doesn't contain a valid partition table

Disk /dev/mapper/atraina--alfdrp-swap_1: 17.2 GB, 17179869184 bytes
255 heads, 63 sectors/track, 2088 cylinders, total 33554432 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/mapper/atraina--alfdrp-swap_1 doesn't contain a valid partition table
root@atraina-alfdrp:~# ls -l /dev/sda*
brw-rw---- 1 root disk 8, 0 2012-03-22 16:31 /dev/sda
brw-rw---- 1 root disk 8, 1 2012-03-22 16:31 /dev/sda1
brw-rw---- 1 root disk 8, 2 2012-03-22 16:31 /dev/sda2
brw-rw---- 1 root disk 8, 4 2012-03-22 16:58 /dev/sda4
brw-rw---- 1 root disk 8, 5 2012-03-22 16:31 /dev/sda5
root@atraina-alfdrp:~# fdisk -lu /dev/sda

Disk /dev/sda: 107.6 GB, 107646812160 bytes
255 heads, 63 sectors/track, 13087 cylinders, total 210247680 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000d854e

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048      499711      248832   83  Linux
/dev/sda2          501758   134215679    66856961    5  Extended
/dev/sda4       134215680   210247679    38016000   83  Linux
/dev/sda5          501760   134215679    66856960   8e  Linux LVM
root@atraina-alfdrp:~# vgs
  Couldn't find device with uuid uY5OiE-xRpo-jYXL-VdLq-PgwA-E2BP-dbej3C.
  VG             #PV #LV #SN Attr   VSize  VFree
  atraina-alfdrp   2   2   0 wz-pn- 63.76g    0
root@atraina-alfdrp:~# lvextend +1gb /dev/atraina-alfdrp/root
  Path required for Logical Volume "+1gb"
  Please provide a volume group name
  Run `lvextend --help' for more information.
root@atraina-alfdrp:~# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/atraina--alfdrp-root
                       48G   47G     0 100% /
udev                  7.9G  4.0K  7.9G   1% /dev
tmpfs                 3.2G  556K  3.2G   1% /run
none                  5.0M     0  5.0M   0% /run/lock
none                  7.9G     0  7.9G   0% /run/shm
/dev/sda1             228M   24M  193M  11% /boot
root@atraina-alfdrp:~# fdisk -lu /dev/sda

Disk /dev/sda: 107.6 GB, 107646812160 bytes
255 heads, 63 sectors/track, 13087 cylinders, total 210247680 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000d854e

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048      499711      248832   83  Linux
/dev/sda2          501758   134215679    66856961    5  Extended
/dev/sda4       134215680   210247679    38016000   83  Linux
/dev/sda5          501760   134215679    66856960   8e  Linux LVM
root@atraina-alfdrp:~# pvcreate /dev/sda4
  Physical volume "/dev/sda4" successfully created
root@atraina-alfdrp:~# vgextend atraina-alfdrp /dev/sda4
  Couldn't find device with uuid uY5OiE-xRpo-jYXL-VdLq-PgwA-E2BP-dbej3C.
  Cannot change VG atraina-alfdrp while PVs are missing.
  Consider vgreduce --removemissing.
root@atraina-alfdrp:~#
 
Old 03-23-2012, 12:32 AM   #19
xeleema
Member
 
Registered: Aug 2005
Location: D.i.t.h.o, Texas
Distribution: Slackware 13.x, rhel3/5, Solaris 8-10(sparc), HP-UX 11.x (pa-risc)
Posts: 987
Blog Entries: 4

Rep: Reputation: 252Reputation: 252Reputation: 252
This looks good...
Code:
 root@atraina-alfdrp:~# pvcreate /dev/sda4
  Physical volume "/dev/sda4" successfully created
root@atraina-alfdrp:~#
However I would suggest a "pvremove /dev/sda4" because the "Type" on sda4 is not correct.
This...
Code:
/dev/sda4  134215680  210247679  38016000  83  Linux
should look like this...
Code:
/dev/sda4  134215680  210247679  38016000  8e  Linux LVM
...then do the "pvcreate /dev/sda4" again.

Now this points to a different problem....
Code:
root@atraina-alfdrp:~# vgextend atraina-alfdrp /dev/sda4
  Couldn't find device with uuid uY5OiE-xRpo-jYXL-VdLq-PgwA-E2BP-dbej3C.
  Cannot change VG atraina-alfdrp while PVs are missing.
  Consider vgreduce --removemissing.
root@atraina-alfdrp:~#
I would suggest you post the output of "pvs" and "vgdisplay -v /dev/atraina-alfdrp", then consider running the command that the error gave you.

From the 'vgreduce' Man Page (RHEL5)
Code:
  --removemissing
       Removes  all  missing physical volumes from the volume group, if there are
       no logical volumes allocated on those. This resumes  normal  operation  of
       the volume group (new logical volumes may again be created, changed and so
       on).

       If this is not possible (there are logical volumes referencing the missing
       physical  volumes)  and you cannot or do not want to remove them manually,
       you can run this option with --force to have vgreduce remove  any  partial
       LVs.

       Any  logical volumes and dependent snapshots that were partly on the miss-
       ing disks get removed completely. This includes those parts  that  lie  on
       disks that are still present.

       If  your logical volumes spanned several disks including the ones that are
       lost, you might want to try to salvage data first by activating your logi-
       cal volumes with --partial as described in lvm (8).
 
Old 03-23-2012, 01:22 AM   #20
stevenl
LQ Newbie
 
Registered: Mar 2012
Posts: 13

Original Poster
Rep: Reputation: Disabled
Hi,

Kind of lost now. What do I do next with following output?

Code:
root@atraina-alfdrp:~#
root@atraina-alfdrp:~#
root@atraina-alfdrp:~# fdisk -lu /dev/sda

Disk /dev/sda: 107.6 GB, 107646812160 bytes
255 heads, 63 sectors/track, 13087 cylinders, total 210247680 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000d854e

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048      499711      248832   83  Linux
/dev/sda2          501758   134215679    66856961    5  Extended
/dev/sda4       134215680   210247679    38016000   83  Linux
/dev/sda5          501760   134215679    66856960   8e  Linux LVM
root@atraina-alfdrp:~# pvremove /dev/sda4
  No physical volume label read from /dev/sda4
  Physical Volume /dev/sda4 not found
root@atraina-alfdrp:~# pvcreate /dev/sda4
  Physical volume "/dev/sda4" successfully created
root@atraina-alfdrp:~# fdisk -lu

Disk /dev/sda: 107.6 GB, 107646812160 bytes
255 heads, 63 sectors/track, 13087 cylinders, total 210247680 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000d854e

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048      499711      248832   83  Linux
/dev/sda2          501758   134215679    66856961    5  Extended
/dev/sda4       134215680   210247679    38016000   83  Linux
/dev/sda5          501760   134215679    66856960   8e  Linux LVM

Disk /dev/mapper/atraina--alfdrp-root: 51.3 GB, 51279560704 bytes
255 heads, 63 sectors/track, 6234 cylinders, total 100155392 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/mapper/atraina--alfdrp-root doesn't contain a valid partition table

Disk /dev/mapper/atraina--alfdrp-swap_1: 17.2 GB, 17179869184 bytes
255 heads, 63 sectors/track, 2088 cylinders, total 33554432 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/mapper/atraina--alfdrp-swap_1 doesn't contain a valid partition table
root@atraina-alfdrp:~# pvs
  Couldn't find device with uuid uY5OiE-xRpo-jYXL-VdLq-PgwA-E2BP-dbej3C.
  PV             VG             Fmt  Attr PSize    PFree
  /dev/sda4                     lvm2 a-     36.25g   36.25g
  /dev/sda5      atraina-alfdrp lvm2 a-     63.76g       0
  unknown device atraina-alfdrp lvm2 a-   1023.00k 1023.00k
root@atraina-alfdrp:~# vgdisplay -v /dev/atraina-alfdrp
    Using volume group(s) on command line
    Finding volume group "atraina-alfdrp"
    Wiping cache of LVM-capable devices
  Couldn't find device with uuid uY5OiE-xRpo-jYXL-VdLq-PgwA-E2BP-dbej3C.
    There are 1 physical volumes missing.
  --- Volume group ---
  VG Name               atraina-alfdrp
  System ID
  Format                lvm2
  Metadata Areas        1
  Metadata Sequence No  4
  VG Access             read/write
  VG Status             resizable
  MAX LV                0
  Cur LV                2
  Open LV               2
  Max PV                0
  Cur PV                2
  Act PV                1
  VG Size               63.76 GiB
  PE Size               4.00 MiB
  Total PE              16322
  Alloc PE / Size       16322 / 63.76 GiB
  Free  PE / Size       0 / 0
  VG UUID               YbbqA9-JzkF-RF0l-sEQx-O84s-2vf6-sKlHdt

  --- Logical volume ---
  LV Name                /dev/atraina-alfdrp/root
  VG Name                atraina-alfdrp
  LV UUID                VdYKYU-rTvN-8CuL-sGpS-1pJf-UyeK-Gq69L6
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                47.76 GiB
  Current LE             12226
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           252:0

  --- Logical volume ---
  LV Name                /dev/atraina-alfdrp/swap_1
  VG Name                atraina-alfdrp
  LV UUID                jiN3wj-h1dr-l56B-ppmj-F9wr-49nD-7y7XCV
  LV Write Access        read/write
  LV Status              available
  # open                 2
  LV Size                16.00 GiB
  Current LE             4096
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           252:1

  --- Physical volumes ---
  PV Name               /dev/sda5
  PV UUID               snB3MQ-ayC7-J7Na-wsCF-Mg9O-3D2L-bhv0nu
  PV Status             allocatable
  Total PE / Free PE    16322 / 0

  PV Name               unknown device
  PV UUID               uY5OiE-xRpo-jYXL-VdLq-PgwA-E2BP-dbej3C
  PV Status             allocatable
  Total PE / Free PE    0 / 0
 
Old 03-23-2012, 06:00 AM   #21
xeleema
Member
 
Registered: Aug 2005
Location: D.i.t.h.o, Texas
Distribution: Slackware 13.x, rhel3/5, Solaris 8-10(sparc), HP-UX 11.x (pa-risc)
Posts: 987
Blog Entries: 4

Rep: Reputation: 252Reputation: 252Reputation: 252
Quote:
Originally Posted by stevenl View Post
Hi, Kind of lost now. What do I do next with following output?
Okay, now run "vgreduce --removemissing" then "vgextend /dev/atraina-alfdrp /dev/sda4".
Once you have that, then you can extend your 'root' (/) Logical Volume like so;
Code:
 lvextend -L +10g /dev/atraina-alfdrp/root
Now once you extend the logical volume, you then need to extend the filesystem itself.
How you do this depends on what the filesystem type is (ext3, xfs, reiser).

To find the "Type" of filesystem, look at the output of "mount | grep root"

Example: Finding the Filesystem "Type"
Code:
root@server(Linux)/# mount|grep rot
/dev/mapper/vg-rot on / type ext3 (rw)
root@server(Linux)/#
If the filesystem is ext3, then you would extend the filesystem like so;
Code:
resize2fs /dev/atraina-alfdrp/root
 
Old 03-25-2012, 02:44 AM   #22
stevenl
LQ Newbie
 
Registered: Mar 2012
Posts: 13

Original Poster
Rep: Reputation: Disabled
Thank you so much. Think it works!

However looking at /dev/sda4, it is showing id 83 and Linux system instead of Linux LVM. Is this correct?
Code:
root@atraina-alfdrp:~# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/atraina--alfdrp-root
                       83G   47G   32G  61% /
udev                  7.9G  4.0K  7.9G   1% /dev
tmpfs                 3.2G  556K  3.2G   1% /run
none                  5.0M     0  5.0M   0% /run/lock
none                  7.9G     0  7.9G   0% /run/shm
/dev/sda1             228M   24M  193M  11% /boot
root@atraina-alfdrp:~# fdisk -lu /dev/sda

Disk /dev/sda: 107.6 GB, 107646812160 bytes
255 heads, 63 sectors/track, 13087 cylinders, total 210247680 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000d854e

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048      499711      248832   83  Linux
/dev/sda2          501758   134215679    66856961    5  Extended
/dev/sda4       134215680   210247679    38016000   83  Linux
/dev/sda5          501760   134215679    66856960   8e  Linux LVM
root@atraina-alfdrp:~#
 
Old 03-26-2012, 01:30 AM   #23
xeleema
Member
 
Registered: Aug 2005
Location: D.i.t.h.o, Texas
Distribution: Slackware 13.x, rhel3/5, Solaris 8-10(sparc), HP-UX 11.x (pa-risc)
Posts: 987
Blog Entries: 4

Rep: Reputation: 252Reputation: 252Reputation: 252
Quote:
Originally Posted by stevenl View Post
Thank you so much. Think it works!
You're welcome! Glad we got it to work! <highfive>

Quote:
Originally Posted by stevenl View Post
However looking at /dev/sda4, it is showing id 83 and Linux system instead of Linux LVM. Is this correct?
Well, I agree that it should be 8e instead of 83 (which I mentioned back in post #19).
I don't think there will be any bad side-effects to changing the Partition ID after it's in use, however it would have been safer to change the Partition ID before the partition was added to the volume group.

You can use the 'fdisk' command to change the partition types.
if you 'fdisk /dev/sda' and hit 'm', you should see the command needed to change the partition type. Just set sda4 to 8e, and then you should be good.

(At this point, it's mostly to stop confusion on your part, and make sure any tools you use in the future properly identify that partition as being under Linux LVM control).

Last edited by xeleema; 03-26-2012 at 01:31 AM.
 
Old 03-26-2012, 04:52 AM   #24
stevenl
LQ Newbie
 
Registered: Mar 2012
Posts: 13

Original Poster
Rep: Reputation: Disabled
Thumbs up

Thanks heaps. (HiFive). Cheers.
 
  


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
disk space unnecessarily full mbanwi Linux - Newbie 2 09-07-2009 09:52 AM
the disk space get full because of a log file. why???? another 1 Linux - Newbie 2 04-25-2009 11:42 AM
The hard disk space is full rahulruns Linux - General 5 04-14-2008 09:04 AM
disk space is full ( / is 100% in use) samengr Linux - General 3 01-26-2008 09:38 AM
Redhat 9 disk space full when not supose to be? cyb0rg51 Linux - Newbie 6 04-25-2004 12:25 AM


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